first attempt at object build.
[vamsas.git] / src / org / vamsas / client / objects / Entry.java
1 /*
2  * This class was automatically generated with 
3  * <a href="http://www.castor.org">Castor 0.9.9M1</a>, using an XML
4  * Schema.
5  * $Id$
6  */
7
8 package org.vamsas.client.objects;
9
10   //---------------------------------/
11  //- Imported classes and packages -/
12 //---------------------------------/
13
14 import java.io.IOException;
15 import java.io.Reader;
16 import java.io.Serializable;
17 import java.io.Writer;
18 import org.exolab.castor.xml.MarshalException;
19 import org.exolab.castor.xml.Marshaller;
20 import org.exolab.castor.xml.Unmarshaller;
21 import org.exolab.castor.xml.ValidationException;
22 import org.xml.sax.ContentHandler;
23
24 /**
25  * Class Entry.
26  * 
27  * @version $Revision$ $Date$
28  */
29 public class Entry extends org.vamsas.client.object 
30 implements java.io.Serializable
31 {
32
33
34       //--------------------------/
35      //- Class/Member Variables -/
36     //--------------------------/
37
38     /**
39      * Field _user
40      */
41     private java.lang.String _user;
42
43     /**
44      * Field _action
45      */
46     private java.lang.String _action;
47
48     /**
49      * Field _date
50      */
51     private org.exolab.castor.types.Date _date;
52
53
54       //----------------/
55      //- Constructors -/
56     //----------------/
57
58     public Entry() 
59      {
60         super();
61     } //-- org.vamsas.client.objects.Entry()
62
63
64       //-----------/
65      //- Methods -/
66     //-----------/
67
68     /**
69      * Note: hashCode() has not been overriden
70      * 
71      * @param obj
72      * @return boolean
73      */
74     public boolean equals(java.lang.Object obj)
75     {
76         if ( this == obj )
77             return true;
78         
79         if (super.equals(obj)==false)
80             return false;
81         
82         if (obj instanceof Entry) {
83         
84             Entry temp = (Entry)obj;
85             if (this._user != null) {
86                 if (temp._user == null) return false;
87                 else if (!(this._user.equals(temp._user))) 
88                     return false;
89             }
90             else if (temp._user != null)
91                 return false;
92             if (this._action != null) {
93                 if (temp._action == null) return false;
94                 else if (!(this._action.equals(temp._action))) 
95                     return false;
96             }
97             else if (temp._action != null)
98                 return false;
99             if (this._date != null) {
100                 if (temp._date == null) return false;
101                 else if (!(this._date.equals(temp._date))) 
102                     return false;
103             }
104             else if (temp._date != null)
105                 return false;
106             return true;
107         }
108         return false;
109     } //-- boolean equals(java.lang.Object) 
110
111     /**
112      * Returns the value of field 'action'.
113      * 
114      * @return String
115      * @return the value of field 'action'.
116      */
117     public java.lang.String getAction()
118     {
119         return this._action;
120     } //-- java.lang.String getAction() 
121
122     /**
123      * Returns the value of field 'date'.
124      * 
125      * @return Date
126      * @return the value of field 'date'.
127      */
128     public org.exolab.castor.types.Date getDate()
129     {
130         return this._date;
131     } //-- org.exolab.castor.types.Date getDate() 
132
133     /**
134      * Returns the value of field 'user'.
135      * 
136      * @return String
137      * @return the value of field 'user'.
138      */
139     public java.lang.String getUser()
140     {
141         return this._user;
142     } //-- java.lang.String getUser() 
143
144     /**
145      * Method isValid
146      * 
147      * 
148      * 
149      * @return boolean
150      */
151     public boolean isValid()
152     {
153         try {
154             validate();
155         }
156         catch (org.exolab.castor.xml.ValidationException vex) {
157             return false;
158         }
159         return true;
160     } //-- boolean isValid() 
161
162     /**
163      * Method marshal
164      * 
165      * 
166      * 
167      * @param out
168      */
169     public void marshal(java.io.Writer out)
170         throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
171     {
172         
173         Marshaller.marshal(this, out);
174     } //-- void marshal(java.io.Writer) 
175
176     /**
177      * Method marshal
178      * 
179      * 
180      * 
181      * @param handler
182      */
183     public void marshal(org.xml.sax.ContentHandler handler)
184         throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
185     {
186         
187         Marshaller.marshal(this, handler);
188     } //-- void marshal(org.xml.sax.ContentHandler) 
189
190     /**
191      * Sets the value of field 'action'.
192      * 
193      * @param action the value of field 'action'.
194      */
195     public void setAction(java.lang.String action)
196     {
197         this._action = action;
198     } //-- void setAction(java.lang.String) 
199
200     /**
201      * Sets the value of field 'date'.
202      * 
203      * @param date the value of field 'date'.
204      */
205     public void setDate(org.exolab.castor.types.Date date)
206     {
207         this._date = date;
208     } //-- void setDate(org.exolab.castor.types.Date) 
209
210     /**
211      * Sets the value of field 'user'.
212      * 
213      * @param user the value of field 'user'.
214      */
215     public void setUser(java.lang.String user)
216     {
217         this._user = user;
218     } //-- void setUser(java.lang.String) 
219
220     /**
221      * Method unmarshal
222      * 
223      * 
224      * 
225      * @param reader
226      * @return Entry
227      */
228     public static org.vamsas.client.objects.Entry unmarshal(java.io.Reader reader)
229         throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
230     {
231         return (org.vamsas.client.objects.Entry) Unmarshaller.unmarshal(org.vamsas.client.objects.Entry.class, reader);
232     } //-- org.vamsas.client.objects.Entry unmarshal(java.io.Reader) 
233
234     /**
235      * Method validate
236      * 
237      */
238     public void validate()
239         throws org.exolab.castor.xml.ValidationException
240     {
241         org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
242         validator.validate(this);
243     } //-- void validate() 
244
245 }