View Javadoc

1   /*
2    * Created on Nov 27, 2004
3    *
4    * TODO To change the template for this generated file go to
5    * Window - Preferences - Java - Code Style - Code Templates
6    */
7   package com.panogenesis.model;
8   
9   import java.io.Serializable;
10  
11  import org.apache.commons.lang.builder.EqualsBuilder;
12  import org.apache.commons.lang.builder.HashCodeBuilder;
13  import org.apache.commons.lang.builder.ToStringBuilder;
14  /***
15   * @author John Arthur
16   *
17   * TODO To change the template for this generated type comment go to
18   * Window - Preferences - Java - Code Style - Code Templates
19   * 
20   * @hibernate.class table="issue_severity_lookup"
21   */
22  public class IssueSeverity extends BaseObject implements Serializable {
23  	private Integer id;
24  	private String severityName;
25  	private String severityDescription;
26  	private Integer listOrder;
27  
28  
29  	/***
30  	 * 
31  	 */
32  	public IssueSeverity() {
33  
34  	}
35  	/***
36  	 * @return Returns the id.
37  	 * @hibernate.id column="id"
38       *  generator-class="increment" unsaved-value="null"
39  	 */
40  	public Integer getId() {
41  		return id;
42  	}
43  	/***
44  	 * @param id The id to set.
45  	 */
46  	public void setId(Integer id) {
47  		this.id = id;
48  	}
49  	/***
50  	 * @return Returns the severityName.
51  	 * @hibernate.property column="severity_name" not-null="true" length="50"
52  	 */
53  	public String getSeverityName() {
54  		return severityName;
55  	}
56  	/***
57  	 * @param severityName The severityName to set.
58  	 * @spring.validator type="required"
59  	 */
60  	public void setSeverityName(String severityName) {
61  		this.severityName = severityName;
62  	}	
63  	/***
64  	 * @return Returns the severityDescription.
65  	 * @hibernate.property column="severity_description" not-null="true" length="255"
66  	 */
67  	public String getSeverityDescription() {
68  		return severityDescription;
69  	}
70  	/***
71  	 * @param severityDescription The severityDescription to set.
72  	 * @spring.validator type="required"
73  	 */
74  	public void setSeverityDescription(String severityDescription) {
75  		this.severityDescription = severityDescription;
76  	}
77  
78  	/***
79  	 * @return Returns the order.
80  	 * 
81  	 * @hibernate.property column="list_order"
82  	 *
83  	 */
84  	public Integer getListOrder() {
85  		return this.listOrder;
86  	}
87  	/***
88  	 * @param order The order to set.
89  	 * 
90  	 */
91  	public void setListOrder(Integer listOrder) {
92  		this.listOrder = listOrder;
93  	}
94  	/***
95  	 * @see java.lang.Object#equals(Object)
96  	 */
97  	public boolean equals(Object object) {
98  		if (!(object instanceof IssueSeverity)) {
99  			return false;
100 		}
101 		IssueSeverity rhs = (IssueSeverity) object;
102 		return new EqualsBuilder().append(
103 				this.listOrder, rhs.listOrder).append(this.severityName,
104 				rhs.severityName).append(this.severityDescription,
105 				rhs.severityDescription).append(this.id, rhs.id).isEquals();
106 	}
107 	/***
108 	 * @see java.lang.Object#hashCode()
109 	 */
110 	public int hashCode() {
111 		return new HashCodeBuilder(651859259, 1620873389).append(this.listOrder).append(this.severityName)
112 				.append(this.severityDescription).append(this.id).toHashCode();
113 	}
114 	/***
115 	 * @see java.lang.Object#toString()
116 	 */
117 	public String toString() {
118 		return new ToStringBuilder(this).append("severityName",
119 				this.severityName).append("id", this.id).append(
120 				"severityDescription", this.severityDescription).toString();
121 	}
122 }