persistence.xml files.
| Modifier and Type | Field and Description |
|---|---|
| private final DataSourceLookup | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final Log | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String | |
| private final ResourcePatternResolver | |
| private static final String | |
| private static final String | |
| private static final String | |
| private static final String |
| Access | Constructor and Description |
|---|---|
| public | PersistenceUnitReader(ResourcePatternResolver
the ResourcePatternResolver to use for loading resources resourcePatternResolver, DataSourceLookup the DataSourceLookup to resolve DataSource names in
dataSourceLookup)persistence.xml files againstCreate a new PersistenceUnitReader. |
| Modifier and Type | Method and Description |
|---|---|
| protected Document | buildDocument(ErrorHandler handler, InputStream stream)
Validate the given stream and return a valid DOM document for parsing. |
| pack-priv static URL | Returns: the corresponding persistence unit root URLthe resource to check resource)Determine the persistence unit root URL based on the given resource
(which points to the |
| protected List | parseDocument(Resource resource, Document document, List<SpringPersistenceUnitInfo> infos)
Parse the validated document and add entries to the given unit info list. |
| protected void | parseJarFiles(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo)
Parse the |
| protected void | parseManagedClasses(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo)
Parse the |
| protected void | parseMappingFiles(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo)
Parse the |
| protected SpringPersistenceUnitInfo | parsePersistenceUnitInfo(Element persistenceUnit, String version, URL rootUrl)
Parse the unit info DOM element. |
| protected void | parseProperties(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo)
Parse the |
| public SpringPersistenceUnitInfo[] | Returns: the resulting PersistenceUnitInfo instancesthe resource location (can be a pattern) persistenceXmlLocation)Parse and build all persistence unit infos defined in the specified XML file(s). |
| public SpringPersistenceUnitInfo[] | Returns: the resulting PersistenceUnitInfo instancesthe resource locations (can be patterns) persistenceXmlLocations)Parse and build all persistence unit infos defined in the given XML files. |
| dataSourceLookup | back to summary |
|---|---|
| private final DataSourceLookup dataSourceLookup | |
| EXCLUDE_UNLISTED_CLASSES | back to summary |
|---|---|
| private static final String EXCLUDE_UNLISTED_CLASSES | |
| JAR_FILE_URL | back to summary |
|---|---|
| private static final String JAR_FILE_URL | |
| JTA_DATA_SOURCE | back to summary |
|---|---|
| private static final String JTA_DATA_SOURCE | |
| logger | back to summary |
|---|---|
| private static final Log logger | |
| MANAGED_CLASS_NAME | back to summary |
|---|---|
| private static final String MANAGED_CLASS_NAME | |
| MAPPING_FILE_NAME | back to summary |
|---|---|
| private static final String MAPPING_FILE_NAME | |
| META_INF | back to summary |
|---|---|
| private static final String META_INF | |
| NON_JTA_DATA_SOURCE | back to summary |
|---|---|
| private static final String NON_JTA_DATA_SOURCE | |
| PERSISTENCE_UNIT | back to summary |
|---|---|
| private static final String PERSISTENCE_UNIT | |
| PERSISTENCE_VERSION | back to summary |
|---|---|
| private static final String PERSISTENCE_VERSION | |
| PROPERTIES | back to summary |
|---|---|
| private static final String PROPERTIES | |
| PROVIDER | back to summary |
|---|---|
| private static final String PROVIDER | |
| resourcePatternResolver | back to summary |
|---|---|
| private final ResourcePatternResolver resourcePatternResolver | |
| SHARED_CACHE_MODE | back to summary |
|---|---|
| private static final String SHARED_CACHE_MODE | |
| TRANSACTION_TYPE | back to summary |
|---|---|
| private static final String TRANSACTION_TYPE | |
| UNIT_NAME | back to summary |
|---|---|
| private static final String UNIT_NAME | |
| VALIDATION_MODE | back to summary |
|---|---|
| private static final String VALIDATION_MODE | |
| PersistenceUnitReader | back to summary |
|---|---|
| public PersistenceUnitReader(ResourcePatternResolver resourcePatternResolver, DataSourceLookup dataSourceLookup) Create a new PersistenceUnitReader.
| |
| buildDocument | back to summary |
|---|---|
| protected Document buildDocument(ErrorHandler handler, InputStream stream) throws ParserConfigurationException, SAXException, IOException Validate the given stream and return a valid DOM document for parsing. | |
| determinePersistenceUnitRootUrl | back to summary |
|---|---|
| pack-priv static URL determinePersistenceUnitRootUrl(Resource resource) throws IOException Determine the persistence unit root URL based on the given resource
(which points to the
| |
| parseDocument | back to summary |
|---|---|
| protected List Parse the validated document and add entries to the given unit info list. | |
| parseJarFiles | back to summary |
|---|---|
| protected void parseJarFiles(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo) throws IOException Parse the | |
| parseManagedClasses | back to summary |
|---|---|
| protected void parseManagedClasses(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo) Parse the | |
| parseMappingFiles | back to summary |
|---|---|
| protected void parseMappingFiles(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo) Parse the | |
| parsePersistenceUnitInfo | back to summary |
|---|---|
| protected SpringPersistenceUnitInfo parsePersistenceUnitInfo(Element persistenceUnit, String version, URL rootUrl) throws IOException Parse the unit info DOM element. | |
| parseProperties | back to summary |
|---|---|
| protected void parseProperties(Element persistenceUnit, SpringPersistenceUnitInfo unitInfo) Parse the | |
| readPersistenceUnitInfos | back to summary |
|---|---|
| public SpringPersistenceUnitInfo[] readPersistenceUnitInfos(String persistenceXmlLocation) Parse and build all persistence unit infos defined in the specified XML file(s).
| |
| readPersistenceUnitInfos | back to summary |
|---|---|
| public SpringPersistenceUnitInfo[] readPersistenceUnitInfos(String[] persistenceXmlLocations) Parse and build all persistence unit infos defined in the given XML files.
| |