Class ArchiveFactoryImpl
- java.lang.Object
-
- org.eclipse.persistence.internal.jpa.deployment.ArchiveFactoryImpl
-
- All Implemented Interfaces:
ArchiveFactory
public class ArchiveFactoryImpl extends java.lang.Object implements ArchiveFactory
This class is written to deal with various URLs that can be returned byPersistenceUnitInfo.getPersistenceUnitRootUrl()
- Author:
- [email protected]
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.logging.Logger
logger
-
Constructor Summary
Constructors Constructor Description ArchiveFactoryImpl()
ArchiveFactoryImpl(java.util.logging.Logger logger)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Archive
createArchive(java.net.URL rootUrl, java.lang.String descriptorLocation, java.util.Map properties)
Return an instance of an implementer of Archive that can process the URL provided This instance will allow access to the persistence descriptor associated with this archive through the getDescriptorStream() methodArchive
createArchive(java.net.URL rootUrl, java.util.Map properties)
Return an instance of an implementer of Archive that can process the URL providedprotected boolean
isJarInputStream(java.net.URL url)
This method is called for a URL which has neither jar nor file protocol.
-
-
-
Method Detail
-
createArchive
public Archive createArchive(java.net.URL rootUrl, java.util.Map properties) throws java.net.URISyntaxException, java.io.IOException
Description copied from interface:ArchiveFactory
Return an instance of an implementer of Archive that can process the URL provided- Specified by:
createArchive
in interfaceArchiveFactory
- Throws:
java.net.URISyntaxException
java.io.IOException
-
createArchive
public Archive createArchive(java.net.URL rootUrl, java.lang.String descriptorLocation, java.util.Map properties) throws java.net.URISyntaxException, java.io.IOException
Description copied from interface:ArchiveFactory
Return an instance of an implementer of Archive that can process the URL provided This instance will allow access to the persistence descriptor associated with this archive through the getDescriptorStream() method- Specified by:
createArchive
in interfaceArchiveFactory
- Throws:
java.net.URISyntaxException
java.io.IOException
-
isJarInputStream
protected boolean isJarInputStream(java.net.URL url) throws java.io.IOException
This method is called for a URL which has neither jar nor file protocol. This attempts to find out if we can treat it as a URL from which a JAR format InputStream can be obtained.- Parameters:
url
-- Throws:
java.io.IOException
-
-