View Javadoc
1   //
2   // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.11 
3   // See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
4   // Any modifications to this file will be lost upon recompilation of the source schema. 
5   // Generated on: 2017.04.23 at 07:23:18 PM CEST 
6   //
7   
8   
9   package com.hack23.cia.model.internal.application.system.impl;
10  
11  import java.io.Serializable;
12  import javax.persistence.Basic;
13  import javax.persistence.Column;
14  import javax.persistence.Entity;
15  import javax.persistence.EnumType;
16  import javax.persistence.Enumerated;
17  import javax.persistence.GeneratedValue;
18  import javax.persistence.GenerationType;
19  import javax.persistence.Id;
20  import javax.persistence.Inheritance;
21  import javax.persistence.InheritanceType;
22  import javax.persistence.Table;
23  import javax.xml.bind.annotation.XmlAccessType;
24  import javax.xml.bind.annotation.XmlAccessorType;
25  import javax.xml.bind.annotation.XmlAttribute;
26  import javax.xml.bind.annotation.XmlSchemaType;
27  import javax.xml.bind.annotation.XmlSeeAlso;
28  import javax.xml.bind.annotation.XmlType;
29  import com.hack23.cia.model.common.api.ModelObject;
30  import org.jvnet.jaxb2_commons.lang.Equals;
31  import org.jvnet.jaxb2_commons.lang.EqualsStrategy;
32  import org.jvnet.jaxb2_commons.lang.HashCode;
33  import org.jvnet.jaxb2_commons.lang.HashCodeStrategy;
34  import org.jvnet.jaxb2_commons.lang.JAXBEqualsStrategy;
35  import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy;
36  import org.jvnet.jaxb2_commons.lang.JAXBToStringStrategy;
37  import org.jvnet.jaxb2_commons.lang.ToString;
38  import org.jvnet.jaxb2_commons.lang.ToStringStrategy;
39  import org.jvnet.jaxb2_commons.locator.ObjectLocator;
40  import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;
41  
42  
43  /**
44   * <p>Java class for Portal complex type.
45   * 
46   * <p>The following schema fragment specifies the expected content contained within this class.
47   * 
48   * <pre>
49   * &lt;complexType name="Portal"&gt;
50   *   &lt;complexContent&gt;
51   *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType"&gt;
52   *       &lt;sequence&gt;
53   *         &lt;element name="modelObjectId" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/&gt;
54   *         &lt;element name="modelObjectVersion" type="{http://www.w3.org/2001/XMLSchema}int" minOccurs="0"/&gt;
55   *         &lt;element name="portalName" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&gt;
56   *         &lt;element name="portalType" type="{http://system.application.internal.model.cia.hack23.com/impl}PortalType" minOccurs="0"/&gt;
57   *         &lt;element name="description" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&gt;
58   *         &lt;element name="googleMapApiKey" type="{http://www.w3.org/2001/XMLSchema}string" minOccurs="0"/&gt;
59   *       &lt;/sequence&gt;
60   *     &lt;/restriction&gt;
61   *   &lt;/complexContent&gt;
62   * &lt;/complexType&gt;
63   * </pre>
64   * 
65   * 
66   */
67  @XmlAccessorType(XmlAccessType.FIELD)
68  @XmlType(name = "Portal", propOrder = {
69      "modelObjectId",
70      "modelObjectVersion",
71      "portalName",
72      "portalType",
73      "description",
74      "googleMapApiKey"
75  })
76  @XmlSeeAlso({
77      DomainPortal.class
78  })
79  @Entity(name = "Portal")
80  @Table(name = "PORTAL")
81  @Inheritance(strategy = InheritanceType.JOINED)
82  public class Portal
83      implements Serializable, ModelObject, Equals, HashCode, ToString
84  {
85  
86      private final static long serialVersionUID = 1L;
87      protected Integer modelObjectId;
88      protected Integer modelObjectVersion;
89      protected String portalName;
90      @XmlSchemaType(name = "string")
91      protected PortalType portalType;
92      protected String description;
93      protected String googleMapApiKey;
94      @XmlAttribute(name = "Hjid")
95      protected Long hjid;
96  
97      /**
98       * Gets the value of the modelObjectId property.
99       * 
100      * @return
101      *     possible object is
102      *     {@link Integer }
103      *     
104      */
105     @Basic
106     @Column(name = "MODEL_OBJECT_ID", precision = 10, scale = 0)
107     public Integer getModelObjectId() {
108         return modelObjectId;
109     }
110 
111     /**
112      * Sets the value of the modelObjectId property.
113      * 
114      * @param value
115      *     allowed object is
116      *     {@link Integer }
117      *     
118      */
119     public void setModelObjectId(Integer value) {
120         this.modelObjectId = value;
121     }
122 
123     /**
124      * Gets the value of the modelObjectVersion property.
125      * 
126      * @return
127      *     possible object is
128      *     {@link Integer }
129      *     
130      */
131     @Basic
132     @Column(name = "MODEL_OBJECT_VERSION", precision = 10, scale = 0)
133     public Integer getModelObjectVersion() {
134         return modelObjectVersion;
135     }
136 
137     /**
138      * Sets the value of the modelObjectVersion property.
139      * 
140      * @param value
141      *     allowed object is
142      *     {@link Integer }
143      *     
144      */
145     public void setModelObjectVersion(Integer value) {
146         this.modelObjectVersion = value;
147     }
148 
149     /**
150      * Gets the value of the portalName property.
151      * 
152      * @return
153      *     possible object is
154      *     {@link String }
155      *     
156      */
157     @Basic
158     @Column(name = "PORTAL_NAME", length = 255)
159     public String getPortalName() {
160         return portalName;
161     }
162 
163     /**
164      * Sets the value of the portalName property.
165      * 
166      * @param value
167      *     allowed object is
168      *     {@link String }
169      *     
170      */
171     public void setPortalName(String value) {
172         this.portalName = value;
173     }
174 
175     /**
176      * Gets the value of the portalType property.
177      * 
178      * @return
179      *     possible object is
180      *     {@link PortalType }
181      *     
182      */
183     @Basic
184     @Column(name = "PORTAL_TYPE", length = 255)
185     @Enumerated(EnumType.STRING)
186     public PortalType getPortalType() {
187         return portalType;
188     }
189 
190     /**
191      * Sets the value of the portalType property.
192      * 
193      * @param value
194      *     allowed object is
195      *     {@link PortalType }
196      *     
197      */
198     public void setPortalType(PortalType value) {
199         this.portalType = value;
200     }
201 
202     /**
203      * Gets the value of the description property.
204      * 
205      * @return
206      *     possible object is
207      *     {@link String }
208      *     
209      */
210     @Basic
211     @Column(name = "DESCRIPTION", length = 255)
212     public String getDescription() {
213         return description;
214     }
215 
216     /**
217      * Sets the value of the description property.
218      * 
219      * @param value
220      *     allowed object is
221      *     {@link String }
222      *     
223      */
224     public void setDescription(String value) {
225         this.description = value;
226     }
227 
228     /**
229      * Gets the value of the googleMapApiKey property.
230      * 
231      * @return
232      *     possible object is
233      *     {@link String }
234      *     
235      */
236     @Basic
237     @Column(name = "GOOGLE_MAP_API_KEY", length = 255)
238     public String getGoogleMapApiKey() {
239         return googleMapApiKey;
240     }
241 
242     /**
243      * Sets the value of the googleMapApiKey property.
244      * 
245      * @param value
246      *     allowed object is
247      *     {@link String }
248      *     
249      */
250     public void setGoogleMapApiKey(String value) {
251         this.googleMapApiKey = value;
252     }
253 
254     public Portal withModelObjectId(Integer value) {
255         setModelObjectId(value);
256         return this;
257     }
258 
259     public Portal withModelObjectVersion(Integer value) {
260         setModelObjectVersion(value);
261         return this;
262     }
263 
264     public Portal withPortalName(String value) {
265         setPortalName(value);
266         return this;
267     }
268 
269     public Portal withPortalType(PortalType value) {
270         setPortalType(value);
271         return this;
272     }
273 
274     public Portal withDescription(String value) {
275         setDescription(value);
276         return this;
277     }
278 
279     public Portal withGoogleMapApiKey(String value) {
280         setGoogleMapApiKey(value);
281         return this;
282     }
283 
284     public String toString() {
285         final ToStringStrategy strategy = JAXBToStringStrategy.INSTANCE;
286         final StringBuilder buffer = new StringBuilder();
287         append(null, buffer, strategy);
288         return buffer.toString();
289     }
290 
291     public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
292         strategy.appendStart(locator, this, buffer);
293         appendFields(locator, buffer, strategy);
294         strategy.appendEnd(locator, this, buffer);
295         return buffer;
296     }
297 
298     public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
299         {
300             Integer theModelObjectId;
301             theModelObjectId = this.getModelObjectId();
302             strategy.appendField(locator, this, "modelObjectId", buffer, theModelObjectId);
303         }
304         {
305             Integer theModelObjectVersion;
306             theModelObjectVersion = this.getModelObjectVersion();
307             strategy.appendField(locator, this, "modelObjectVersion", buffer, theModelObjectVersion);
308         }
309         {
310             String thePortalName;
311             thePortalName = this.getPortalName();
312             strategy.appendField(locator, this, "portalName", buffer, thePortalName);
313         }
314         {
315             PortalType thePortalType;
316             thePortalType = this.getPortalType();
317             strategy.appendField(locator, this, "portalType", buffer, thePortalType);
318         }
319         {
320             String theDescription;
321             theDescription = this.getDescription();
322             strategy.appendField(locator, this, "description", buffer, theDescription);
323         }
324         {
325             String theGoogleMapApiKey;
326             theGoogleMapApiKey = this.getGoogleMapApiKey();
327             strategy.appendField(locator, this, "googleMapApiKey", buffer, theGoogleMapApiKey);
328         }
329         return buffer;
330     }
331 
332     /**
333      * Gets the value of the hjid property.
334      * 
335      * @return
336      *     possible object is
337      *     {@link Long }
338      *     
339      */
340     @Id
341     @Column(name = "HJID")
342     @GeneratedValue(strategy = GenerationType.AUTO)
343     public Long getHjid() {
344         return hjid;
345     }
346 
347     /**
348      * Sets the value of the hjid property.
349      * 
350      * @param value
351      *     allowed object is
352      *     {@link Long }
353      *     
354      */
355     public void setHjid(Long value) {
356         this.hjid = value;
357     }
358 
359     public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
360         if ((object == null)||(this.getClass()!= object.getClass())) {
361             return false;
362         }
363         if (this == object) {
364             return true;
365         }
366         final Portal that = ((Portal) object);
367         {
368             Integer lhsModelObjectId;
369             lhsModelObjectId = this.getModelObjectId();
370             Integer rhsModelObjectId;
371             rhsModelObjectId = that.getModelObjectId();
372             if (!strategy.equals(LocatorUtils.property(thisLocator, "modelObjectId", lhsModelObjectId), LocatorUtils.property(thatLocator, "modelObjectId", rhsModelObjectId), lhsModelObjectId, rhsModelObjectId)) {
373                 return false;
374             }
375         }
376         {
377             Integer lhsModelObjectVersion;
378             lhsModelObjectVersion = this.getModelObjectVersion();
379             Integer rhsModelObjectVersion;
380             rhsModelObjectVersion = that.getModelObjectVersion();
381             if (!strategy.equals(LocatorUtils.property(thisLocator, "modelObjectVersion", lhsModelObjectVersion), LocatorUtils.property(thatLocator, "modelObjectVersion", rhsModelObjectVersion), lhsModelObjectVersion, rhsModelObjectVersion)) {
382                 return false;
383             }
384         }
385         {
386             String lhsPortalName;
387             lhsPortalName = this.getPortalName();
388             String rhsPortalName;
389             rhsPortalName = that.getPortalName();
390             if (!strategy.equals(LocatorUtils.property(thisLocator, "portalName", lhsPortalName), LocatorUtils.property(thatLocator, "portalName", rhsPortalName), lhsPortalName, rhsPortalName)) {
391                 return false;
392             }
393         }
394         {
395             PortalType lhsPortalType;
396             lhsPortalType = this.getPortalType();
397             PortalType rhsPortalType;
398             rhsPortalType = that.getPortalType();
399             if (!strategy.equals(LocatorUtils.property(thisLocator, "portalType", lhsPortalType), LocatorUtils.property(thatLocator, "portalType", rhsPortalType), lhsPortalType, rhsPortalType)) {
400                 return false;
401             }
402         }
403         {
404             String lhsDescription;
405             lhsDescription = this.getDescription();
406             String rhsDescription;
407             rhsDescription = that.getDescription();
408             if (!strategy.equals(LocatorUtils.property(thisLocator, "description", lhsDescription), LocatorUtils.property(thatLocator, "description", rhsDescription), lhsDescription, rhsDescription)) {
409                 return false;
410             }
411         }
412         {
413             String lhsGoogleMapApiKey;
414             lhsGoogleMapApiKey = this.getGoogleMapApiKey();
415             String rhsGoogleMapApiKey;
416             rhsGoogleMapApiKey = that.getGoogleMapApiKey();
417             if (!strategy.equals(LocatorUtils.property(thisLocator, "googleMapApiKey", lhsGoogleMapApiKey), LocatorUtils.property(thatLocator, "googleMapApiKey", rhsGoogleMapApiKey), lhsGoogleMapApiKey, rhsGoogleMapApiKey)) {
418                 return false;
419             }
420         }
421         return true;
422     }
423 
424     public boolean equals(Object object) {
425         final EqualsStrategy strategy = JAXBEqualsStrategy.INSTANCE;
426         return equals(null, null, object, strategy);
427     }
428 
429     public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
430         int currentHashCode = 1;
431         {
432             Integer theModelObjectId;
433             theModelObjectId = this.getModelObjectId();
434             currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "modelObjectId", theModelObjectId), currentHashCode, theModelObjectId);
435         }
436         {
437             Integer theModelObjectVersion;
438             theModelObjectVersion = this.getModelObjectVersion();
439             currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "modelObjectVersion", theModelObjectVersion), currentHashCode, theModelObjectVersion);
440         }
441         {
442             String thePortalName;
443             thePortalName = this.getPortalName();
444             currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "portalName", thePortalName), currentHashCode, thePortalName);
445         }
446         {
447             PortalType thePortalType;
448             thePortalType = this.getPortalType();
449             currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "portalType", thePortalType), currentHashCode, thePortalType);
450         }
451         {
452             String theDescription;
453             theDescription = this.getDescription();
454             currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "description", theDescription), currentHashCode, theDescription);
455         }
456         {
457             String theGoogleMapApiKey;
458             theGoogleMapApiKey = this.getGoogleMapApiKey();
459             currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "googleMapApiKey", theGoogleMapApiKey), currentHashCode, theGoogleMapApiKey);
460         }
461         return currentHashCode;
462     }
463 
464     public int hashCode() {
465         final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
466         return this.hashCode(null, strategy);
467     }
468 
469 }