Package org.jboss.as.jpa.injectors
Class PersistenceContextInjectionSource
- java.lang.Object
-
- org.jboss.as.ee.component.InjectionSource
-
- org.jboss.as.jpa.injectors.PersistenceContextInjectionSource
-
public class PersistenceContextInjectionSource extends InjectionSource
Represents the PersistenceContext injected into a component.- Author:
- Scott Marlow
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.jboss.as.ee.component.InjectionSource
InjectionSource.ResolutionContext
-
-
Constructor Summary
Constructors Constructor Description PersistenceContextInjectionSource(jakarta.persistence.PersistenceContextType type, jakarta.persistence.SynchronizationType synchronizationType, Map properties, org.jboss.msc.service.ServiceName puServiceName, org.jboss.msc.service.ServiceRegistry serviceRegistry, String scopedPuName, String injectionTypeName, PersistenceUnitMetadata pu, JPADeploymentSettings jpaDeploymentSettings)Constructor for the PersistenceContextInjectorService
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object other)voidgetResourceValue(InjectionSource.ResolutionContext resolutionContext, org.jboss.msc.service.ServiceBuilder<?> serviceBuilder, org.jboss.as.server.deployment.DeploymentPhaseContext phaseContext, org.jboss.msc.inject.Injector<ManagedReferenceFactory> injector)inthashCode()
-
-
-
Constructor Detail
-
PersistenceContextInjectionSource
public PersistenceContextInjectionSource(jakarta.persistence.PersistenceContextType type, jakarta.persistence.SynchronizationType synchronizationType, Map properties, org.jboss.msc.service.ServiceName puServiceName, org.jboss.msc.service.ServiceRegistry serviceRegistry, String scopedPuName, String injectionTypeName, PersistenceUnitMetadata pu, JPADeploymentSettings jpaDeploymentSettings)Constructor for the PersistenceContextInjectorService- Parameters:
type- The persistence context typeproperties- The persistence context propertiespuServiceName- represents the deployed persistence.xml that we are going to use.serviceRegistry- The MSC service registry which will be used to find the PersistenceContext servicescopedPuName- the fully scoped reference to the persistence.xmlinjectionTypeName- is normally "jakarta.persistence.EntityManager" but could be a different target class for example "org.hibernate.Session" in which case, EntityManager.unwrap(org.hibernate.Session.class is called)pu-jpaDeploymentSettings- OptionalJPADeploymentSettingsapplicable for the persistence context
-
-
Method Detail
-
getResourceValue
public void getResourceValue(InjectionSource.ResolutionContext resolutionContext, org.jboss.msc.service.ServiceBuilder<?> serviceBuilder, org.jboss.as.server.deployment.DeploymentPhaseContext phaseContext, org.jboss.msc.inject.Injector<ManagedReferenceFactory> injector) throws org.jboss.as.server.deployment.DeploymentUnitProcessingException
- Specified by:
getResourceValuein classInjectionSource- Throws:
org.jboss.as.server.deployment.DeploymentUnitProcessingException
-
-