|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.openjpa.persistence.PersistenceUnitInfoImpl
public class PersistenceUnitInfoImpl
Implementation of the PersistenceUnitInfo interface used by OpenJPA
when parsing persistence configuration information.
| Nested Class Summary | |
|---|---|
static class |
PersistenceUnitInfoImpl.ClassResolverImpl
Simple class resolver built around the persistence unit loader. |
| Field Summary | |
|---|---|
static java.lang.String |
KEY_PROVIDER
|
| Fields inherited from interface org.apache.openjpa.lib.meta.SourceTracker |
|---|
SRC_ANNOTATIONS, SRC_OTHER, SRC_XML |
| Constructor Summary | |
|---|---|
PersistenceUnitInfoImpl()
|
|
| Method Summary | |
|---|---|
void |
addJarFile(java.net.URL jar)
|
void |
addJarFileName(java.lang.String name)
|
void |
addManagedClassName(java.lang.String name)
|
void |
addMappingFileName(java.lang.String name)
|
void |
addTransformer(javax.persistence.spi.ClassTransformer transformer)
|
boolean |
excludeUnlistedClasses()
|
void |
fromUserProperties(java.util.Map map)
Load the given user-supplied map of properties into this persistence unit. |
java.lang.ClassLoader |
getClassLoader()
|
java.util.List<java.net.URL> |
getJarFileUrls()
|
javax.sql.DataSource |
getJtaDataSource()
|
java.lang.String |
getJtaDataSourceName()
|
java.util.List<java.lang.String> |
getManagedClassNames()
|
java.util.List<java.lang.String> |
getMappingFileNames()
|
java.lang.ClassLoader |
getNewTempClassLoader()
|
javax.sql.DataSource |
getNonJtaDataSource()
|
java.lang.String |
getNonJtaDataSourceName()
|
java.lang.String |
getPersistenceProviderClassName()
|
java.lang.String |
getPersistenceUnitName()
|
java.net.URL |
getPersistenceUnitRootUrl()
|
java.net.URL |
getPersistenceXmlFileUrl()
The location of the persistence.xml resource. |
java.util.Properties |
getProperties()
|
java.lang.String |
getResourceName()
|
java.io.File |
getSourceFile()
|
java.lang.Object |
getSourceScope()
|
int |
getSourceType()
|
javax.persistence.spi.PersistenceUnitTransactionType |
getTransactionType()
|
void |
setExcludeUnlistedClasses(boolean excludeUnlisted)
|
void |
setJtaDataSource(javax.sql.DataSource ds)
|
void |
setJtaDataSourceName(java.lang.String jta)
|
void |
setNonJtaDataSource(javax.sql.DataSource ds)
|
void |
setNonJtaDataSourceName(java.lang.String nonJta)
|
void |
setPersistenceProviderClassName(java.lang.String providerClassName)
|
void |
setPersistenceUnitName(java.lang.String emName)
|
void |
setPersistenceUnitRootUrl(java.net.URL root)
|
void |
setPersistenceXmlFileUrl(java.net.URL url)
The location of the persistence.xml resource. |
void |
setProperty(java.lang.String key,
java.lang.String value)
|
void |
setTransactionType(javax.persistence.spi.PersistenceUnitTransactionType transType)
|
java.util.Map |
toOpenJPAProperties()
Return a Map containing the properties necessary to create
a Configuration that reflects the information in this
persistence unit info. |
static java.util.Map |
toOpenJPAProperties(javax.persistence.spi.PersistenceUnitInfo info)
Return a Map containing the properties necessary to create
a Configuration that reflects the information in the given
persistence unit info. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String KEY_PROVIDER
| Constructor Detail |
|---|
public PersistenceUnitInfoImpl()
| Method Detail |
|---|
public java.lang.ClassLoader getClassLoader()
getClassLoader in interface javax.persistence.spi.PersistenceUnitInfopublic java.lang.ClassLoader getNewTempClassLoader()
getNewTempClassLoader in interface javax.persistence.spi.PersistenceUnitInfopublic java.lang.String getPersistenceUnitName()
getPersistenceUnitName in interface javax.persistence.spi.PersistenceUnitInfopublic void setPersistenceUnitName(java.lang.String emName)
public java.lang.String getPersistenceProviderClassName()
getPersistenceProviderClassName in interface javax.persistence.spi.PersistenceUnitInfopublic void setPersistenceProviderClassName(java.lang.String providerClassName)
public javax.persistence.spi.PersistenceUnitTransactionType getTransactionType()
getTransactionType in interface javax.persistence.spi.PersistenceUnitInfopublic void setTransactionType(javax.persistence.spi.PersistenceUnitTransactionType transType)
public java.lang.String getJtaDataSourceName()
public void setJtaDataSourceName(java.lang.String jta)
public javax.sql.DataSource getJtaDataSource()
getJtaDataSource in interface javax.persistence.spi.PersistenceUnitInfopublic void setJtaDataSource(javax.sql.DataSource ds)
public java.lang.String getNonJtaDataSourceName()
public void setNonJtaDataSourceName(java.lang.String nonJta)
public javax.sql.DataSource getNonJtaDataSource()
getNonJtaDataSource in interface javax.persistence.spi.PersistenceUnitInfopublic void setNonJtaDataSource(javax.sql.DataSource ds)
public java.net.URL getPersistenceUnitRootUrl()
getPersistenceUnitRootUrl in interface javax.persistence.spi.PersistenceUnitInfopublic void setPersistenceUnitRootUrl(java.net.URL root)
public boolean excludeUnlistedClasses()
excludeUnlistedClasses in interface javax.persistence.spi.PersistenceUnitInfopublic void setExcludeUnlistedClasses(boolean excludeUnlisted)
public java.util.List<java.lang.String> getMappingFileNames()
getMappingFileNames in interface javax.persistence.spi.PersistenceUnitInfopublic void addMappingFileName(java.lang.String name)
public java.util.List<java.net.URL> getJarFileUrls()
getJarFileUrls in interface javax.persistence.spi.PersistenceUnitInfopublic void addJarFile(java.net.URL jar)
public void addJarFileName(java.lang.String name)
public java.util.List<java.lang.String> getManagedClassNames()
getManagedClassNames in interface javax.persistence.spi.PersistenceUnitInfopublic void addManagedClassName(java.lang.String name)
public java.util.Properties getProperties()
getProperties in interface javax.persistence.spi.PersistenceUnitInfo
public void setProperty(java.lang.String key,
java.lang.String value)
public void addTransformer(javax.persistence.spi.ClassTransformer transformer)
addTransformer in interface javax.persistence.spi.PersistenceUnitInfopublic java.net.URL getPersistenceXmlFileUrl()
public void setPersistenceXmlFileUrl(java.net.URL url)
public void fromUserProperties(java.util.Map map)
public java.util.Map toOpenJPAProperties()
Map containing the properties necessary to create
a Configuration that reflects the information in this
persistence unit info.
public static java.util.Map toOpenJPAProperties(javax.persistence.spi.PersistenceUnitInfo info)
Map containing the properties necessary to create
a Configuration that reflects the information in the given
persistence unit info.
public java.io.File getSourceFile()
getSourceFile in interface SourceTrackerpublic java.lang.Object getSourceScope()
getSourceScope in interface SourceTrackerpublic int getSourceType()
getSourceType in interface SourceTrackerpublic java.lang.String getResourceName()
getResourceName in interface SourceTracker
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||