/* * This class was automatically generated with * Castor 0.9.9M2, using an XML * Schema. * $Id$ */ package org.vamsas.objects.core; //---------------------------------/ //- Imported classes and packages -/ //---------------------------------/ import java.io.IOException; import java.io.Reader; import java.io.Serializable; import java.io.Writer; import org.exolab.castor.xml.MarshalException; import org.exolab.castor.xml.Marshaller; import org.exolab.castor.xml.Unmarshaller; import org.exolab.castor.xml.ValidationException; import org.xml.sax.ContentHandler; /** * Class ApplicationData. * * @version $Revision$ $Date$ */ public class ApplicationData extends org.vamsas.objects.core.AppData implements java.io.Serializable { //--------------------------/ //- Class/Member Variables -/ //--------------------------/ /** * Field _version */ private java.lang.String _version; /** * Field _name */ private java.lang.String _name; /** * Field _urn */ private java.lang.String _urn; //----------------/ //- Constructors -/ //----------------/ public ApplicationData() { super(); } //-- org.vamsas.objects.core.ApplicationData() //-----------/ //- Methods -/ //-----------/ /** * Note: hashCode() has not been overriden * * @param obj * @return boolean */ public boolean equals(java.lang.Object obj) { if ( this == obj ) return true; if (super.equals(obj)==false) return false; if (obj instanceof ApplicationData) { ApplicationData temp = (ApplicationData)obj; if (this._version != null) { if (temp._version == null) return false; else if (!(this._version.equals(temp._version))) return false; } else if (temp._version != null) return false; if (this._name != null) { if (temp._name == null) return false; else if (!(this._name.equals(temp._name))) return false; } else if (temp._name != null) return false; if (this._urn != null) { if (temp._urn == null) return false; else if (!(this._urn.equals(temp._urn))) return false; } else if (temp._urn != null) return false; return true; } return false; } //-- boolean equals(java.lang.Object) /** * Returns the value of field 'name'. * * @return String * @return the value of field 'name'. */ public java.lang.String getName() { return this._name; } //-- java.lang.String getName() /** * Returns the value of field 'urn'. * * @return String * @return the value of field 'urn'. */ public java.lang.String getUrn() { return this._urn; } //-- java.lang.String getUrn() /** * Returns the value of field 'version'. * * @return String * @return the value of field 'version'. */ public java.lang.String getVersion() { return this._version; } //-- java.lang.String getVersion() /** * Method isValid * * * * @return boolean */ public boolean isValid() { try { validate(); } catch (org.exolab.castor.xml.ValidationException vex) { return false; } return true; } //-- boolean isValid() /** * Method marshal * * * * @param out */ public void marshal(java.io.Writer out) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException { Marshaller.marshal(this, out); } //-- void marshal(java.io.Writer) /** * Method marshal * * * * @param handler */ public void marshal(org.xml.sax.ContentHandler handler) throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException { Marshaller.marshal(this, handler); } //-- void marshal(org.xml.sax.ContentHandler) /** * Sets the value of field 'name'. * * @param name the value of field 'name'. */ public void setName(java.lang.String name) { this._name = name; } //-- void setName(java.lang.String) /** * Sets the value of field 'urn'. * * @param urn the value of field 'urn'. */ public void setUrn(java.lang.String urn) { this._urn = urn; } //-- void setUrn(java.lang.String) /** * Sets the value of field 'version'. * * @param version the value of field 'version'. */ public void setVersion(java.lang.String version) { this._version = version; } //-- void setVersion(java.lang.String) /** * Method unmarshal * * * * @param reader * @return AppData */ public static org.vamsas.objects.core.AppData unmarshal(java.io.Reader reader) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException { return (org.vamsas.objects.core.ApplicationData) Unmarshaller.unmarshal(org.vamsas.objects.core.ApplicationData.class, reader); } //-- org.vamsas.objects.core.AppData unmarshal(java.io.Reader) /** * Method validate * */ public void validate() throws org.exolab.castor.xml.ValidationException { org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator(); validator.validate(this); } //-- void validate() }