@Test public void testGetOnEmpty() throws Exception { runOnOtherThread(new Runnable() { @Override public void run() { final Context expected = EmptyContext.getInstance(); final Context actual = ContextHolder.current(); assertTrue(expected == actual); } }); }
public static Context current() { final Context context = cabinet.get(); return null != context ? context : EmptyContext.getInstance(); }
ContextHolder { public static Context current() { final Context context = cabinet.get(); return null != context ? context : EmptyContext.getInstance(); } }
ContextHolder { public static Context current() { final Context context = cabinet.get(); return null != context ? context : EmptyContext.getInstance(); } private  ContextHolder(); }
ContextHolder { public static Context current() { final Context context = cabinet.get(); return null != context ? context : EmptyContext.getInstance(); } private  ContextHolder(); static Context current(); static Context attach(final Context context); static Context remove(); }
ContextHolder { public static Context current() { final Context context = cabinet.get(); return null != context ? context : EmptyContext.getInstance(); } private  ContextHolder(); static Context current(); static Context attach(final Context context); static Context remove();  }