/* * 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 Application. * * @version $Revision$ $Date$ */ public class Application extends org.vamsas.client.object implements java.io.Serializable { //--------------------------/ //- Class/Member Variables -/ //--------------------------/ /** * Field _version */ private java.lang.String _version; /** * Field _name */ private java.lang.String _name; /** * Field _session */ private java.lang.String _session; /** * Field _data */ private java.lang.String _data; //----------------/ //- Constructors -/ //----------------/ public Application() { super(); } //-- org.vamsas.objects.core.Application() //-----------/ //- 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 Application) { Application temp = (Application)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._session != null) { if (temp._session == null) return false; else if (!(this._session.equals(temp._session))) return false; } else if (temp._session != null) return false; if (this._data != null) { if (temp._data == null) return false; else if (!(this._data.equals(temp._data))) return false; } else if (temp._data != null) return false; return true; } return false; } //-- boolean equals(java.lang.Object) /** * Returns the value of field 'data'. * * @return String * @return the value of field 'data'. */ public java.lang.String getData() { return this._data; } //-- java.lang.String getData() /** * 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 'session'. * * @return String * @return the value of field 'session'. */ public java.lang.String getSession() { return this._session; } //-- java.lang.String getSession() /** * 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 'data'. * * @param data the value of field 'data'. */ public void setData(java.lang.String data) { this._data = data; } //-- void setData(java.lang.String) /** * 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 'session'. * * @param session the value of field 'session'. */ public void setSession(java.lang.String session) { this._session = session; } //-- void setSession(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 Application */ public static org.vamsas.objects.core.Application unmarshal(java.io.Reader reader) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException { return (org.vamsas.objects.core.Application) Unmarshaller.unmarshal(org.vamsas.objects.core.Application.class, reader); } //-- org.vamsas.objects.core.Application 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() }