Home
last modified time | relevance | path

Searched refs:Providers (Results 1 – 25 of 28) sorted by relevance

12

/external/guice/core/test/com/google/inject/util/
DProvidersTest.java36 Provider<String> p = Providers.of(foo); in testOfInstance()
42 Provider<String> p = Providers.of(null); in testOfNull()
49 Providers.of(null), in testOfEquality()
50 Providers.of(null)) in testOfEquality()
52 Providers.of("Hello"), in testOfEquality()
53 Providers.of("Hello")) in testOfEquality()
60 Providers.guicify(new JavaxProvider(10)), in testGuicifyEquality()
61 Providers.guicify(new JavaxProvider(10))) in testGuicifyEquality()
63 Providers.guicify(new JavaxProvider(11)), in testGuicifyEquality()
64 Providers.guicify(new JavaxProvider(11))) in testGuicifyEquality()
[all …]
/external/guice/extensions/servlet/test/com/google/inject/servlet/
DServletScopesTest.java38 import com.google.inject.util.Providers;
68 bind(c).toProvider(Providers.of("c")).in(ServletScopes.REQUEST); in testIsRequestScopedPositive()
69 bind(d).toProvider(Providers.of("d")).in(RequestScoped.class); in testIsRequestScopedPositive()
74 bind(f).toProvider(Providers.of("f")).in(RequestScoped.class); in testIsRequestScopedPositive()
128 bind(c).toProvider(Providers.of("c")).in(Scopes.NO_SCOPE); in testIsRequestScopedNegative()
130 bind(e).toProvider(Providers.of("e")).asEagerSingleton(); in testIsRequestScopedNegative()
131 bind(f).toProvider(Providers.of("f")).in(Scopes.SINGLETON); in testIsRequestScopedNegative()
132 bind(g).toProvider(Providers.of("g")).in(Singleton.class); in testIsRequestScopedNegative()
133 bind(h).toProvider(Providers.of("h")).in(CustomScoped.class); in testIsRequestScopedNegative()
138 bind(i).toProvider(Providers.of("i")).in(CustomScoped.class); in testIsRequestScopedNegative()
DServletPipelineRequestDispatcherTest.java36 import com.google.inject.util.Providers;
107 Provider<ServletDefinition> bindingProvider = Providers.of(servletDefinition); in testIncludeManagedServlet()
177 Provider<ServletDefinition> bindingProvider = Providers.of(servletDefinition); in testForwardToManagedServlet()
249 Provider<ServletDefinition> bindingProvider = Providers.of(servletDefinition); in forwardToManagedServletFailureOnCommittedBuffer()
DServletTest.java45 import com.google.inject.util.Providers;
456 bind(IN_SESSION_NULL_KEY).toProvider(Providers.<InSession>of(null)).in(SessionScoped.class); in createInjector()
458 bind(IN_REQUEST_NULL_KEY).toProvider(Providers.<InRequest>of(null)).in(RequestScoped.class); in createInjector()
/external/guice/core/test/com/google/inject/
DBinderTest.java30 import com.google.inject.util.Providers;
467 bind(new TypeLiteral<Provider<String>>() {}).toInstance(Providers.of("A")); in testBindingToProvider()
488 .toProvider(Providers.<AbstractModule>of(null)); in configure()
489 bind(Binder.class).annotatedWith(red).toProvider(Providers.<Binder>of(null)); in configure()
490 bind(Binding.class).annotatedWith(red).toProvider(Providers.<Binding>of(null)); in configure()
491 bind(Injector.class).annotatedWith(red).toProvider(Providers.<Injector>of(null)); in configure()
492 bind(Key.class).annotatedWith(red).toProvider(Providers.<Key>of(null)); in configure()
493 bind(Module.class).annotatedWith(red).toProvider(Providers.<Module>of(null)); in configure()
494 bind(Provider.class).annotatedWith(red).toProvider(Providers.<Provider>of(null)); in configure()
495 bind(Scope.class).annotatedWith(red).toProvider(Providers.<Scope>of(null)); in configure()
[all …]
DScopesTest.java32 import com.google.inject.util.Providers;
559 bind(c).toProvider(Providers.of("c")).in(Scopes.SINGLETON);
561 bind(e).toProvider(Providers.of("e")).asEagerSingleton();
562 bind(f).toProvider(Providers.of("f")).in(Singleton.class);
566 bind(i).toProvider(Providers.of("i")).in(Singleton.class);
614 bind(c).toProvider(Providers.of("c")).in(Scopes.NO_SCOPE);
615 bind(d).toProvider(Providers.of("d")).in(CustomScoped.class);
619 bind(f).toProvider(Providers.of("f")).in(CustomScoped.class);
663 bind(c).toProvider(Providers.of("c")).in(CUSTOM_SCOPE);
664 bind(d).toProvider(Providers.of("d")).in(CustomScoped.class);
[all …]
DMembersInjectorTest.java22 import com.google.inject.util.Providers;
175 bind(MembersInjector.class).toProvider(Providers.<MembersInjector>of(null)); in testCannotBindMembersInjector()
188 .toProvider(Providers.<MembersInjector<A<C>>>of(null)); in testCannotBindMembersInjector()
DDuplicateBindingsTest.java27 import com.google.inject.util.Providers;
47 private Provider<Foo> pFoo = Providers.<Foo>of(new FooImpl());
160 new SimpleModule(new FooImpl(), Providers.<Foo>of(new FooImpl()), in testMixedTargetsFails()
DBinderTestSuite.java30 import com.google.inject.util.Providers;
767 Provider<?> provider = Providers.of(new Object());
DProvisionListenerTest.java33 import com.google.inject.util.Providers;
717 bind(Injector.class).toProvider(Providers.<Injector>of(null));
/external/guice/core/src/com/google/inject/internal/
DInstanceBindingImpl.java29 import com.google.inject.util.Providers;
45 this.provider = Providers.of(instance); in InstanceBindingImpl()
53 this.provider = Providers.of(instance); in InstanceBindingImpl()
DProviderInstanceBindingImpl.java30 import com.google.inject.util.Providers;
67 return Providers.guicify(providerInstance); in getProviderInstance()
DInjectorImpl.java48 import com.google.inject.util.Providers;
472 provider = Providers.of(value);
/external/guice/extensions/dagger-adapter/test/com/google/inject/daggeradapter/
DDaggerAdapterTest.java29 import com.google.inject.util.Providers;
89 mb.addBinding().toProvider(Providers.of(8)); // mix'n'match. in configure()
/external/guice/core/src/com/google/inject/util/
DProviders.java40 public final class Providers { class
42 private Providers() {} in Providers() method in Providers
/external/guice/core/test/com/googlecode/guice/
DJsr330Test.java35 import com.google.inject.util.Providers;
268 com.google.inject.Provider<String> guicified = Providers.guicify(jsr330Provider); in testGuicify330Provider()
273 assertSame(guicified, Providers.guicify(guicified)); in testGuicify330Provider()
292 Providers.guicify(jsr330Provider); in testGuicifyWithDependencies()
/external/guice/extensions/multibindings/test/com/google/inject/multibindings/
DMultibinderTest.java61 import com.google.inject.util.Providers;
336 multibinder.addBinding().toProvider(Providers.of("A")); in testMultibinderSetForbidsDuplicateElements()
390 multibinder.addBinding().toProvider(Providers.of(new ValueType(1, 2))); in testMultibinderSetShowsBothElementsIfToStringDifferent()
472 .addBinding().toProvider(Providers.<String>of(null)); in testMultibinderSetForbidsNullElements()
742 multibinder.addBinding().toProvider(Providers.of("A")); in testModuleOverrideRepeatedInstallsAndMultibindings_toProviderInstance()
743 multibinder.addBinding().toProvider(Providers.of("B")); in testModuleOverrideRepeatedInstallsAndMultibindings_toProviderInstance()
1144 multibinder.addBinding().toProvider(Providers.of("A")); in testMultibinderCanInjectCollectionOfProviders()
1145 multibinder.addBinding().toProvider(Providers.of("B")); in testMultibinderCanInjectCollectionOfProviders()
1168 multibinder.addBinding().toProvider(Providers.of("A")); in testMultibinderCanInjectCollectionOfProvidersWithAnnotation()
1169 multibinder.addBinding().toProvider(Providers.of("B")); in testMultibinderCanInjectCollectionOfProvidersWithAnnotation()
DOptionalBinderTest.java56 import com.google.inject.util.Providers;
697 .setDefault().toProvider(Providers.<String>of(null)); in testLinkedToNullProvidersMakeAbsentValuesAndPresentProviders_default()
742 .setBinding().toProvider(Providers.<String>of(null)); in testLinkedToNullProvidersMakeAbsentValuesAndPresentProviders_actual()
788 .setBinding().toProvider(Providers.<String>of(null)); in testLinkedToNullActualDoesntFallbackToDefault()
964 final Provider<String> aProvider = Providers.of("A"); in testModuleOverrideRepeatedInstalls_toProviderInstance()
965 final Provider<String> bProvider = Providers.of("B"); in testModuleOverrideRepeatedInstalls_toProviderInstance()
DMapBinderTest.java56 import com.google.inject.util.Providers;
618 .addBinding("null").toProvider(Providers.<String>of(null)); in testMapBinderMapForbidsNullValues()
/external/guice/extensions/persist/src/com/google/inject/persist/jpa/
DJpaPersistModule.java30 import com.google.inject.util.Providers;
/external/e2fsprogs/lib/et/test_cases/
Dimap_err.et13 # Permission is also granted to Internet Service Providers and others
/external/guice/extensions/testlib/test/com/google/inject/testing/fieldbinder/
DBoundFieldModuleTest.java33 import com.google.inject.util.Providers;
720 @Bind(lazy = true) Provider<Integer> foo = Providers.of(null);
/external/guice/core/test/com/google/inject/spi/
DProviderMethodsTest.java47 import com.google.inject.util.Providers;
860 bind(String.class).toProvider(Providers.<String>of(null));
DElementsTest.java49 import com.google.inject.util.Providers;
852 stringLookup.initializeDelegate(Providers.of("out")); in testElementInitialization()
/external/guice/extensions/assistedinject/src/com/google/inject/assistedinject/
DFactoryProvider2.java57 import com.google.inject.util.Providers;
705 binder.bind((Key) paramKey).toProvider(Providers.of(args[p++])); in getBindingFromNewInjector()

12