Package org.glassfish.persistence.jpa
Class ProviderContainerContractInfoBase
- java.lang.Object
-
- org.glassfish.persistence.jpa.ProviderContainerContractInfoBase
-
- All Implemented Interfaces:
ProviderContainerContractInfo
- Direct Known Subclasses:
ServerProviderContainerContractInfo
public abstract class ProviderContainerContractInfoBase extends Object implements ProviderContainerContractInfo
Convenience base class for implementing ProviderContainerContractInfo.- Author:
- Mitesh Meswani
-
-
Field Summary
-
Fields inherited from interface org.glassfish.persistence.jpa.ProviderContainerContractInfo
DEFAULT_DS_NAME
-
-
Constructor Summary
Constructors Constructor Description ProviderContainerContractInfoBase(com.sun.appserv.connectors.internal.api.ConnectorRuntime connectorRuntime)ProviderContainerContractInfoBase(com.sun.appserv.connectors.internal.api.ConnectorRuntime connectorRuntime, org.glassfish.api.deployment.DeploymentContext context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetDefaultDataSourceName()booleanisWeavingEnabled()DataSourcelookupDataSource(String dataSourceName)Looks up DataSource with JNDI name given bydataSourceNameDataSourcelookupNonTxDataSource(String dataSourceName)Looks up Non transactional DataSource with JNDI name given bydataSourceName-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.glassfish.persistence.jpa.ProviderContainerContractInfo
addTransformer, getApplicationLocation, getClassLoader, getDeploymentContext, getJTADataSourceOverride, getTempClassloader, getValidatorFactory, isJava2DBRequired, registerEMF
-
-
-
-
Constructor Detail
-
ProviderContainerContractInfoBase
public ProviderContainerContractInfoBase(com.sun.appserv.connectors.internal.api.ConnectorRuntime connectorRuntime)
-
ProviderContainerContractInfoBase
public ProviderContainerContractInfoBase(com.sun.appserv.connectors.internal.api.ConnectorRuntime connectorRuntime, org.glassfish.api.deployment.DeploymentContext context)
-
-
Method Detail
-
lookupDataSource
public DataSource lookupDataSource(String dataSourceName) throws NamingException
Description copied from interface:ProviderContainerContractInfoLooks up DataSource with JNDI name given bydataSourceName- Specified by:
lookupDataSourcein interfaceProviderContainerContractInfo- Returns:
- DataSource with JNDI name given by
dataSourceName - Throws:
NamingException
-
lookupNonTxDataSource
public DataSource lookupNonTxDataSource(String dataSourceName) throws NamingException
Description copied from interface:ProviderContainerContractInfoLooks up Non transactional DataSource with JNDI name given bydataSourceName- Specified by:
lookupNonTxDataSourcein interfaceProviderContainerContractInfo- Returns:
- Non transactional DataSource with JNDI name given by
dataSourceName - Throws:
NamingException
-
getDefaultDataSourceName
public String getDefaultDataSourceName()
- Specified by:
getDefaultDataSourceNamein interfaceProviderContainerContractInfo- Returns:
- default data source name to be used if user has not defined a data source
-
isWeavingEnabled
public boolean isWeavingEnabled()
- Specified by:
isWeavingEnabledin interfaceProviderContainerContractInfo- Returns:
- true if weaving is enabled for the current environment false otherwise
-
-