View Javadoc
1   /*
2    * This class was automatically generated with 
3    * <a href="http://www.castor.org">Castor 1.3.1</a>, using an XML
4    * Schema.
5    * $Id$
6    */
7   
8   package org.exolab.castor.mapping.xml;
9   
10  /**
11   * Class Property.
12   * 
13   * @version $Revision$ $Date$
14   */
15  @SuppressWarnings("serial")
16  public class Property extends PropertyType 
17  implements java.io.Serializable
18  {
19  
20  
21        //----------------/
22       //- Constructors -/
23      //----------------/
24  
25      public Property() {
26          super();
27      }
28  
29  
30        //-----------/
31       //- Methods -/
32      //-----------/
33  
34      /**
35       * Method isValid.
36       * 
37       * @return true if this object is valid according to the schema
38       */
39      public boolean isValid(
40      ) {
41          try {
42              validate();
43          } catch (org.exolab.castor.xml.ValidationException vex) {
44              return false;
45          }
46          return true;
47      }
48  
49      /**
50       * 
51       * 
52       * @param out
53       * @throws org.exolab.castor.xml.MarshalException if object is
54       * null or if any SAXException is thrown during marshaling
55       * @throws org.exolab.castor.xml.ValidationException if this
56       * object is an invalid instance according to the schema
57       */
58      public void marshal(
59              final java.io.Writer out)
60      throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
61          org.exolab.castor.xml.Marshaller.marshal(this, out);
62      }
63  
64      /**
65       * 
66       * 
67       * @param handler
68       * @throws java.io.IOException if an IOException occurs during
69       * marshaling
70       * @throws org.exolab.castor.xml.ValidationException if this
71       * object is an invalid instance according to the schema
72       * @throws org.exolab.castor.xml.MarshalException if object is
73       * null or if any SAXException is thrown during marshaling
74       */
75      public void marshal(
76              final org.xml.sax.ContentHandler handler)
77      throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
78          org.exolab.castor.xml.Marshaller.marshal(this, handler);
79      }
80  
81      /**
82       * Method unmarshal.
83       * 
84       * @param reader
85       * @throws org.exolab.castor.xml.MarshalException if object is
86       * null or if any SAXException is thrown during marshaling
87       * @throws org.exolab.castor.xml.ValidationException if this
88       * object is an invalid instance according to the schema
89       * @return the unmarshaled org.exolab.castor.mapping.xml.Propert
90       */
91      public static org.exolab.castor.mapping.xml.Property unmarshal(
92              final java.io.Reader reader)
93      throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
94          return (org.exolab.castor.mapping.xml.Property) org.exolab.castor.xml.Unmarshaller.unmarshal(org.exolab.castor.mapping.xml.Property.class, reader);
95      }
96  
97      /**
98       * 
99       * 
100      * @throws org.exolab.castor.xml.ValidationException if this
101      * object is an invalid instance according to the schema
102      */
103     public void validate(
104     )
105     throws org.exolab.castor.xml.ValidationException {
106         org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
107         validator.validate(this);
108     }
109 
110 }