@Test public void testExecutorService_DefaultShutdown() { AgBuilder builder = new AgBuilder(); AgRuntime r = builder.build(); ExecutorService exec; try { exec = r.service(ExecutorService.class); assertFalse(exec.isShutdown()); } finally { r.shutdown(); } assertTrue(exec.isShutdown()); }
public AgRuntime build() { Injector i = createInjector(); return new AgRuntime(i, createExtraFeatures(i)); }
AgBuilder { public AgRuntime build() { Injector i = createInjector(); return new AgRuntime(i, createExtraFeatures(i)); } }
AgBuilder { public AgRuntime build() { Injector i = createInjector(); return new AgRuntime(i, createExtraFeatures(i)); } AgBuilder(); }
AgBuilder { public AgRuntime build() { Injector i = createInjector(); return new AgRuntime(i, createExtraFeatures(i)); } AgBuilder(); AgBuilder doNotAutoLoadFeatures(); AgBuilder doNotAutoLoadModules(); AgBuilder agService(IAgService agService); AgBuilder agService(Class<? extends IAgService> agServiceType); AgBuilder entityEncoderFilter(EntityEncoderFilter filter); AgBuilder entityEncoderFilters(Collection<EntityEncoderFilter> filters); AgBuilder baseUrl(String url); AgBuilder executor(ExecutorService executor); AgBuilder entityOverlay(AgEntityOverlay<T> overlay); AgBuilder feature(Feature feature); AgBuilder feature(AgFeatureProvider featureProvider); AgBuilder module(Module module); AgBuilder module(AgModuleProvider provider); AgBuilder metadataEncoder(String type, PropertyMetadataEncoder encoder); AgRuntime build(); }
AgBuilder { public AgRuntime build() { Injector i = createInjector(); return new AgRuntime(i, createExtraFeatures(i)); } AgBuilder(); AgBuilder doNotAutoLoadFeatures(); AgBuilder doNotAutoLoadModules(); AgBuilder agService(IAgService agService); AgBuilder agService(Class<? extends IAgService> agServiceType); AgBuilder entityEncoderFilter(EntityEncoderFilter filter); AgBuilder entityEncoderFilters(Collection<EntityEncoderFilter> filters); AgBuilder baseUrl(String url); AgBuilder executor(ExecutorService executor); AgBuilder entityOverlay(AgEntityOverlay<T> overlay); AgBuilder feature(Feature feature); AgBuilder feature(AgFeatureProvider featureProvider); AgBuilder module(Module module); AgBuilder module(AgModuleProvider provider); AgBuilder metadataEncoder(String type, PropertyMetadataEncoder encoder); AgRuntime build();  }