001/*
002 =================== DO NOT EDIT THIS FILE ====================
003 Generated by Modello 1.9.0-SNAPSHOT,
004 any modifications will be overwritten.
005 ==============================================================
006 */
007
008package org.codehaus.modello.test.features;
009
010  //---------------------------------/
011 //- Imported classes and packages -/
012//---------------------------------/
013
014import org.codehaus.modello.test.features.other.PackageNameFeature;
015import org.codehaus.modello.test.features.other.SubInterfaceInPackage;
016
017/**
018 * A simple class for association demo.
019 * 
020 * @version $Revision$ $Date$
021 */
022@SuppressWarnings( "all" )
023public class Reference
024    implements java.io.Serializable
025{
026
027      //--------------------------/
028     //- Class/Member Variables -/
029    //--------------------------/
030
031    /**
032     * Field id.
033     */
034    private String id;
035
036
037      //-----------/
038     //- Methods -/
039    //-----------/
040
041    /**
042     * Method equals.
043     * 
044     * @param other
045     * @return boolean
046     */
047    public boolean equals( Object other )
048    {
049        if ( this == other )
050        {
051            return true;
052        }
053
054        if ( !( other instanceof Reference ) )
055        {
056            return false;
057        }
058
059        Reference that = (Reference) other;
060        boolean result = true;
061
062        result = result && ( getId() == null ? that.getId() == null : getId().equals( that.getId() ) );
063
064        return result;
065    } //-- boolean equals( Object )
066
067    /**
068     * Get the id field.
069     * 
070     * @return String
071     */
072    public String getId()
073    {
074        return this.id;
075    } //-- String getId()
076
077    /**
078     * Method hashCode.
079     * 
080     * @return int
081     */
082    public int hashCode()
083    {
084        int result = 17;
085
086        result = 37 * result + ( id != null ? id.hashCode() : 0 );
087
088        return result;
089    } //-- int hashCode()
090
091    /**
092     * Set the id field.
093     * 
094     * @param id
095     */
096    public void setId( String id )
097    {
098        this.id = id;
099    } //-- void setId( String )
100
101    /**
102     * Method toString.
103     * 
104     * @return String
105     */
106    public java.lang.String toString()
107    {
108        StringBuilder buf = new StringBuilder( 128 );
109
110        buf.append( "id = '" );
111        buf.append( getId() );
112        buf.append( "'" );
113
114        return buf.toString();
115    } //-- java.lang.String toString()
116
117}