org.apache.cactus.integration.ant.deployment
Class ApplicationXmlVersion

java.lang.Object
  extended byorg.apache.cactus.integration.ant.deployment.ApplicationXmlVersion
All Implemented Interfaces:
java.lang.Comparable

public final class ApplicationXmlVersion
extends java.lang.Object
implements java.lang.Comparable

Enumerated type that represents the version of the deployment descriptor of a enterprise application (application.xml).

Since:
Cactus 1.5
Version:
$Id: ApplicationXmlVersion.java,v 1.3 2003/05/26 09:52:38 cmlenz Exp $
Author:
Christopher Lenz

Field Summary
 java.lang.String systemId
          The system ID of the corresponding document type.
static ApplicationXmlVersion V1_2
          Instance for version 1.2.
static ApplicationXmlVersion V1_3
          Instance for version 1.3.
 
Method Summary
 int compareTo(java.lang.Object theOther)
           
 boolean equals(java.lang.Object theOther)
           
 java.lang.String getPublicId()
          Returns the public ID of the document type corresponding to the descriptor version.
 java.lang.String getSystemId()
          Returns the system ID of the document type corresponding to the descriptor version.
 java.lang.String getVersion()
          Returns the tag name.
 int hashCode()
           
 java.lang.String toString()
           
static ApplicationXmlVersion valueOf(org.w3c.dom.DocumentType theDocType)
          Returns the version corresponding to the given document type.
static ApplicationXmlVersion valueOf(java.lang.String thePublicId)
          Returns the version corresponding to the given public ID.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

V1_2

public static final ApplicationXmlVersion V1_2
Instance for version 1.2.


V1_3

public static final ApplicationXmlVersion V1_3
Instance for version 1.3.


systemId

public java.lang.String systemId
The system ID of the corresponding document type.

Method Detail

compareTo

public int compareTo(java.lang.Object theOther)
Specified by:
compareTo in interface java.lang.Comparable
See Also:
Comparable.compareTo(java.lang.Object)

equals

public final boolean equals(java.lang.Object theOther)
See Also:
Object.toString()

hashCode

public final int hashCode()
See Also:
Object.hashCode()

getVersion

public final java.lang.String getVersion()
Returns the tag name.

Returns:
The tag name

getPublicId

public java.lang.String getPublicId()
Returns the public ID of the document type corresponding to the descriptor version.

Returns:
The public ID

getSystemId

public java.lang.String getSystemId()
Returns the system ID of the document type corresponding to the descriptor version.

Returns:
The system ID

toString

public final java.lang.String toString()
See Also:
Object.toString()

valueOf

public static ApplicationXmlVersion valueOf(org.w3c.dom.DocumentType theDocType)
                                     throws java.lang.NullPointerException
Returns the version corresponding to the given document type.

Parameters:
theDocType - The document type
Returns:
The version that matches the document type, or null if the doctype is not recognized
Throws:
java.lang.NullPointerException - If the document type is null

valueOf

public static ApplicationXmlVersion valueOf(java.lang.String thePublicId)
Returns the version corresponding to the given public ID.

Parameters:
thePublicId - The public ID
Returns:
The version that matches the public ID, or null if the ID is not recognized


Copyright © 2000-2003 Apache Software Foundation. All Rights Reserved.