/* * This class was automatically generated with * <a href="http://castor.exolab.org">Castor 0.9.2</a>, using an * XML Schema. * $Id$ */ package org.apache.jetspeed.xml.api.jcm; //---------------------------------/ //- Imported classes and packages -/ //---------------------------------/ import java.io.Reader; import java.io.Serializable; import java.io.Writer; import org.exolab.castor.xml.*; import org.exolab.castor.xml.MarshalException; import org.exolab.castor.xml.ValidationException; import org.xml.sax.DocumentHandler; /** * * @version $Revision$ $Date$ **/ public class Image implements java.io.Serializable { //--------------------------/ //- Class/Member Variables -/ //--------------------------/ private java.lang.String _title; private java.lang.String _url; private java.lang.String _link; private java.lang.String _description; private int _width; /** * keeps track of state for field: _width **/ private boolean _has_width; private int _height; /** * keeps track of state for field: _height **/ private boolean _has_height; //----------------/ //- Constructors -/ //----------------/ public Image() { super(); } //-- org.apache.jetspeed.xml.api.jcm.Image() //-----------/ //- Methods -/ //-----------/ /** **/ public void deleteHeight() { this._has_height= false; } //-- void deleteHeight() /** **/ public void deleteWidth() { this._has_width= false; } //-- void deleteWidth() /** **/ public java.lang.String getDescription() { return this._description; } //-- java.lang.String getDescription() /** **/ public int getHeight() { return this._height; } //-- int getHeight() /** **/ public java.lang.String getLink() { return this._link; } //-- java.lang.String getLink() /** **/ public java.lang.String getTitle() { return this._title; } //-- java.lang.String getTitle() /** **/ public java.lang.String getUrl() { return this._url; } //-- java.lang.String getUrl() /** **/ public int getWidth() { return this._width; } //-- int getWidth() /** **/ public boolean hasHeight() { return this._has_height; } //-- boolean hasHeight() /** **/ public boolean hasWidth() { return this._has_width; } //-- boolean hasWidth() /** **/ public boolean isValid() { try { validate(); } catch (org.exolab.castor.xml.ValidationException vex) { return false; } return true; } //-- boolean isValid() /** * * @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) /** * * @param handler **/ public void marshal(org.xml.sax.DocumentHandler handler) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException { Marshaller.marshal(this, handler); } //-- void marshal(org.xml.sax.DocumentHandler) /** * * @param description **/ public void setDescription(java.lang.String description) { this._description = description; } //-- void setDescription(java.lang.String) /** * * @param height **/ public void setHeight(int height) { this._height = height; this._has_height = true; } //-- void setHeight(int) /** * * @param link **/ public void setLink(java.lang.String link) { this._link = link; } //-- void setLink(java.lang.String) /** * * @param title **/ public void setTitle(java.lang.String title) { this._title = title; } //-- void setTitle(java.lang.String) /** * * @param url **/ public void setUrl(java.lang.String url) { this._url = url; } //-- void setUrl(java.lang.String) /** * * @param width **/ public void setWidth(int width) { this._width = width; this._has_width = true; } //-- void setWidth(int) /** * * @param reader **/ public static org.apache.jetspeed.xml.api.jcm.Image unmarshal(java.io.Reader reader) throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException { return (org.apache.jetspeed.xml.api.jcm.Image) Unmarshaller.unmarshal(org.apache.jetspeed.xml.api.jcm.Image.class, reader); } //-- org.apache.jetspeed.xml.api.jcm.Image unmarshal(java.io.Reader) /** **/ 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() }