001: /*
002: * This class was automatically generated with
003: * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
004: * Schema.
005: * $Id$
006: */
007:
008: package org.exolab.castor.builder.binding.xml;
009:
010: //---------------------------------/
011: //- Imported classes and packages -/
012: //---------------------------------/
013:
014: import org.exolab.castor.xml.Marshaller;
015: import org.exolab.castor.xml.Unmarshaller;
016:
017: /**
018: * Class AutomaticNamingType.
019: *
020: * @version $Revision$ $Date$
021: */
022: public class AutomaticNamingType implements java.io.Serializable {
023:
024: //--------------------------/
025: //- Class/Member Variables -/
026: //--------------------------/
027:
028: /**
029: * Field _forces.
030: */
031: private org.exolab.castor.builder.binding.xml.Forces _forces;
032:
033: /**
034: * Field _excludes.
035: */
036: private org.exolab.castor.builder.binding.xml.Excludes _excludes;
037:
038: //----------------/
039: //- Constructors -/
040: //----------------/
041:
042: public AutomaticNamingType() {
043: super ();
044: }
045:
046: //-----------/
047: //- Methods -/
048: //-----------/
049:
050: /**
051: * Returns the value of field 'excludes'.
052: *
053: * @return the value of field 'Excludes'.
054: */
055: public org.exolab.castor.builder.binding.xml.Excludes getExcludes() {
056: return this ._excludes;
057: }
058:
059: /**
060: * Returns the value of field 'forces'.
061: *
062: * @return the value of field 'Forces'.
063: */
064: public org.exolab.castor.builder.binding.xml.Forces getForces() {
065: return this ._forces;
066: }
067:
068: /**
069: * Method isValid.
070: *
071: * @return true if this object is valid according to the schema
072: */
073: public boolean isValid() {
074: try {
075: validate();
076: } catch (org.exolab.castor.xml.ValidationException vex) {
077: return false;
078: }
079: return true;
080: }
081:
082: /**
083: *
084: *
085: * @param out
086: * @throws org.exolab.castor.xml.MarshalException if object is
087: * null or if any SAXException is thrown during marshaling
088: * @throws org.exolab.castor.xml.ValidationException if this
089: * object is an invalid instance according to the schema
090: */
091: public void marshal(final java.io.Writer out)
092: throws org.exolab.castor.xml.MarshalException,
093: org.exolab.castor.xml.ValidationException {
094: Marshaller.marshal(this , out);
095: }
096:
097: /**
098: *
099: *
100: * @param handler
101: * @throws java.io.IOException if an IOException occurs during
102: * marshaling
103: * @throws org.exolab.castor.xml.ValidationException if this
104: * object is an invalid instance according to the schema
105: * @throws org.exolab.castor.xml.MarshalException if object is
106: * null or if any SAXException is thrown during marshaling
107: */
108: public void marshal(final org.xml.sax.ContentHandler handler)
109: throws java.io.IOException,
110: org.exolab.castor.xml.MarshalException,
111: org.exolab.castor.xml.ValidationException {
112: Marshaller.marshal(this , handler);
113: }
114:
115: /**
116: * Sets the value of field 'excludes'.
117: *
118: * @param excludes the value of field 'excludes'.
119: */
120: public void setExcludes(
121: final org.exolab.castor.builder.binding.xml.Excludes excludes) {
122: this ._excludes = excludes;
123: }
124:
125: /**
126: * Sets the value of field 'forces'.
127: *
128: * @param forces the value of field 'forces'.
129: */
130: public void setForces(
131: final org.exolab.castor.builder.binding.xml.Forces forces) {
132: this ._forces = forces;
133: }
134:
135: /**
136: * Method unmarshalAutomaticNamingType.
137: *
138: * @param reader
139: * @throws org.exolab.castor.xml.MarshalException if object is
140: * null or if any SAXException is thrown during marshaling
141: * @throws org.exolab.castor.xml.ValidationException if this
142: * object is an invalid instance according to the schema
143: * @return the unmarshaled
144: * org.exolab.castor.builder.binding.xml.AutomaticNamingType
145: */
146: public static org.exolab.castor.builder.binding.xml.AutomaticNamingType unmarshalAutomaticNamingType(
147: final java.io.Reader reader)
148: throws org.exolab.castor.xml.MarshalException,
149: org.exolab.castor.xml.ValidationException {
150: return (org.exolab.castor.builder.binding.xml.AutomaticNamingType) Unmarshaller
151: .unmarshal(
152: org.exolab.castor.builder.binding.xml.AutomaticNamingType.class,
153: reader);
154: }
155:
156: /**
157: *
158: *
159: * @throws org.exolab.castor.xml.ValidationException if this
160: * object is an invalid instance according to the schema
161: */
162: public void validate()
163: throws org.exolab.castor.xml.ValidationException {
164: org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
165: validator.validate(this);
166: }
167:
168: }
|