Home
last modified time | relevance | path

Searched refs:createInjector (Results 1 – 25 of 126) sorted by relevance

123456

/external/guice/extensions/testlib/test/com/google/inject/testing/fieldbinder/
DBoundFieldModuleTest.java46 Guice.createInjector(module); in testBindingNothing()
59 Injector injector = Guice.createInjector(module); in testBindingOnePrivate()
72 Injector injector = Guice.createInjector(module); in testBindingOnePublic()
95 Injector injector = Guice.createInjector(module); in testSuperTypeBinding()
110 Injector injector = Guice.createInjector(module); in testBindingTwo()
125 Injector injector = Guice.createInjector(module); in testBindingSuperType()
139 Injector injector = Guice.createInjector(module); in testBindingSuperTypeAccessSubType()
166 Guice.createInjector(module); in testBindingIncorrectTypeProviderFails()
190 Injector injector = Guice.createInjector(module); in testBindingWithBindingAnnotation()
211 Injector injector = Guice.createInjector(module); in testBindingWithQualifier()
[all …]
/external/guice/core/test/com/google/inject/
DOptionalBindingTest.java89 Guice.createInjector(everythingModule) in testEverythingInjectorGetInstance()
95 Guice.createInjector(partialModule) in testPartialInjectorGetInstance()
101 Guice.createInjector().getInstance(HasOptionalInjections.class).assertNothingInjected(); in testNothingInjectorGetInstance()
106 Guice.createInjector(everythingModule).injectMembers(instance); in testEverythingInjectorInjectMembers()
112 Guice.createInjector(partialModule).injectMembers(instance); in testPartialInjectorInjectMembers()
118 Guice.createInjector().injectMembers(instance); in testNothingInjectorInjectMembers()
123 Guice.createInjector(everythingModule, toInstanceModule) in testEverythingInjectorToInstance()
129 Guice.createInjector(partialModule, toInstanceModule) in testPartialInjectorToInstance()
135 Guice.createInjector(toInstanceModule) in testNothingInjectorToInstance()
141 Guice.createInjector(everythingModule, toProviderInstanceModule) in testEverythingInjectorToProviderInstance()
[all …]
DNullableInjectionPointTest.java23 createInjector().getInstance(FooConstructor.class); in testInjectNullIntoNotNullableConstructor()
36 createInjector().getInstance(FooMethod.class); in testInjectNullIntoNotNullableMethod()
49 createInjector().getInstance(FooField.class); in testInjectNullIntoNotNullableField()
62 assertNull(createInjector().getInstance(Foo.class)); in testGetInstanceOfNull()
66 NullableFooConstructor nfc = createInjector().getInstance(NullableFooConstructor.class); in testInjectNullIntoNullableConstructor()
71 NullableFooMethod nfm = createInjector().getInstance(NullableFooMethod.class); in testInjectNullIntoNullableMethod()
76 NullableFooField nff = createInjector().getInstance(NullableFooField.class); in testInjectNullIntoNullableField()
82 createInjector().getInstance(CustomNullableFooConstructor.class); in testInjectNullIntoCustomNullableConstructor()
87 CustomNullableFooMethod nfm = createInjector().getInstance(CustomNullableFooMethod.class); in testInjectNullIntoCustomNullableMethod()
92 CustomNullableFooField nff = createInjector().getInstance(CustomNullableFooField.class); in testInjectNullIntoCustomNullableField()
[all …]
DProvisionExceptionTest.java41 Guice.createInjector().getInstance(A.class); in testExceptionsCollapsed()
60 Guice.createInjector( in testExceptionsCollapsedWithScopes()
83 Guice.createInjector().getInstance(E.class); in testMethodInjectionExceptions()
96 Guice.createInjector( in testBindToProviderInstanceExceptions()
120 Guice.createInjector().getInstance(F.class); in testProvisionExceptionsAreWrappedForBindToType()
132 Guice.createInjector( in testProvisionExceptionsAreWrappedForBindToProviderType()
154 Guice.createInjector( in testProvisionExceptionsAreWrappedForBindToProviderInstance()
174 Guice.createInjector().getInstance(A.class); in testProvisionExceptionIsSerializable()
196 Guice.createInjector( in testMultipleCauses()
225 Injector injector = Guice.createInjector(); in testInjectInnerClass()
[all …]
DJitBindingsTest.java58 Guice.createInjector( in testLinkedBindingWorks()
76 Guice.createInjector( in testMoreBasicsWork()
96 Guice.createInjector( in testLinkedEagerSingleton()
114 Guice.createInjector( in testBasicsWithEagerSingleton()
134 Guice.createInjector( in testLinkedToScoped()
152 Guice.createInjector( in testBasicsWithScoped()
172 Guice.createInjector( in testFailsIfInjectingScopedDirectlyWhenItIsntBound()
190 Guice.createInjector( in testLinkedProviderBindingWorks()
207 Guice.createInjector( in testJitGetFails()
224 Guice.createInjector( in testJitInjectionFails()
[all …]
DParentInjectorTest.java38 Injector parent = Guice.createInjector(bindsA); in testParentAndChildCannotShareExplicitBindings()
58 Injector parent = Guice.createInjector(); in testParentJitBindingWontClobberChildBinding()
75 Injector parent = Guice.createInjector(); in testChildCannotBindToAParentJitBinding()
90 Injector parent = Guice.createInjector(); in testJustInTimeBindingsAreSharedWithParentIfPossible()
102 Injector parent = Guice.createInjector(bindsB); in testBindingsInherited()
108 Injector top = Guice.createInjector(bindsA); in testGetParent()
117 Injector parent = Guice.createInjector(); in testChildBindingsNotVisibleToParent()
128 Guice.createInjector( in testScopesInherited()
157 Guice.createInjector( in testInterceptorsInherited()
182 Injector parent = Guice.createInjector(bindListConverterModule); in testTypeConvertersInherited()
[all …]
DCircularDependencyTest.java46 Guice.createInjector( in testCircularlyDependentConstructors()
59 Guice.createInjector( in testCircularlyDependentConstructorsWithProviderMethods()
78 Guice.createInjector( in testCircularlyDependentConstructorsWithProviderInstances()
110 Guice.createInjector( in testCircularlyDependentConstructorsWithProviderKeys()
122 Injector injector = Guice.createInjector(); in testCircularlyDependentConstructorsWithProvidedBy()
235 Guice.createInjector().getInstance(C.class); in testUnresolvableCircularDependency()
247 Guice.createInjector( in testUnresolvableCircularDependenciesWithProviderInstances()
272 Guice.createInjector( in testUnresolvableCircularDependenciesWithProviderKeys()
292 Guice.createInjector().getInstance(C2.class); in testUnresolvableCircularDependenciesWithProvidedBy()
346 Guice.createInjector( in testDisabledCircularDependency()
[all …]
DInjectorTest.java50 Injector injector = Guice.createInjector(Stage.TOOL); in testToStringDoesNotInfinitelyRecurse()
60 Guice.createInjector( in testProviderMethods()
92 return Guice.createInjector( in createFooInjector()
114 Guice.createInjector(
127 Injector injector = Guice.createInjector();
214 Guice.createInjector(
230 Guice.createInjector(
266 Guice.createInjector(
297 Guice.createInjector(
327 Guice.createInjector(
[all …]
DBinderTest.java76 Guice.createInjector( in testProviderFromBinder()
98 Guice.createInjector( in testMissingBindings()
159 Guice.createInjector( in testMissingDependency()
185 Guice.createInjector( in testDanglingConstantBinding()
203 Guice.createInjector( in testRecursiveBinding()
222 Guice.createInjector( in testBindingNullConstant()
242 Guice.createInjector( in testToStringOnBinderApi()
272 Guice.createInjector( in testNothingIsSerializableInBinderApi()
303 Guice.createInjector( in testArrayTypeCanonicalization()
320 Guice.createInjector( in testArrayTypeCanonicalization()
[all …]
DMembersInjectorTest.java64 Guice.createInjector( in testMembersInjectorFromBinder()
114 Guice.createInjector( in testMembersInjectorFromInjector()
144 Injector injector = Guice.createInjector(); in testMembersInjectorWithNonInjectedTypes()
154 Injector injector = Guice.createInjector(); in testInjectionFailure()
170 Injector injector = Guice.createInjector(); in testInjectionAppliesToSpecifiedType()
178 Guice.createInjector( in testInjectingMembersInjector()
195 Guice.createInjector( in testCannotBindMembersInjector()
210 Guice.createInjector( in testCannotBindMembersInjector()
228 Guice.createInjector().getInstance(InjectsBrokenMembersInjector.class); in testInjectingMembersInjectorWithErrorsInDependencies()
244 Guice.createInjector( in testLookupMembersInjectorBinding()
[all …]
DRequireAtInjectOnConstructorsTest.java30 Guice.createInjector( in testNoCxtors_explicitBinding()
53 Guice.createInjector( in testNoCxtors_jitBinding()
75 Guice.createInjector( in testNoCxtors_implicitBinding()
98 Guice.createInjector( in testNoCxtors_inheritedByPrivateModules()
127 Guice.createInjector( in testNoCxtors_accumulatesAllErrors()
156 Guice.createInjector( in testNoCxtors_separateOptionsForPrivateModules()
188 Guice.createInjector( in testManyConstructorsButNoneWithAtInject()
211 Guice.createInjector( in testRequireAtInjectStillAllowsToConstructorBindings()
DPrivateModuleTest.java42 Guice.createInjector( in testBasicUsage()
83 Guice.createInjector( in testWithoutPrivateModules()
105 Guice.createInjector( in testMisplacedExposedAnnotation()
127 Guice.createInjector( in testMisplacedExposeStatement()
147 Guice.createInjector( in testPrivateModulesAndProvidesMethods()
211 Guice.createInjector( in testCannotBindAKeyExportedByASibling()
247 Guice.createInjector( in testExposeButNoBind()
278 Guice.createInjector( in testMessagesFromPrivateModulesAreNicelyIntegrated()
310 Guice.createInjector( in testNestedPrivateInjectors()
332 Guice.createInjector( in testInstallingRegularModulesFromPrivateModules()
[all …]
DImplicitBindingTest.java31 Injector injector = Guice.createInjector(); in testCircularDependency()
50 Injector injector = Guice.createInjector(); in testDefaultImplementation()
71 Injector injector = Guice.createInjector(); in testDefaultProvider()
78 Guice.createInjector( in testBindingOverridesImplementedBy()
95 Guice.createInjector().getInstance(Key.get(I.class, Names.named("i"))); in testNoImplicitBindingIsCreatedForAnnotatedKeys()
136 Guice.createInjector( in testCircularJitBindingsLeaveNoResidue()
280 Injector parentSetupRootInjector = Guice.createInjector(testModule); in testInstancesRequestingProvidersForThemselvesWithChildInjectors()
290 Injector childSetupRootInjector = Guice.createInjector(); in testInstancesRequestingProvidersForThemselvesWithChildInjectors()
346 Injector injector = Guice.createInjector(); in testRecursiveJitBindingsCleanupCorrectly()
388 NonEmptyEnum cardSuit = Guice.createInjector().getInstance(NonEmptyEnum.class); in testProvidedByNonEmptyEnum()
[all …]
DBindingTest.java60 Guice.createInjector( in testExplicitCyclicDependency()
123 Guice.createInjector( in testBindToUnboundLinkedBinding()
142 Guice.createInjector( in testScopeIsAppliedToKeyNotTarget()
214 assertNotNull(Guice.createInjector().getInstance(clazz)); in assertBindingSucceeds()
219 Guice.createInjector().getInstance(clazz); in assertBindingFails()
230 Guice.createInjector().getInstance(TooManyConstructors.class); in testTooManyConstructors()
253 Guice.createInjector( in testToConstructorBinding()
271 Guice.createInjector( in testToConstructorBindingsOnParameterizedTypes()
295 Guice.createInjector( in testToConstructorBindingsFailsOnRawTypes()
326 Guice.createInjector( in testToConstructorAndMethodInterceptors()
[all …]
DRequestInjectionTest.java50 Guice.createInjector( in testInjectMembers()
67 Guice.createInjector( in testInjectStatics()
84 Guice.createInjector( in testInjectMembersAndStatics()
103 Guice.createInjector( in testValidationErrorOnInjectedMembers()
122 Guice.createInjector( in testInjectionErrorOnInjectedMembers()
149 Guice.createInjector( in testUserExceptionWhileInjectingInstance()
167 Guice.createInjector( in testUserExceptionWhileInjectingStatically()
225 Guice.createInjector( in testEarlyInjectableReferencesWithSameIdentity()
DDuplicateBindingsTest.java52 Guice.createInjector( in testDuplicateBindingsAreIgnored()
82 Guice.createInjector(new FailingProviderModule(), new FailingProviderModule()); in testProviderMethodsFailIfInstancesDiffer()
97 Guice.createInjector( in testSameScopeInstanceIgnored()
101 Guice.createInjector( in testSameScopeInstanceIgnored()
107 Guice.createInjector( in testSameScopeAnnotationIgnored()
113 Guice.createInjector( in testMixedAnnotationAndScopeForSingletonIgnored()
119 Guice.createInjector( in testMixedScopeAndUnscopedIgnored()
126 Guice.createInjector( in testMixedScopeFails()
187 Guice.createInjector( in testMixedTargetsFails()
232 Guice.createInjector(new ThrowingModule(), new ThrowingModule()); in testExceptionInEqualsThrowsCreationException()
[all …]
/external/guice/core/src/com/google/inject/
DGuice.java58 public static Injector createInjector(Module... modules) { in createInjector() method in Guice
59 return createInjector(Arrays.asList(modules)); in createInjector()
68 public static Injector createInjector(Iterable<? extends Module> modules) { in createInjector() method in Guice
69 return createInjector(Stage.DEVELOPMENT, modules); in createInjector()
77 public static Injector createInjector(Stage stage, Module... modules) { in createInjector() method in Guice
78 return createInjector(stage, Arrays.asList(modules)); in createInjector()
86 public static Injector createInjector(Stage stage, Iterable<? extends Module> modules) { in createInjector() method in Guice
/external/guice/core/test/com/google/inject/util/
DOverrideModuleTest.java21 import static com.google.inject.Guice.createInjector;
70 Injector injector = createInjector(Modules.override(newModule("A")).with(newModule("B"))); in testOverride()
78 Injector injector = createInjector(module); in testOverrideMultiple()
86 Injector injector = createInjector(Modules.override(EMPTY_MODULE).with(newModule("B"))); in testOverrideUnmatchedTolerated()
107 Injector injector = createInjector(Modules.override(original).with(replacements)); in testOverrideConstant()
121 Injector injector = createInjector(Modules.override(original).with(EMPTY_MODULE)); in testGetProviderInModule()
138 Injector injector = createInjector(Modules.override(original).with(replacements)); in testOverrideWhatGetProviderProvided()
161 Injector injector = createInjector(Modules.override(original).with(replacements)); in testOverrideUsingOriginalsGetProvider()
197 Injector injector = createInjector(Modules.override(overrides).with(replacements2)); in testOverrideOfOverride()
223 createInjector(module); in testOverridesTwiceFails()
[all …]
/external/guice/core/test/com/google/inject/spi/
DModuleAnnotatedMethodScannerTest.java65 Injector injector = Guice.createInjector(module, NamedMunger.module()); in testScanning()
98 Injector injector = Guice.createInjector(module, NamedMunger.module()); in testSkipSources()
120 Injector injector = Guice.createInjector(module, NamedMunger.module()); in testWithSource()
135 Guice.createInjector(module, NamedMunger.module()); in testMoreThanOneClaimedAnnotationFails()
203 Guice.createInjector(new SomeModule(), FailingScanner.module());
250 Injector parent = Guice.createInjector(NamedMunger.module());
274 Injector parent = Guice.createInjector();
286 Guice.createInjector(
304 Guice.createInjector(
328 Guice.createInjector(
[all …]
DProviderMethodsTest.java71 Injector injector = Guice.createInjector(this); in testProviderMethods()
149 Guice.createInjector(
205 Guice.createInjector(
233 Guice.createInjector(new ProvideTs<String>("A", "B") {}, new ProvideTs<Integer>(1, 2) {});
274 Guice.createInjector(
311 Injector injector = Guice.createInjector(installsSelf);
320 Guice.createInjector(
368 Injector injector = Guice.createInjector(module);
401 Injector injector = Guice.createInjector(module);
424 Guice.createInjector(
[all …]
/external/guice/extensions/throwingproviders/test/com/google/inject/throwingproviders/
DCheckedProviderTest.java99 Guice.createInjector( in setUp()
118 Guice.createInjector( in setUp()
143 Guice.createInjector( in setUp()
304 Guice.createInjector( in testAnnotations_Bind()
325 Guice.createInjector( in testAnnotations_Provides()
361 Guice.createInjector( in testAnnotations_Cxtor()
422 Guice.createInjector( in testThrowingProviderSubclassing()
439 Guice.createInjector( in testBindingToNonInterfaceType_Bind()
458 Guice.createInjector( in testBindingToNonInterfaceType_Provides()
482 Guice.createInjector( in testBindingToSubSubInterface_Bind()
[all …]
DThrowingProviderTest.java68 Guice.createInjector(
86 Guice.createInjector(
225 Guice.createInjector( in testAnnotations_Bind()
246 Guice.createInjector( in testAnnotations_Provides()
313 Guice.createInjector( in testThrowingProviderSubclassing()
330 Guice.createInjector( in testBindingToNonInterfaceType_Bind()
349 Guice.createInjector( in testBindingToNonInterfaceType_Provides()
373 Guice.createInjector( in testBindingToSubSubInterface_Bind()
392 Guice.createInjector( in testBindingToSubSubInterface_Provides()
419 Guice.createInjector( in testBindingToInterfaceWithExtraMethod_Bind()
[all …]
/external/guice/extensions/assistedinject/test/com/google/inject/assistedinject/
DFactoryModuleBuilderTest.java61 Guice.createInjector( in testImplicitForwardingAssistedBindingFailsWithInterface()
83 Guice.createInjector( in testImplicitForwardingAssistedBindingFailsWithAbstractClass()
106 Guice.createInjector( in testImplicitForwardingAssistedBindingCreatesNewObjects()
128 Guice.createInjector( in testExplicitForwardingAssistedBindingFailsWithInterface()
154 Guice.createInjector( in testExplicitForwardingAssistedBindingFailsWithAbstractClass()
181 Guice.createInjector( in testExplicitForwardingAssistedBindingCreatesNewObjects()
206 Guice.createInjector( in testAnnotatedAndParentBoundReturnValue()
229 Guice.createInjector( in testParentBoundReturnValue()
249 Guice.createInjector( in testConfigureAnnotatedReturnValue()
268 Guice.createInjector( in testNoBindingAssistedInject()
[all …]
DFactoryProvider2Test.java59 Guice.createInjector( in testAssistedFactory()
81 Guice.createInjector( in testAssistedFactoryWithAnnotations()
146 Guice.createInjector( in testFactoryUsesInjectedConstructor()
184 Guice.createInjector( in testConstructorDoesntNeedAllFactoryMethodArguments()
209 Guice.createInjector( in testMethodsAndFieldsGetInjected()
249 Guice.createInjector( in testProviderInjection()
279 Guice.createInjector( in testAssistedProviderInjection()
316 Guice.createInjector( in testTypeTokenInjection()
352 Guice.createInjector( in testTypeTokenProviderInjection()
390 Guice.createInjector( in testAssistInjectionInNonPublicConstructor()
[all …]
/external/guice/core/test/com/google/inject/internal/
DMultibinderTest.java123 Injector injector = Guice.createInjector(abc, de); in testMultibinderAggregatesMultipleModules()
157 Injector injector = Guice.createInjector(module); in testMultibinderAggregationForAnnotationInstance()
189 Injector injector = Guice.createInjector(module); in testMultibinderAggregationForAnnotationType()
224 Injector injector = Guice.createInjector(module); in testMultibinderWithMultipleAnnotationValueSets()
265 Injector injector = Guice.createInjector(module); in testMultibinderWithMultipleAnnotationTypeSets()
298 Injector injector = Guice.createInjector(module); in testMultibinderWithMultipleSetTypes()
315 Injector injector = Guice.createInjector(module); in testMultibinderWithEmptySet()
324 Guice.createInjector( in testMultibinderSetIsUnmodifiable()
342 Guice.createInjector( in testMultibinderSetIsSerializable()
386 Injector injector = Guice.createInjector(module); in testMultibinderSetIsLazy()
[all …]

123456