Class OperationDescriptor<T extends Annotation>
- java.lang.Object
-
- org.glassfish.hk2.utilities.DescriptorImpl
-
- org.glassfish.hk2.utilities.AbstractActiveDescriptor<OperationHandle<T>>
-
- org.glassfish.hk2.extras.operation.internal.OperationDescriptor<T>
-
- All Implemented Interfaces:
Externalizable
,Serializable
,ActiveDescriptor<OperationHandle<T>>
,Descriptor
,SingleCache<OperationHandle<T>>
public class OperationDescriptor<T extends Annotation> extends AbstractActiveDescriptor<OperationHandle<T>>
- Author:
- jwells
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description OperationDescriptor(T scope, SingleOperationManager<T> parent)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description OperationHandle<T>
create(ServiceHandle<?> root)
Creates an instance of the ActiveDescriptor.Class<?>
getImplementationClass()
The implementation class that should be used to generate new instances of this descriptor.Type
getImplementationType()
If known the Type of the implementation.void
setImplementationType(Type t)
-
Methods inherited from class org.glassfish.hk2.utilities.AbstractActiveDescriptor
addContractType, addQualifierAnnotation, dispose, equals, getCache, getContractTypes, getFactoryLocatorId, getFactoryServiceId, getInjectees, getQualifierAnnotations, getScopeAnnotation, getScopeAsAnnotation, hashCode, isCacheSet, isReified, releaseCache, removeContractType, removeQualifierAnnotation, setCache, setFactoryId, setName, setReified, setScopeAnnotation, setScopeAsAnnotation
-
Methods inherited from class org.glassfish.hk2.utilities.DescriptorImpl
addAdvertisedContract, addMetadata, addMetadata, addQualifier, clearMetadata, descriptorEquals, getAdvertisedContracts, getClassAnalysisName, getDescriptorType, getDescriptorVisibility, getImplementation, getLoader, getLocatorId, getMetadata, getName, getQualifiers, getRanking, getScope, getServiceId, isProxiable, isProxyForSameScope, pretty, readExternal, readObject, removeAdvertisedContract, removeAllMetadata, removeMetadata, removeQualifier, setClassAnalysisName, setDescriptorType, setDescriptorVisibility, setImplementation, setLoader, setLocatorId, setMetadata, setProxiable, setProxyForSameScope, setRanking, setScope, setServiceId, toString, writeExternal, writeObject
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.glassfish.hk2.api.Descriptor
getAdvertisedContracts, getClassAnalysisName, getDescriptorType, getDescriptorVisibility, getImplementation, getLoader, getLocatorId, getMetadata, getName, getQualifiers, getRanking, getScope, getServiceId, isProxiable, isProxyForSameScope, setRanking
-
-
-
-
Constructor Detail
-
OperationDescriptor
public OperationDescriptor(T scope, SingleOperationManager<T> parent)
-
-
Method Detail
-
getImplementationClass
public Class<?> getImplementationClass()
Description copied from interface:ActiveDescriptor
The implementation class that should be used to generate new instances of this descriptor.If the class returned is a Factory, then the factory is used to create instances. In this case the system will get an instance of the factory and use it to create the instances
- Returns:
- The class that directly implements the contract types, or the class that is the factory for an object that implements the contract types
-
getImplementationType
public Type getImplementationType()
Description copied from interface:ActiveDescriptor
If known the Type of the implementation. If unknown will return the same asActiveDescriptor.getImplementationClass()
- Returns:
- The type of the implementation or the implementation class
-
setImplementationType
public void setImplementationType(Type t)
- Overrides:
setImplementationType
in classAbstractActiveDescriptor<OperationHandle<T extends Annotation>>
-
create
public OperationHandle<T> create(ServiceHandle<?> root)
Description copied from interface:ActiveDescriptor
Creates an instance of the ActiveDescriptor. All of the Injectee's must be created prior to instantiation, and associated with the ExtendedProvider so that they can be destroyed properly- Parameters:
root
- The root service handle, which can be used to associated all the PerLookup objects with this creation- Returns:
- An instance of this ActiveDescriptor
-
-