Uses of Interface
org.glassfish.hk2.api.ServiceLocator
-
-
Uses of ServiceLocator in com.sun.enterprise.module
Methods in com.sun.enterprise.module that return ServiceLocator Modifier and Type Method Description ServiceLocator
ModulesRegistry. createServiceLocator()
Creates the defaultServiceLocator
from all the modules in this registry Calling this method has the same effect of calling {@link #createServiceLocator("default")}ServiceLocator
ModulesRegistry. createServiceLocator(java.lang.String name)
Creates aServiceLocator
from all the modules in this registry Cal;ling this method has the same effect of callingModulesRegistry.newServiceLocator()
followed by {@link #populateServiceLocator(String, org.glassfish.hk2.api.ServiceLocator, java.util.List}.ServiceLocator
ModulesRegistry. createServiceLocator(ServiceLocator serviceLocator, java.lang.String name, java.util.List<PopulatorPostProcessor> postProcessors)
Creates aServiceLocator
with the provided parent.ServiceLocator
ModulesRegistry. newServiceLocator()
Creates an uninitializedServiceLocator
ServiceLocator
ModulesRegistry. newServiceLocator(ServiceLocator parent)
Methods in com.sun.enterprise.module with parameters of type ServiceLocator Modifier and Type Method Description ServiceLocator
ModulesRegistry. createServiceLocator(ServiceLocator serviceLocator, java.lang.String name, java.util.List<PopulatorPostProcessor> postProcessors)
Creates aServiceLocator
with the provided parent.ServiceLocator
ModulesRegistry. newServiceLocator(ServiceLocator parent)
void
ModulesRegistry. populateConfig(ServiceLocator serviceLocator)
void
ModulesRegistry. populateServiceLocator(java.lang.String name, ServiceLocator h, java.util.List<PopulatorPostProcessor> postProcessors)
Populates aServiceLocator
from all the modules in this registry. -
Uses of ServiceLocator in com.sun.enterprise.module.bootstrap
Methods in com.sun.enterprise.module.bootstrap that return ServiceLocator Modifier and Type Method Description ServiceLocator
Main. createServiceLocator(ModulesRegistry mr, StartupContext context, java.util.List<PopulatorPostProcessor> postProcessors, DescriptorFileFinder descriptorFileFinder)
ServiceLocator
Main. getServiceLocator()
Methods in com.sun.enterprise.module.bootstrap with parameters of type ServiceLocator Modifier and Type Method Description private void
Main. addDescriptorFileFinder(ServiceLocator serviceLocator, DescriptorFileFinder descriptorFileFinder)
ModuleStartup
Main. findStartupService(ModulesRegistry registry, ServiceLocator serviceLocator, java.lang.String mainModuleName, StartupContext context)
Return the ModuleStartup service configured to be used to start the system. -
Uses of ServiceLocator in com.sun.enterprise.module.common_impl
Fields in com.sun.enterprise.module.common_impl with type parameters of type ServiceLocator Modifier and Type Field Description private java.util.Map<ServiceLocator,java.lang.String>
AbstractModulesRegistryImpl. habitats
(package private) java.util.Map<Module,java.util.Map<ServiceLocator,java.util.List<ActiveDescriptor>>>
AbstractModulesRegistryImpl. moduleDescriptors
Methods in com.sun.enterprise.module.common_impl that return ServiceLocator Modifier and Type Method Description ServiceLocator
AbstractModulesRegistryImpl. createServiceLocator()
ServiceLocator
AbstractModulesRegistryImpl. createServiceLocator(java.lang.String name)
ServiceLocator
AbstractModulesRegistryImpl. createServiceLocator(ServiceLocator parent, java.lang.String name, java.util.List<PopulatorPostProcessor> postProcessors)
ServiceLocator
AbstractModulesRegistryImpl. newServiceLocator()
Creates an uninitializedServiceLocator
ServiceLocator
AbstractModulesRegistryImpl. newServiceLocator(ServiceLocator parent)
Create a new ServiceLocator optionally providing a parent ServicesMethods in com.sun.enterprise.module.common_impl that return types with arguments of type ServiceLocator Modifier and Type Method Description protected java.util.Set<ServiceLocator>
AbstractModulesRegistryImpl. getAllServiceLocators()
Methods in com.sun.enterprise.module.common_impl with parameters of type ServiceLocator Modifier and Type Method Description ServiceLocator
AbstractModulesRegistryImpl. createServiceLocator(ServiceLocator parent, java.lang.String name, java.util.List<PopulatorPostProcessor> postProcessors)
protected void
AbstractModulesRegistryImpl. initializeServiceLocator(ServiceLocator serviceLocator)
ServiceLocator
AbstractModulesRegistryImpl. newServiceLocator(ServiceLocator parent)
Create a new ServiceLocator optionally providing a parent Servicesprotected abstract java.util.List<ActiveDescriptor>
AbstractModulesRegistryImpl. parseInhabitants(Module module, java.lang.String name, ServiceLocator serviceLocator, java.util.List<PopulatorPostProcessor> postProcessors)
void
AbstractModulesRegistryImpl. populateConfig(ServiceLocator serviceLocator)
void
AbstractModulesRegistryImpl. populateServiceLocator(java.lang.String name, ServiceLocator serviceLocator, java.util.List<PopulatorPostProcessor> postProcessors)
Creates aServiceLocator
from all the modules in this registry -
Uses of ServiceLocator in com.sun.enterprise.module.impl
Methods in com.sun.enterprise.module.impl with parameters of type ServiceLocator Modifier and Type Method Description protected java.util.List<ActiveDescriptor>
ModulesRegistryImpl. parseInhabitants(Module module, java.lang.String name, ServiceLocator serviceLocator, java.util.List<PopulatorPostProcessor> postProcessors)
-
Uses of ServiceLocator in com.sun.enterprise.module.single
Methods in com.sun.enterprise.module.single that return ServiceLocator Modifier and Type Method Description ServiceLocator
StaticModulesRegistry. createServiceLocator(java.lang.String name)
Methods in com.sun.enterprise.module.single with parameters of type ServiceLocator Modifier and Type Method Description protected java.util.List<ActiveDescriptor>
ClassPathBasedModulesRegistry. parseInhabitants(Module module, java.lang.String name, ServiceLocator serviceLocator, java.util.List<PopulatorPostProcessor> postProcessors)
protected java.util.List<ActiveDescriptor>
SingleModulesRegistry. parseInhabitants(Module module, java.lang.String name, ServiceLocator serviceLocator, java.util.List<PopulatorPostProcessor> postProcessors)
void
StaticModulesRegistry. populateConfig(ServiceLocator serviceLocator)
-
Uses of ServiceLocator in org.glassfish.hk2.api
Methods in org.glassfish.hk2.api that return ServiceLocator Modifier and Type Method Description abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name)
Creates (or finds) a ServiceLocator.abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name, ServiceLocator parent)
Creates or finds a ServiceLocator.abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator)
Creates or finds a ServiceLocator.abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator, ServiceLocatorFactory.CreatePolicy policy)
Creates a ServiceLocator.abstract ServiceLocator
ServiceLocatorFactory. find(java.lang.String name)
Finds the ServiceLocator with this nameServiceLocator
ServiceLocator. getParent()
Gets the parent service locator for this locatorMethods in org.glassfish.hk2.api with parameters of type ServiceLocator Modifier and Type Method Description abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name, ServiceLocator parent)
Creates or finds a ServiceLocator.abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator)
Creates or finds a ServiceLocator.abstract ServiceLocator
ServiceLocatorFactory. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator, ServiceLocatorFactory.CreatePolicy policy)
Creates a ServiceLocator.abstract void
ServiceLocatorFactory. destroy(ServiceLocator locator)
Removes the given ServiceLocatorvoid
ServiceLocatorListener. locatorAdded(ServiceLocator added)
This method is called whenever a ServiceLocator has been added to the set of ServiceLocators.void
ServiceLocatorListener. locatorDestroyed(ServiceLocator destroyed)
This method is called whenever a ServiceLocator will be removed from the set of ServiceLocators.DescriptorImpl
PopulatorPostProcessor. process(ServiceLocator serviceLocator, DescriptorImpl descriptorImpl)
This method can be used to alter the descriptor read in.Method parameters in org.glassfish.hk2.api with type arguments of type ServiceLocator Modifier and Type Method Description void
ServiceLocatorListener. initialize(java.util.Set<ServiceLocator> initialLocators)
This method returns the complete list of named service locators at the time that this listener is registered. -
Uses of ServiceLocator in org.glassfish.hk2.bootstrap
Methods in org.glassfish.hk2.bootstrap with parameters of type ServiceLocator Modifier and Type Method Description static void
HK2Populator. populate(ServiceLocator serviceLocator)
This method can be used to populate the service locator with files that have been written out using theDescriptorImpl
writeObject method, looking in the classpath to locate these filesstatic java.util.List<ActiveDescriptor>
HK2Populator. populate(ServiceLocator serviceLocator, DescriptorFileFinder fileFinder, java.util.List<? extends PopulatorPostProcessor> postProcessors)
This method can be used to populate the service locator with files that have been written out using theDescriptorImpl
writeObject method.void
ConfigPopulator. populateConfig(ServiceLocator serviceLocator)
Called during the creation sequence of a service locator, and can be used to populate configuration datastatic void
HK2Populator. populateConfig(ServiceLocator serviceLocator)
-
Uses of ServiceLocator in org.glassfish.hk2.bootstrap.impl
Methods in org.glassfish.hk2.bootstrap.impl with parameters of type ServiceLocator Modifier and Type Method Description DescriptorImpl
Hk2LoaderPopulatorPostProcessor. process(ServiceLocator serviceLocator, DescriptorImpl descriptorImpl)
Uses the given classloader to load the class from the descriptor -
Uses of ServiceLocator in org.glassfish.hk2.configuration.api
Methods in org.glassfish.hk2.configuration.api with parameters of type ServiceLocator Modifier and Type Method Description static void
ConfigurationUtilities. enableConfigurationSystem(ServiceLocator locator)
Enables the Configuration subsystem of HK2. -
Uses of ServiceLocator in org.glassfish.hk2.configuration.hub.api
Methods in org.glassfish.hk2.configuration.hub.api with parameters of type ServiceLocator Modifier and Type Method Description static void
ManagerUtilities. enableConfigurationHub(ServiceLocator locator)
This method will add the Hub service to the given service locator. -
Uses of ServiceLocator in org.glassfish.hk2.configuration.internal
Fields in org.glassfish.hk2.configuration.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
ChildInjectResolverImpl. locator
private ServiceLocator
ChildIterableImpl. locator
private ServiceLocator
ConfigurationListener. locator
private ServiceLocator
NoNameTypeFilter. locator
Constructors in org.glassfish.hk2.configuration.internal with parameters of type ServiceLocator Constructor Description ChildIterableImpl(ServiceLocator locator, java.lang.reflect.Type childType, java.lang.String prefix, java.lang.String separator)
NoNameTypeFilter(ServiceLocator locator, java.lang.String typeName, java.lang.String instanceName)
-
Uses of ServiceLocator in org.glassfish.hk2.configuration.persistence.properties
Methods in org.glassfish.hk2.configuration.persistence.properties with parameters of type ServiceLocator Modifier and Type Method Description static void
PropertyFileUtilities. enablePropertyFileService(ServiceLocator locator)
This class adds the system implementation ofPropertyFileService
to the given service locator. -
Uses of ServiceLocator in org.glassfish.hk2.extension
Methods in org.glassfish.hk2.extension that return ServiceLocator Modifier and Type Method Description ServiceLocator
ServiceLocatorGenerator. create(java.lang.String name, ServiceLocator parent)
Creates the ServiceLocator that will be used to generate the ServiceLocatorsMethods in org.glassfish.hk2.extension with parameters of type ServiceLocator Modifier and Type Method Description ServiceLocator
ServiceLocatorGenerator. create(java.lang.String name, ServiceLocator parent)
Creates the ServiceLocator that will be used to generate the ServiceLocators -
Uses of ServiceLocator in org.glassfish.hk2.extras
Methods in org.glassfish.hk2.extras with parameters of type ServiceLocator Modifier and Type Method Description static void
ExtrasUtilities. bridgeServiceLocator(ServiceLocator into, ServiceLocator from)
This method will bridge all non-local services from the from ServiceLocator into the into ServiceLocator.private static void
ExtrasUtilities. checkParentage(ServiceLocator a, ServiceLocator b)
static void
ExtrasUtilities. enableDefaultInterceptorServiceImplementation(ServiceLocator locator)
This method adds in a default implementation of theInterceptionService
which uses annotations to denote which services should intercept other services.static void
ExtrasUtilities. enableOperations(ServiceLocator locator)
This method adds in the infrastructure necessary to enable HK2 Operations support.static void
ExtrasUtilities. enableTopicDistribution(ServiceLocator locator)
This method will enable the default topic distribution service.private static java.lang.String
ExtrasUtilities. getBridgeName(ServiceLocator into, ServiceLocator from)
static void
ExtrasUtilities. unbridgeServiceLocator(ServiceLocator into, ServiceLocator from)
This method will remove all non-local services from the from ServiceLocator into the into ServiceLocator. -
Uses of ServiceLocator in org.glassfish.hk2.extras.events.internal
Fields in org.glassfish.hk2.extras.events.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
DefaultTopicDistributionService. locator
Methods in org.glassfish.hk2.extras.events.internal with parameters of type ServiceLocator Modifier and Type Method Description private void
DefaultTopicDistributionService. fire(java.lang.Object message, java.lang.reflect.Method subscription, DefaultTopicDistributionService.SubscriberInfo subscriptionInfo, java.lang.Object target, ServiceLocator locator)
-
Uses of ServiceLocator in org.glassfish.hk2.extras.hk2bridge.internal
Fields in org.glassfish.hk2.extras.hk2bridge.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
Hk2BridgeImpl. local
private ServiceLocator
Hk2BridgeImpl. remote
private ServiceLocator
CrossOverDescriptor. remoteLocator
Methods in org.glassfish.hk2.extras.hk2bridge.internal with parameters of type ServiceLocator Modifier and Type Method Description void
Hk2BridgeImpl. setRemote(ServiceLocator remote)
Constructors in org.glassfish.hk2.extras.hk2bridge.internal with parameters of type ServiceLocator Constructor Description CrossOverDescriptor(ServiceLocator local, ActiveDescriptor<T> localService)
Hk2BridgeImpl(ServiceLocator local)
-
Uses of ServiceLocator in org.glassfish.hk2.extras.interception.internal
Fields in org.glassfish.hk2.extras.interception.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
DefaultInterceptionService. locator
-
Uses of ServiceLocator in org.glassfish.hk2.extras.operation.internal
Fields in org.glassfish.hk2.extras.operation.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
OperationManagerImpl. locator
private ServiceLocator
SingleOperationManager. locator
Constructors in org.glassfish.hk2.extras.operation.internal with parameters of type ServiceLocator Constructor Description OperationHandleImpl(SingleOperationManager<T> parent, OperationIdentifier<T> identifier, java.lang.Object operationLock, ServiceLocator locator)
SingleOperationManager(T scope, ServiceLocator locator)
-
Uses of ServiceLocator in org.glassfish.hk2.internal
Fields in org.glassfish.hk2.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
ImmediateHelper. locator
Fields in org.glassfish.hk2.internal with type parameters of type ServiceLocator Modifier and Type Field Description private java.util.HashMap<java.lang.String,ServiceLocator>
ServiceLocatorFactoryImpl. serviceLocators
Methods in org.glassfish.hk2.internal that return ServiceLocator Modifier and Type Method Description ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name)
ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name, ServiceLocator parent)
ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator)
ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator, ServiceLocatorFactory.CreatePolicy policy)
ServiceLocator
ServiceLocatorFactoryImpl. find(java.lang.String name)
private ServiceLocator
ServiceLocatorFactoryImpl. internalCreate(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator)
Methods in org.glassfish.hk2.internal with parameters of type ServiceLocator Modifier and Type Method Description private void
ServiceLocatorFactoryImpl. callListenerAdded(ServiceLocator added)
ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name, ServiceLocator parent)
ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator)
ServiceLocator
ServiceLocatorFactoryImpl. create(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator, ServiceLocatorFactory.CreatePolicy policy)
private void
ServiceLocatorFactoryImpl. destroy(java.lang.String name, ServiceLocator locator)
void
ServiceLocatorFactoryImpl. destroy(ServiceLocator locator)
private ServiceLocator
ServiceLocatorFactoryImpl. internalCreate(java.lang.String name, ServiceLocator parent, ServiceLocatorGenerator generator)
Constructors in org.glassfish.hk2.internal with parameters of type ServiceLocator Constructor Description ImmediateHelper(ServiceLocator serviceLocator, ImmediateContext immediateContext)
-
Uses of ServiceLocator in org.glassfish.hk2.runlevel
Methods in org.glassfish.hk2.runlevel with parameters of type ServiceLocator Modifier and Type Method Description static void
RunLevelServiceUtilities. enableRunLevelService(ServiceLocator locator)
Enables the RunLevelService in the givenServiceLocator
. -
Uses of ServiceLocator in org.glassfish.hk2.runlevel.internal
Fields in org.glassfish.hk2.runlevel.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
AsyncRunLevelContext. locator
private ServiceLocator
CurrentTaskFuture.DownQueueRunner. locator
private ServiceLocator
CurrentTaskFuture. locator
private ServiceLocator
CurrentTaskFuture.QueueRunner. locator
Constructors in org.glassfish.hk2.runlevel.internal with parameters of type ServiceLocator Constructor Description AsyncRunLevelContext(ServiceLocator locator)
Constructor for the guy who does the workCurrentTaskFuture(AsyncRunLevelContext asyncContext, java.util.concurrent.Executor executor, ServiceLocator locator, int proposedLevel, int maxThreads, boolean useThreads, long cancelTimeout, java.util.Timer timer)
DownQueueRunner(java.lang.Object queueLock, java.util.List<ActiveDescriptor<?>> queue, CurrentTaskFuture.DownAllTheWay parent, ServiceLocator locator)
QueueRunner(ServiceLocator locator, AsyncRunLevelContext asyncContext, java.lang.Object queueLock, java.util.List<ServiceHandle<?>> queue, CurrentTaskFuture.UpOneLevel parent, java.lang.Object parentLock, int maxThreads)
-
Uses of ServiceLocator in org.glassfish.hk2.runlevel.utilities
Methods in org.glassfish.hk2.runlevel.utilities with parameters of type ServiceLocator Modifier and Type Method Description static int
Utilities. getRunLevelMode(ServiceLocator locator, Descriptor descriptor, java.lang.Integer modeOverride)
Get the run level mode from the metadata of the given descriptor.static int
Utilities. getRunLevelValue(ServiceLocator locator, Descriptor descriptor)
Get the run level value from the metadata of the given descriptor. -
Uses of ServiceLocator in org.glassfish.hk2.utilities
Fields in org.glassfish.hk2.utilities declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
AliasDescriptor. locator
The service locator.private ServiceLocator
GreedyResolver. locator
private ServiceLocator
ImmediateContext. locator
Methods in org.glassfish.hk2.utilities that return ServiceLocator Modifier and Type Method Description static ServiceLocator
ServiceLocatorUtilities. bind(java.lang.String name, Binder... binders)
This method will create or find a ServiceLocator with the given name and bind all of the binders given together in a single config transaction.static ServiceLocator
ServiceLocatorUtilities. bind(Binder... binders)
This method will create or find a ServiceLocator with the name "default" and bind all of the binders given together in a single config transaction.static ServiceLocator
ServiceLocatorUtilities. createAndPopulateServiceLocator()
This method is often the first line of a stand-alone client that wishes to use HK2.static ServiceLocator
ServiceLocatorUtilities. createAndPopulateServiceLocator(java.lang.String name)
This method is often the first line of a stand-alone client that wishes to use HK2.Methods in org.glassfish.hk2.utilities with parameters of type ServiceLocator Modifier and Type Method Description static java.util.List<ActiveDescriptor<?>>
ServiceLocatorUtilities. addClasses(ServiceLocator locator, boolean idempotent, java.lang.Class<?>... toAdd)
It is very often the case that one wishes to add classes that hk2 will automatically analyze for contracts and qualifiers to a service locator.static java.util.List<ActiveDescriptor<?>>
ServiceLocatorUtilities. addClasses(ServiceLocator locator, java.lang.Class<?>... toAdd)
It is very often the case that one wishes to add classes that hk2 will automatically analyze for contracts and qualifiers to a service locator.static java.util.List<FactoryDescriptors>
ServiceLocatorUtilities. addFactoryConstants(ServiceLocator locator, Factory<?>... constants)
This method adds factory constants to the given locator.static java.util.List<FactoryDescriptors>
ServiceLocatorUtilities. addFactoryDescriptors(ServiceLocator locator, boolean requiresDeepCopy, FactoryDescriptors... factories)
Adds the given factory descriptors to the service locatorstatic java.util.List<FactoryDescriptors>
ServiceLocatorUtilities. addFactoryDescriptors(ServiceLocator locator, FactoryDescriptors... factories)
Adds the given factory descriptors to the service locatorstatic <T> ActiveDescriptor<T>
ServiceLocatorUtilities. addOneConstant(ServiceLocator locator, java.lang.Object constant)
This method adds one existing object to the given service locator.static <T> ActiveDescriptor<T>
ServiceLocatorUtilities. addOneConstant(ServiceLocator locator, java.lang.Object constant, java.lang.String name, java.lang.reflect.Type... contracts)
This method adds one existing object to the given service locator.static <T> ActiveDescriptor<T>
ServiceLocatorUtilities. addOneDescriptor(ServiceLocator locator, Descriptor descriptor)
It is very often the case that one wishes to add a single descriptor to a service locator.static <T> ActiveDescriptor<T>
ServiceLocatorUtilities. addOneDescriptor(ServiceLocator locator, Descriptor descriptor, boolean requiresDeepCopy)
It is very often the case that one wishes to add a single descriptor to a service locator.static void
ServiceLocatorUtilities. bind(ServiceLocator locator, Binder... binders)
This method will bind all of the binders given together in a single config transaction.static DynamicConfiguration
ServiceLocatorUtilities. createDynamicConfiguration(ServiceLocator locator)
This method returns aDynamicConfiguration
for use with adding and removing services to the givenServiceLocator
.static void
ServiceLocatorUtilities. dumpAllDescriptors(ServiceLocator locator)
Dumps all descriptors in this ServiceLocator to stderrstatic void
ServiceLocatorUtilities. dumpAllDescriptors(ServiceLocator locator, java.io.PrintStream output)
Dumps all descriptors in this ServiceLocator to the given PrintStreamstatic void
ServiceLocatorUtilities. enableGreedyResolution(ServiceLocator locator)
Enables greedy service resolution in this service locator by adding theGreedyResolver
into the service locator.static void
ServiceLocatorUtilities. enableImmediateScope(ServiceLocator locator)
This method will add the ability to use theImmediate
scope to the given locator.static ImmediateController
ServiceLocatorUtilities. enableImmediateScopeSuspended(ServiceLocator locator)
This method will add the ability to use theImmediate
scope to the given locator.static void
ServiceLocatorUtilities. enableInheritableThreadScope(ServiceLocator locator)
This method will add the ability to use theInheritableThread
scope to the given locator.static void
ServiceLocatorUtilities. enableLookupExceptions(ServiceLocator locator)
This method will cause lookup operations to throw exceptions when exceptions are encountered in underlying operations such as classloading.static void
ServiceLocatorUtilities. enablePerThreadScope(ServiceLocator locator)
This method will add the ability to use thePerThread
scope to the given locator.static void
ServiceLocatorUtilities. enableTopicDistribution(ServiceLocator locator)
Deprecated.Use ExtrasUtilities.enableTopicDistribution.static <T> ActiveDescriptor<T>
ServiceLocatorUtilities. findOneDescriptor(ServiceLocator locator, Descriptor descriptor)
Finds a descriptor in the given service locator.static <T> T
ServiceLocatorUtilities. findOrCreateService(ServiceLocator locator, java.lang.Class<T> type, java.lang.annotation.Annotation... qualifiers)
This method will first attempt to find a service corresponding to the type and qualifiers passed in to the method, and if one is found simply returns it.static <T> T
ServiceLocatorUtilities. getService(ServiceLocator locator, java.lang.String className)
Returns the best service matching the passed in fully qualified class name of the servicestatic <T> T
ServiceLocatorUtilities. getService(ServiceLocator locator, Descriptor descriptor)
Returns the service in this service locator given the current descriptor.private DescriptorImpl
DuplicatePostProcessor. implementationOnly(ServiceLocator serviceLocator, DescriptorImpl descriptorImpl)
DescriptorImpl
ClassLoaderPostProcessor. process(ServiceLocator serviceLocator, DescriptorImpl descriptorImpl)
DescriptorImpl
DuplicatePostProcessor. process(ServiceLocator serviceLocator, DescriptorImpl descriptorImpl)
static void
ServiceLocatorUtilities. removeFilter(ServiceLocator locator, Filter filter)
Removes all the descriptors from the given locator that match the given filterstatic void
ServiceLocatorUtilities. removeFilter(ServiceLocator locator, Filter filter, boolean includeAliasDescriptors)
Removes all the descriptors from the given locator that match the given filterstatic void
ServiceLocatorUtilities. removeOneDescriptor(ServiceLocator locator, Descriptor descriptor)
This method will attempt to remove descriptors matching the passed in descriptor from the given locator.static void
ServiceLocatorUtilities. removeOneDescriptor(ServiceLocator locator, Descriptor descriptor, boolean includeAliasDescriptors)
This method will attempt to remove descriptors matching the passed in descriptor from the given locator.private DescriptorImpl
DuplicatePostProcessor. strict(ServiceLocator serviceLocator, DescriptorImpl descriptorImpl)
Constructors in org.glassfish.hk2.utilities with parameters of type ServiceLocator Constructor Description AliasDescriptor(ServiceLocator locator, ActiveDescriptor<T> descriptor, java.lang.String contract, java.lang.String name)
Construct an AliasDescriptor.GreedyResolver(ServiceLocator locator)
ImmediateContext(ServiceLocator locator)
-
Uses of ServiceLocator in org.jvnet.hk2.external.generator
Methods in org.jvnet.hk2.external.generator that return ServiceLocator Modifier and Type Method Description ServiceLocator
ServiceLocatorGeneratorImpl. create(java.lang.String name, ServiceLocator parent)
Methods in org.jvnet.hk2.external.generator with parameters of type ServiceLocator Modifier and Type Method Description ServiceLocator
ServiceLocatorGeneratorImpl. create(java.lang.String name, ServiceLocator parent)
private ServiceLocatorImpl
ServiceLocatorGeneratorImpl. initialize(java.lang.String name, ServiceLocator parent)
-
Uses of ServiceLocator in org.jvnet.hk2.internal
Classes in org.jvnet.hk2.internal that implement ServiceLocator Modifier and Type Class Description class
ServiceLocatorImpl
Fields in org.jvnet.hk2.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
FactoryCreator. locator
private ServiceLocator
PopulatorImpl. serviceLocator
Methods in org.jvnet.hk2.internal that return ServiceLocator Modifier and Type Method Description ServiceLocator
ServiceLocatorImpl. getParent()
Methods in org.jvnet.hk2.internal that return types with arguments of type ServiceLocator Modifier and Type Method Description static ActiveDescriptor<ServiceLocator>
Utilities. getLocatorDescriptor(ServiceLocator locator)
Returns a constant ActiveDescriptor for the basic ServiceLocatorMethods in org.jvnet.hk2.internal with parameters of type ServiceLocator Modifier and Type Method Description static ActiveDescriptor<ServiceLocator>
Utilities. getLocatorDescriptor(ServiceLocator locator)
Returns a constant ActiveDescriptor for the basic ServiceLocatorprivate ImmediateResults
ServiceLocatorImpl. narrow(ServiceLocator locator, java.util.List<SystemDescriptor<?>> candidates, java.lang.reflect.Type requiredType, java.lang.String name, Injectee injectee, boolean onlyOne, boolean doValidation, NarrowResults cachedResults, Filter filter, java.lang.annotation.Annotation... qualifiers)
private <T> T
ProxyUtilities. secureCreate(java.lang.Class<?> superclass, java.lang.Class<?>[] interfaces, javassist.util.proxy.MethodHandler callback, boolean useJDKProxy, ServiceLocator anchor)
We put the anchor as the value even though we don't use it in order to make it easier to catch memory leaks here.Constructors in org.jvnet.hk2.internal with parameters of type ServiceLocator Constructor Description DynamicConfigurationServiceImpl(ServiceLocator locator)
FactoryCreator(ServiceLocator locator, ActiveDescriptor<?> factoryDescriptor)
PopulatorImpl(ServiceLocator serviceLocator, DynamicConfigurationService dcs)
ServiceLocatorRuntimeImpl(ServiceLocator locator)
-
Uses of ServiceLocator in org.jvnet.hk2.testing.junit
Fields in org.jvnet.hk2.testing.junit declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
ServiceLocatorTestRule. serviceLocator
TheServiceLocator
in effect for the currently executing JUnit test method.protected ServiceLocator
HK2Runner. testLocator
Test classes can use this service locator as their private test locatorMethods in org.jvnet.hk2.testing.junit that return ServiceLocator Modifier and Type Method Description static ServiceLocator
HK2TestUtilities. create(java.lang.String name, ServiceLocator parent, HK2TestModule... modules)
Will create a ServiceLocator after doing test-specific bindings from the TestModulestatic ServiceLocator
HK2TestUtilities. create(java.lang.String name, HK2TestModule... modules)
protected ServiceLocator
ServiceLocatorTestRule. createServiceLocator(org.junit.runner.Description testDescription)
Creates and returns aServiceLocator
suitable for the JUnit test described by the suppliedDescription
.Methods in org.jvnet.hk2.testing.junit with parameters of type ServiceLocator Modifier and Type Method Description protected void
ServiceLocatorTestRule. configureServiceLocator(ServiceLocator serviceLocator, org.junit.runner.Description testDescription)
Configures the suppliedServiceLocator
for use by the test described by the suppliedDescription
.static ServiceLocator
HK2TestUtilities. create(java.lang.String name, ServiceLocator parent, HK2TestModule... modules)
Will create a ServiceLocator after doing test-specific bindings from the TestModuleprotected void
ServiceLocatorTestRule. performDependencyInjection(ServiceLocator serviceLocator, T test)
Performs HK2 dependency injection on thisServiceLocatorTestRule
and the supplied test instance, using the suppliedServiceLocator
as needed. -
Uses of ServiceLocator in org.jvnet.hk2.testing.junit.internal
Fields in org.jvnet.hk2.testing.junit.internal declared as ServiceLocator Modifier and Type Field Description private ServiceLocator
ClassVisitorImpl. locator
Constructors in org.jvnet.hk2.testing.junit.internal with parameters of type ServiceLocator Constructor Description ClassVisitorImpl(ServiceLocator locator, boolean verbose, java.util.Set<java.lang.String> excludes)
Creates this with the config to add to if this is a service
-