/*
 * Generated by XCodeGen v1.0
 * Sun Jul 07 16:05:41 EDT 2002
 */

package xcodegen.sample.domain.dto;

import java.io.Serializable;

/**
 * Order made by a user
 *
 * @author Herve Tchepannou
 * @version 
 */
public class OrderDTO
    extends xcodegen.sample.domain.dto.PersonDTO
    implements Serializable
{

///////////////////////////////////////////////////
// Fields
///////////////////////////////////////////////////


    /**  */
    private int id;

    /**  */
    private java.util.Date created;

    /**  */
    private int personId;


///////////////////////////////////////////////////
// Constructors
///////////////////////////////////////////////////

    public OrderDTO ()
    {
    }
    

    
///////////////////////////////////////////////////
// Public methods
///////////////////////////////////////////////////

    public boolean equals( Object obj )
    {
        if ( ( obj != null ) && ( obj.getClass() == getClass() ) )
        {
            return toString().equals( obj.toString() );
        }
        else
        {
            return false;
        }
    }
    
    public String toString()
    {
        StringBuffer buff = new StringBuffer();
        buff.append( getClass().getName() ).append( "{" );
        
        
        buff.append( "id=" ).append( getId () );
            
        buff.append( "," ).append( "created=" ).append( getCreated () );
            
        buff.append( "," ).append( "personId=" ).append( getPersonId () );
    
        buff.append( "}" );
        return buff.toString();
    }

    public java.util.Collection validate()
    {

        java.util.Collection errors = super.validate();


        return errors;
    }
        


///////////////////////////////////////////////////
// accessor methods for attributes
///////////////////////////////////////////////////

    
    /**
     * Getter of <code>id</code>
     * @see #id
     */
    public int getId () { return this.id; }
    
    /** 
     * Setter of <code>id</code>
     * @see #id
     */
    public void setId ( int value ) { this.id = value; }
    
    /**
     * Getter of <code>created</code>
     * @see #created
     */
    public java.util.Date getCreated () { return this.created; }
    
    /** 
     * Setter of <code>created</code>
     * @see #created
     */
    public void setCreated ( java.util.Date value ) { this.created = value; }
    
    /**
     * Getter of <code>personId</code>
     * @see #personId
     */
    public int getPersonId () { return this.personId; }
    
    /** 
     * Setter of <code>personId</code>
     * @see #personId
     */
    public void setPersonId ( int value ) { this.personId = value; }
}
