View Javadoc

1   /*
2    =================== DO NOT EDIT THIS FILE ====================
3    Generated by Modello 1.4.1 on 2012-04-13 21:28:14,
4    any modifications will be overwritten.
5    ==============================================================
6    */
7   
8   package org.apache.maven.doxia.module.fml.model;
9   
10  /**
11   * 
12   *          The <code>&lt;faqs&gt;</code> element is the root of
13   * the FML descriptor.
14   *          The following table lists all of the possible child
15   * elements.
16   *       
17   * 
18   * @version $Revision$ $Date$
19   */
20  @SuppressWarnings( "all" )
21  public class Faqs
22      implements java.io.Serializable
23  {
24  
25        //--------------------------/
26       //- Class/Member Variables -/
27      //--------------------------/
28  
29      /**
30       * 
31       *             The title name of this FAQ.
32       *           
33       */
34      private String title = "FAQ";
35  
36      /**
37       * 
38       *             Boolean to generate optionally [top] links.
39       *           
40       */
41      private boolean toplink = true;
42  
43      /**
44       * Field parts.
45       */
46      private java.util.List<Part> parts;
47  
48      /**
49       * Field modelEncoding.
50       */
51      private String modelEncoding = "UTF-8";
52  
53  
54        //-----------/
55       //- Methods -/
56      //-----------/
57  
58      /**
59       * Method addPart.
60       * 
61       * @param part
62       */
63      public void addPart( Part part )
64      {
65          getParts().add( part );
66      } //-- void addPart( Part )
67  
68      /**
69       * Method equals.
70       * 
71       * @param other
72       * @return boolean
73       */
74      public boolean equals( Object other )
75      {
76          if ( this == other )
77          {
78              return true;
79          }
80  
81          if ( !( other instanceof Faqs ) )
82          {
83              return false;
84          }
85  
86          Faqs that = (Faqs) other;
87          boolean result = true;
88  
89          result = result && ( getTitle() == null ? that.getTitle() == null : getTitle().equals( that.getTitle() ) );
90          result = result && toplink == that.toplink;
91          result = result && ( getParts() == null ? that.getParts() == null : getParts().equals( that.getParts() ) );
92  
93          return result;
94      } //-- boolean equals( Object )
95  
96      /**
97       * Get the modelEncoding field.
98       * 
99       * @return String
100      */
101     public String getModelEncoding()
102     {
103         return this.modelEncoding;
104     } //-- String getModelEncoding()
105 
106     /**
107      * Method getParts.
108      * 
109      * @return List
110      */
111     public java.util.List<Part> getParts()
112     {
113         if ( this.parts == null )
114         {
115             this.parts = new java.util.ArrayList<Part>();
116         }
117 
118         return this.parts;
119     } //-- java.util.List<Part> getParts()
120 
121     /**
122      * Get the title name of this FAQ.
123      * 
124      * @return String
125      */
126     public String getTitle()
127     {
128         return this.title;
129     } //-- String getTitle()
130 
131     /**
132      * Method hashCode.
133      * 
134      * @return int
135      */
136     public int hashCode()
137     {
138         int result = 17;
139 
140         result = 37 * result + ( title != null ? title.hashCode() : 0 );
141         result = 37 * result + ( toplink ? 0 : 1 );
142         result = 37 * result + ( parts != null ? parts.hashCode() : 0 );
143 
144         return result;
145     } //-- int hashCode()
146 
147     /**
148      * Get boolean to generate optionally [top] links.
149      * 
150      * @return boolean
151      */
152     public boolean isToplink()
153     {
154         return this.toplink;
155     } //-- boolean isToplink()
156 
157     /**
158      * Method removePart.
159      * 
160      * @param part
161      */
162     public void removePart( Part part )
163     {
164         getParts().remove( part );
165     } //-- void removePart( Part )
166 
167     /**
168      * Set the modelEncoding field.
169      * 
170      * @param modelEncoding
171      */
172     public void setModelEncoding( String modelEncoding )
173     {
174         this.modelEncoding = modelEncoding;
175     } //-- void setModelEncoding( String )
176 
177     /**
178      * Set list of FAQ part.
179      * 
180      * @param parts
181      */
182     public void setParts( java.util.List<Part> parts )
183     {
184         this.parts = parts;
185     } //-- void setParts( java.util.List )
186 
187     /**
188      * Set the title name of this FAQ.
189      * 
190      * @param title
191      */
192     public void setTitle( String title )
193     {
194         this.title = title;
195     } //-- void setTitle( String )
196 
197     /**
198      * Set boolean to generate optionally [top] links.
199      * 
200      * @param toplink
201      */
202     public void setToplink( boolean toplink )
203     {
204         this.toplink = toplink;
205     } //-- void setToplink( boolean )
206 
207     /**
208      * Method toString.
209      * 
210      * @return String
211      */
212     public java.lang.String toString()
213     {
214         StringBuilder buf = new StringBuilder( 128 );
215 
216         buf.append( "title = '" );
217         buf.append( getTitle() );
218         buf.append( "'" );
219         buf.append( "\n" ); 
220         buf.append( "toplink = '" );
221         buf.append( isToplink() );
222         buf.append( "'" );
223         buf.append( "\n" ); 
224         buf.append( "parts = '" );
225         buf.append( getParts() );
226         buf.append( "'" );
227 
228         return buf.toString();
229     } //-- java.lang.String toString()
230 
231 }