org.eclipse.modisco.jee.actions
Class AbstractDeploymentDescriptorDiscoverer<T>
java.lang.Object
org.eclipse.modisco.infra.discovery.core.AbstractDiscoverer<T>
org.eclipse.modisco.infra.discovery.core.AbstractModelDiscoverer<T>
org.eclipse.modisco.jee.actions.AbstractDeploymentDescriptorDiscoverer<T>
- All Implemented Interfaces:
- IDiscoverer<T>
- Direct Known Subclasses:
- EjbJarDiscoverer2, WebXmlDiscoverer2
public abstract class AbstractDeploymentDescriptorDiscoverer<T>
- extends AbstractModelDiscoverer<T>
A default implementation for discovering JEE configuration file
Method Summary |
static java.lang.String |
getDescXmlVersion(Plugin plugin,
java.lang.Object source,
java.lang.String rootName,
java.lang.String dtdUrl)
Determine which version of DTD/XSD is used in the .xml file |
static java.lang.String |
getDoctypeVersion(Plugin plugin,
java.lang.Object source,
java.lang.String rootName,
java.lang.String baseUrl)
Look for a DOCTYPE declaration, then a dtd one. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractDeploymentDescriptorDiscoverer
public AbstractDeploymentDescriptorDiscoverer()
getDescXmlVersion
public static java.lang.String getDescXmlVersion(Plugin plugin,
java.lang.Object source,
java.lang.String rootName,
java.lang.String dtdUrl)
- Determine which version of DTD/XSD is used in the .xml file
- Parameters:
source
-
- Returns:
- the version of the .xml file
getDoctypeVersion
public static java.lang.String getDoctypeVersion(Plugin plugin,
java.lang.Object source,
java.lang.String rootName,
java.lang.String baseUrl)
- Look for a DOCTYPE declaration, then a dtd one. Assume that the right DTD is declared right
after the DOCTYPE
- Parameters:
file
-
- Returns:
- the version of the hibernate-configuration.xml file