Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.springframework.orm.jpa.persistenceunit
Class MutablePersistenceUnitInfo

    java.lang.Object
      org.springframework.orm.jpa.persistenceunit.MutablePersistenceUnitInfo

All Implemented Interfaces:
  PersistenceUnitInfo, SmartPersistenceUnitInfo

    public class MutablePersistenceUnitInfo

extends Object
implements SmartPersistenceUnitInfo

Spring's base implementation of the JPA `PersistenceUnitInfo` interface, used to bootstrap an EntityManagerFactory in a container.

This implementation is largely a JavaBean, offering mutators for all standard PersistenceUnitInfo properties.

Since:
  2.0
Author:
  Rod Johnson, Juergen Hoeller, Costin Leau

Constructor Summary
`MutablePersistenceUnitInfo()`

Method Summary
`void` | `addJarFileUrl(URL jarFileUrl)`
`void` | `addManagedClassName(String managedClassName)`
`void` | `addMappingFileName(String mappingFileName)`
`void` | `addProperty(String name, String value)`
`void` | `addTransformer(ClassTransformer classTransformer)` This implementation throws an UnsupportedOperationException.
`boolean` | `excludeUnlistedClasses()`
`ClassLoader` | `getClassLoader()` This implementation returns the default ClassLoader.
`List<URL>` | `getJarFileUrls()`
`DataSource` | `getJtaDataSource()`
`List<String>` | `getManagedClassNames()`
`List<String>` | `getMappingFileNames()`
`ClassLoader` | `getNewTempClassLoader()` This implementation throws an UnsupportedOperationException.
`DataSource` | `getNonJtaDataSource()`
`String` | `getPersistenceProviderClassName()`
`String` | `getPersistenceProviderPackageName()`
`String` | `getPersistenceUnitName()`
`URL` | `getPersistenceUnitRootUrl()`
`String` | `getPersistenceXMLSchemaVersion()`
`Properties` | `getProperties()`
`PersistenceUnitTransactionType` | `getTransactionType()`
`void` | `setExcludeUnlistedClasses(boolean excludeUnlistedClasses)`
`void` | `setJtaDataSource(DataSource jtaDataSource)`
`void` | `setNonJtaDataSource(DataSource nonJtaDataSource)`
`void` | `setPersistenceProviderClassName(String persistenceProviderClassName)`
`void` | `setPersistenceProviderPackageName(String persistenceProviderPackageName)` Set the persistence provider's own package name, for exclusion from class transformation.
`void` | `setPersistenceUnitName(String persistenceUnitName)`
`void` | `setPersistenceUnitRootUrl(URL persistenceUnitRootUrl)`
`void` | `setPersistenceXMLSchemaVersion(String persistenceXMLSchemaVersion)`
`void` | `setProperties(Properties properties)`
`void` | `setTransactionType(PersistenceUnitTransactionType transactionType)`
`String` | `toString()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### MutablePersistenceUnitInfo

    public MutablePersistenceUnitInfo()

Method Detail

### setPersistenceUnitName

    public void setPersistenceUnitName(String persistenceUnitName)

### getPersistenceUnitName

    public String getPersistenceUnitName()

  Specified by:
    `getPersistenceUnitName` in interface `PersistenceUnitInfo`

### setPersistenceProviderClassName

    public void setPersistenceProviderClassName(String persistenceProviderClassName)

### getPersistenceProviderClassName

    public String getPersistenceProviderClassName()

  Specified by:
    `getPersistenceProviderClassName` in interface `PersistenceUnitInfo`

### setTransactionType

    public void setTransactionType(PersistenceUnitTransactionType transactionType)

### getTransactionType

    public PersistenceUnitTransactionType getTransactionType()

  Specified by:
    `getTransactionType` in interface `PersistenceUnitInfo`

### setJtaDataSource

    public void setJtaDataSource(DataSource jtaDataSource)

### getJtaDataSource

    public DataSource getJtaDataSource()

  Specified by:
    `getJtaDataSource` in interface `PersistenceUnitInfo`

### setNonJtaDataSource

    public void setNonJtaDataSource(DataSource nonJtaDataSource)

### getNonJtaDataSource

    public DataSource getNonJtaDataSource()

  Specified by:
    `getNonJtaDataSource` in interface `PersistenceUnitInfo`

### addMappingFileName

    public void addMappingFileName(String mappingFileName)

### getMappingFileNames

    public List<String> getMappingFileNames()

  Specified by:
    `getMappingFileNames` in interface `PersistenceUnitInfo`

### addJarFileUrl

    public void addJarFileUrl(URL jarFileUrl)

### getJarFileUrls

    public List<URL> getJarFileUrls()

  Specified by:
    `getJarFileUrls` in interface `PersistenceUnitInfo`

### setPersistenceUnitRootUrl

    public void setPersistenceUnitRootUrl(URL persistenceUnitRootUrl)

### getPersistenceUnitRootUrl

    public URL getPersistenceUnitRootUrl()

  Specified by:
    `getPersistenceUnitRootUrl` in interface `PersistenceUnitInfo`

### addManagedClassName

    public void addManagedClassName(String managedClassName)

### getManagedClassNames

    public List<String> getManagedClassNames()

  Specified by:
    `getManagedClassNames` in interface `PersistenceUnitInfo`

### setExcludeUnlistedClasses

    public void setExcludeUnlistedClasses(boolean excludeUnlistedClasses)

### excludeUnlistedClasses

    public boolean excludeUnlistedClasses()

  Specified by:
    `excludeUnlistedClasses` in interface `PersistenceUnitInfo`

### addProperty

    public void addProperty(String name,
                            String value)

### setProperties

    public void setProperties(Properties properties)

### getProperties

    public Properties getProperties()

  Specified by:
    `getProperties` in interface `PersistenceUnitInfo`

### setPersistenceXMLSchemaVersion

    public void setPersistenceXMLSchemaVersion(String persistenceXMLSchemaVersion)

### getPersistenceXMLSchemaVersion

    public String getPersistenceXMLSchemaVersion()

### setPersistenceProviderPackageName

    public void setPersistenceProviderPackageName(String persistenceProviderPackageName)

  Description copied from interface: `SmartPersistenceUnitInfo`
  Set the persistence provider's own package name, for exclusion from class transformation.

  Specified by:
    `setPersistenceProviderPackageName` in interface `SmartPersistenceUnitInfo`
  See Also:
    `PersistenceUnitInfo.addTransformer(javax.persistence.spi.ClassTransformer)`, `PersistenceUnitInfo.getNewTempClassLoader()`

### getPersistenceProviderPackageName

    public String getPersistenceProviderPackageName()

### getClassLoader

    public ClassLoader getClassLoader()

  This implementation returns the default ClassLoader.

  Specified by:
    `getClassLoader` in interface `PersistenceUnitInfo`
  See Also:
    `ClassUtils.getDefaultClassLoader()`

### addTransformer

    public void addTransformer(ClassTransformer classTransformer)

  This implementation throws an UnsupportedOperationException.

  Specified by:
    `addTransformer` in interface `PersistenceUnitInfo`

### getNewTempClassLoader

    public ClassLoader getNewTempClassLoader()

  This implementation throws an UnsupportedOperationException.

  Specified by:
    `getNewTempClassLoader` in interface `PersistenceUnitInfo`

### toString

    public String toString()

  Overrides:
    `toString` in class `Object`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD