| Modifier and Type | Class and Description |
|---|---|
| public static enum | PersistenceUnitProcessor.Mode
Passed to processORMetadata method to indicate processing mode. |
| Modifier and Type | Field and Description |
|---|---|
| public static ArchiveFactory | ARCHIVE_FACTORY
Cache the ArchiveFactory used to derive Archives. |
| private static final int | WEBINF_CLASSES_LEN
Length of application classes directory path String. |
| private static final String | WEBINF_CLASSES_STR
Path to application classes directory in WAR file. |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public static String | buildClassNameFromEntryString(String classEntryString)
Entries in a zip file are directory entries using slashes to separate them. |
| public static Set | Returns: a Set of class name stringsBuild a set that contains all the class names at a URL. |
| public static Collection | buildEntityList(MetadataProcessor processor, ClassLoader loader)
Create a list of the entities that will be deployed. |
| public static String | Returns: StringBuild the unique persistence name by concatenating the decoded URL with the persistence unit name. |
| public static URL | Returns: The URL of the PU root containing the resource.- URL of a resource belonging to the PU (obtained for
pxmlURL, String descriptorLocation via Classloader.getResource(String)).- the name of the resource. descriptorLocation)Determine the URL path to the persistence unit |
| public static Set | |
| public static Set | findPersistenceArchives(ClassLoader
the class loader to get the class path from loader)Search the classpath for persistence archives. |
| public static Set | findPersistenceArchives(ClassLoader
the class loader to get the class path from loader, String descriptorPath)Return a list of Archives representing the root of the persistence descriptor. |
| public static Set | findPersistenceArchives(ClassLoader
the class loader to get the class path from loader, String descriptorPath, List<URL> jarFileUrls, Map<K, V> properties)Return a list of Archives representing the root of the persistence descriptor. |
| private static URL | |
| public static ArchiveFactory | |
| public static ArchiveFactory | |
| public static Set | |
| public static MetadataAnnotation | getConverterAnnotation(MetadataClass candidateClass)
Return if a given class is annotated with @Embeddable. |
| public static MetadataAnnotation | getEmbeddableAnnotation(MetadataClass candidateClass)
Return if a given class is annotated with @Embeddable. |
| public static MetadataAnnotation | |
| public static MetadataAnnotation | getMappedSuperclassAnnotation(MetadataClass candidateClass)
Return if a given class is annotated with @Entity. |
| public static Set | |
| public static List | getPersistenceUnits(Archive
The url of a jar file or directory to check archive, ClassLoader loader)Get a list of persistence units from the file or directory at the given url. |
| public static MetadataAnnotation | getStaticMetamodelAnnotation(MetadataClass candidateClass)
Return the @StaticMetamodel annotation on the given class. |
| public static boolean | |
| public static boolean | |
| public static boolean | |
| public static boolean | isMappedSuperclass(MetadataClass candidateClass)
Return if a given class is annotated with @MappedSuperclass. |
| public static boolean | isStaticMetamodelClass(MetadataClass candidateClass)
Return if a given class is annotated with @StaticMetamodel. |
| private static boolean | Returns: true if the file-entry pair can be a persistence root according to JPA Spec (8.2).archive file URL. In case of a nested archive, this is
the URL of the innermost archive. file, String a directory entry in the archive (or an empty string).
In case of a nested archive, this is the entry in the innermost archive. rootEntry)
|
| public static Class | loadClass(String className, ClassLoader loader, boolean throwExceptionIfNotFound, MetadataProject project)
Load the given class name with the given class loader. |
| public static void | processORMetadata(MetadataProcessor processor, boolean throwExceptionOnFail, PersistenceUnitProcessor.
Process the Object/relational metadata from XML and annotations |
| public static List | processPersistenceArchive(Archive archive, ClassLoader loader)
Go through the jar file for this PersistenceUnitProcessor and process any XML provided in it. |
| private static List | processPersistenceXML(URL baseURL, InputStream input, ClassLoader loader)
Build a persistence.xml file into a SEPersistenceUnitInfo object. |
| public static void |
| ARCHIVE_FACTORY | back to summary |
|---|---|
| public static ArchiveFactory ARCHIVE_FACTORY Cache the ArchiveFactory used to derive Archives. This allows applications to set the ArchiveFactory | |
| WEBINF_CLASSES_LEN | back to summary |
|---|---|
| private static final int WEBINF_CLASSES_LEN Length of application classes directory path String. | |
| WEBINF_CLASSES_STR | back to summary |
|---|---|
| private static final String WEBINF_CLASSES_STR Path to application classes directory in WAR file. | |
| PersistenceUnitProcessor | back to summary |
|---|---|
| protected PersistenceUnitProcessor() Default constructor. | |
| buildClassNameFromEntryString | back to summary |
|---|---|
| public static String buildClassNameFromEntryString(String classEntryString) Entries in a zip file are directory entries using slashes to separate them. Build a class name using '.' instead of slash and removing the '.class' extension. | |
| buildClassSet | back to summary |
|---|---|
| public static Set Build a set that contains all the class names at a URL. | |
| buildEntityList | back to summary |
|---|---|
| public static Collection Create a list of the entities that will be deployed. This list is built from the information provided in the PersistenceUnitInfo argument. The list contains Classes specified in the PersistenceUnitInfo's class list and also files that are annotated with @Entity and @Embeddable in the jar files provided in the persistence info. This list of classes will used to build a deployment project and to decide what classes to weave. | |
| buildPersistenceUnitName | back to summary |
|---|---|
| public static String buildPersistenceUnitName(URL url, String puName) Build the unique persistence name by concatenating the decoded URL with the persistence unit name. A decoded URL is required while persisting on a multi-bytes OS.
| |
| computePURootURL | back to summary |
|---|---|
| public static URL computePURootURL(URL pxmlURL, String descriptorLocation) throws IOException, URISyntaxException Determine the URL path to the persistence unit
| |
| findPersistenceArchives | back to summary |
|---|---|
| public static Set Search the classpath for persistence archives. A persistence archive is defined as any part of the class path that contains a META-INF directory with a persistence.xml file in it. Return a list of the URLs of those files. Use the current thread's context classloader to get the classpath. We assume it is a URL class loader. | |
| findPersistenceArchives | back to summary |
|---|---|
| public static Set Search the classpath for persistence archives. A persistence archive is
defined as any part of the class path that contains a META-INF directory
with a persistence.xml file in it. Return a list of
| |
| findPersistenceArchives | back to summary |
|---|---|
| public static Set Return a list of Archives representing the root of the persistence descriptor. It is the caller's responsibility to close all the archives.
| |
| findPersistenceArchives | back to summary |
|---|---|
| public static Set Return a list of Archives representing the root of the persistence descriptor. It is the caller's responsibility to close all the archives.
| |
| fixUNC | back to summary |
|---|---|
| private static URL fixUNC(URL url) throws URISyntaxException, MalformedURLException, UnsupportedEncodingException This method fixes incorrect authority attribute that is set by JDK when UNC is used in classpath. See JDK bug #6585937 and GlassFish issue #3209 for more details. | |
| getArchiveFactory | back to summary |
|---|---|
| public static ArchiveFactory getArchiveFactory(ClassLoader loader) | |
| getArchiveFactory | back to summary |
|---|---|
| public static ArchiveFactory getArchiveFactory(ClassLoader loader, Map<K, V> properties) | |
| getClassNamesFromURL | back to summary |
|---|---|
| public static Set | |
| getConverterAnnotation | back to summary |
|---|---|
| public static MetadataAnnotation getConverterAnnotation(MetadataClass candidateClass) Return if a given class is annotated with @Embeddable. | |
| getEmbeddableAnnotation | back to summary |
|---|---|
| public static MetadataAnnotation getEmbeddableAnnotation(MetadataClass candidateClass) Return if a given class is annotated with @Embeddable. | |
| getEntityAnnotation | back to summary |
|---|---|
| public static MetadataAnnotation getEntityAnnotation(MetadataClass candidateClass) Return if a given class is annotated with @Entity. | |
| getMappedSuperclassAnnotation | back to summary |
|---|---|
| public static MetadataAnnotation getMappedSuperclassAnnotation(MetadataClass candidateClass) Return if a given class is annotated with @Entity. | |
| getPersistenceUnits | back to summary |
|---|---|
| public static Set | |
| getPersistenceUnits | back to summary |
|---|---|
| public static List Get a list of persistence units from the file or directory at the given url. PersistenceUnits are built based on the presence of a persistence descriptor *
| |
| getStaticMetamodelAnnotation | back to summary |
|---|---|
| public static MetadataAnnotation getStaticMetamodelAnnotation(MetadataClass candidateClass) Return the @StaticMetamodel annotation on the given class. | |
| isConverter | back to summary |
|---|---|
| public static boolean isConverter(MetadataClass candidateClass) Return if a given class is annotated with @Converter. | |
| isEmbeddable | back to summary |
|---|---|
| public static boolean isEmbeddable(MetadataClass candidateClass) Return if a given class is annotated with @Embeddable. | |
| isEntity | back to summary |
|---|---|
| public static boolean isEntity(MetadataClass candidateClass) Return if a given class is annotated with @Entity. | |
| isMappedSuperclass | back to summary |
|---|---|
| public static boolean isMappedSuperclass(MetadataClass candidateClass) Return if a given class is annotated with @MappedSuperclass. | |
| isStaticMetamodelClass | back to summary |
|---|---|
| public static boolean isStaticMetamodelClass(MetadataClass candidateClass) Return if a given class is annotated with @StaticMetamodel. | |
| isValidRootInArchive | back to summary |
|---|---|
private static boolean isValidRootInArchive(String file, String rootEntry)
| |
| loadClass | back to summary |
|---|---|
| public static Class Load the given class name with the given class loader. | |
| processORMetadata | back to summary |
|---|---|
| public static void processORMetadata(MetadataProcessor processor, boolean throwExceptionOnFail, PersistenceUnitProcessor. Process the Object/relational metadata from XML and annotations | |
| processPersistenceArchive | back to summary |
|---|---|
| public static List Go through the jar file for this PersistenceUnitProcessor and process any XML provided in it. | |
| processPersistenceXML | back to summary |
|---|---|
| private static List Build a persistence.xml file into a SEPersistenceUnitInfo object. May eventually change this to use OX mapping as well. | |
| setArchiveFactory | back to summary |
|---|---|
| public static void setArchiveFactory(ArchiveFactory factory) | |
| Modifier and Type | Field and Description |
|---|---|
| public static final PersistenceUnitProcessor. | |
| public static final PersistenceUnitProcessor. | |
| public static final PersistenceUnitProcessor. | |
| public static final PersistenceUnitProcessor. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static PersistenceUnitProcessor. | |
| public static PersistenceUnitProcessor. |
| ALL | back to summary |
|---|---|
| public static final PersistenceUnitProcessor. | |
| COMPOSITE_MEMBER_FINAL | back to summary |
|---|---|
| public static final PersistenceUnitProcessor. | |
| COMPOSITE_MEMBER_INITIAL | back to summary |
|---|---|
| public static final PersistenceUnitProcessor. | |
| COMPOSITE_MEMBER_MIDDLE | back to summary |
|---|---|
| public static final PersistenceUnitProcessor. | |
| Mode | back to summary |
|---|---|
| private Mode() | |
| valueOf | back to summary |
|---|---|
| public static PersistenceUnitProcessor. | |
| values | back to summary |
|---|---|
| public static PersistenceUnitProcessor. | |