001    //
002    // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, v2.2.6 
003    // See <a href="http://java.sun.com/xml/jaxb">http://java.sun.com/xml/jaxb</a> 
004    // Any modifications to this file will be lost upon recompilation of the source schema. 
005    // Generated on: 2013.10.14 at 11:56:49 PM IST 
006    //
007    
008    
009    package org.apache.activemq.schema.core;
010    
011    import java.math.BigInteger;
012    import java.util.ArrayList;
013    import java.util.HashMap;
014    import java.util.List;
015    import java.util.Map;
016    import javax.xml.bind.JAXBElement;
017    import javax.xml.bind.annotation.XmlAccessType;
018    import javax.xml.bind.annotation.XmlAccessorType;
019    import javax.xml.bind.annotation.XmlAnyAttribute;
020    import javax.xml.bind.annotation.XmlAnyElement;
021    import javax.xml.bind.annotation.XmlAttribute;
022    import javax.xml.bind.annotation.XmlElementRef;
023    import javax.xml.bind.annotation.XmlID;
024    import javax.xml.bind.annotation.XmlRootElement;
025    import javax.xml.bind.annotation.XmlSchemaType;
026    import javax.xml.bind.annotation.XmlType;
027    import javax.xml.bind.annotation.adapters.CollapsedStringAdapter;
028    import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter;
029    import javax.xml.namespace.QName;
030    import org.jvnet.jaxb2_commons.lang.Equals;
031    import org.jvnet.jaxb2_commons.lang.EqualsStrategy;
032    import org.jvnet.jaxb2_commons.lang.HashCode;
033    import org.jvnet.jaxb2_commons.lang.HashCodeStrategy;
034    import org.jvnet.jaxb2_commons.lang.JAXBHashCodeStrategy;
035    import org.jvnet.jaxb2_commons.lang.JAXBToStringStrategy;
036    import org.jvnet.jaxb2_commons.lang.ToString;
037    import org.jvnet.jaxb2_commons.lang.ToStringStrategy;
038    import org.jvnet.jaxb2_commons.locator.ObjectLocator;
039    import org.jvnet.jaxb2_commons.locator.util.LocatorUtils;
040    
041    
042    /**
043     * <p>Java class for anonymous complex type.
044     * 
045     * <p>The following schema fragment specifies the expected content contained within this class.
046     * 
047     * <pre>
048     * &lt;complexType>
049     *   &lt;complexContent>
050     *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
051     *       &lt;choice maxOccurs="unbounded" minOccurs="0">
052     *         &lt;choice>
053     *           &lt;element name="statements" minOccurs="0">
054     *             &lt;complexType>
055     *               &lt;complexContent>
056     *                 &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
057     *                   &lt;choice minOccurs="0">
058     *                     &lt;element ref="{http://activemq.apache.org/schema/core}statements"/>
059     *                     &lt;any namespace='##other'/>
060     *                   &lt;/choice>
061     *                 &lt;/restriction>
062     *               &lt;/complexContent>
063     *             &lt;/complexType>
064     *           &lt;/element>
065     *           &lt;any namespace='##other' maxOccurs="unbounded" minOccurs="0"/>
066     *         &lt;/choice>
067     *       &lt;/choice>
068     *       &lt;attribute name="batchStatments" type="{http://www.w3.org/2001/XMLSchema}boolean" />
069     *       &lt;attribute name="maxRows" type="{http://www.w3.org/2001/XMLSchema}integer" />
070     *       &lt;attribute name="statements" type="{http://www.w3.org/2001/XMLSchema}string" />
071     *       &lt;attribute name="useExternalMessageReferences" type="{http://www.w3.org/2001/XMLSchema}boolean" />
072     *       &lt;attribute name="id" type="{http://www.w3.org/2001/XMLSchema}ID" />
073     *       &lt;anyAttribute processContents='lax' namespace='##other'/>
074     *     &lt;/restriction>
075     *   &lt;/complexContent>
076     * &lt;/complexType>
077     * </pre>
078     * 
079     * 
080     */
081    @XmlAccessorType(XmlAccessType.FIELD)
082    @XmlType(name = "", propOrder = {
083        "statementsOrAny"
084    })
085    @XmlRootElement(name = "hsqldb-jdbc-adapter")
086    public class DtoHsqldbJdbcAdapter
087        implements Equals, HashCode, ToString
088    {
089    
090        @XmlElementRef(name = "statements", namespace = "http://activemq.apache.org/schema/core", type = JAXBElement.class)
091        @XmlAnyElement(lax = true)
092        protected List<Object> statementsOrAny;
093        @XmlAttribute(name = "batchStatments")
094        protected Boolean batchStatments;
095        @XmlAttribute(name = "maxRows")
096        protected BigInteger maxRows;
097        @XmlAttribute(name = "statements")
098        protected String statements;
099        @XmlAttribute(name = "useExternalMessageReferences")
100        protected Boolean useExternalMessageReferences;
101        @XmlAttribute(name = "id")
102        @XmlJavaTypeAdapter(CollapsedStringAdapter.class)
103        @XmlID
104        @XmlSchemaType(name = "ID")
105        protected String id;
106        @XmlAnyAttribute
107        private Map<QName, String> otherAttributes = new HashMap<QName, String>();
108    
109        /**
110         * Gets the value of the statementsOrAny property.
111         * 
112         * <p>
113         * This accessor method returns a reference to the live list,
114         * not a snapshot. Therefore any modification you make to the
115         * returned list will be present inside the JAXB object.
116         * This is why there is not a <CODE>set</CODE> method for the statementsOrAny property.
117         * 
118         * <p>
119         * For example, to add a new item, do as follows:
120         * <pre>
121         *    getStatementsOrAny().add(newItem);
122         * </pre>
123         * 
124         * 
125         * <p>
126         * Objects of the following type(s) are allowed in the list
127         * {@link JAXBElement }{@code <}{@link DtoHsqldbJdbcAdapter.Statements }{@code >}
128         * {@link Object }
129         * 
130         * 
131         */
132        public List<Object> getStatementsOrAny() {
133            if (statementsOrAny == null) {
134                statementsOrAny = new ArrayList<Object>();
135            }
136            return this.statementsOrAny;
137        }
138    
139        /**
140         * Gets the value of the batchStatments property.
141         * 
142         * @return
143         *     possible object is
144         *     {@link Boolean }
145         *     
146         */
147        public Boolean isBatchStatments() {
148            return batchStatments;
149        }
150    
151        /**
152         * Sets the value of the batchStatments property.
153         * 
154         * @param value
155         *     allowed object is
156         *     {@link Boolean }
157         *     
158         */
159        public void setBatchStatments(Boolean value) {
160            this.batchStatments = value;
161        }
162    
163        /**
164         * Gets the value of the maxRows property.
165         * 
166         * @return
167         *     possible object is
168         *     {@link BigInteger }
169         *     
170         */
171        public BigInteger getMaxRows() {
172            return maxRows;
173        }
174    
175        /**
176         * Sets the value of the maxRows property.
177         * 
178         * @param value
179         *     allowed object is
180         *     {@link BigInteger }
181         *     
182         */
183        public void setMaxRows(BigInteger value) {
184            this.maxRows = value;
185        }
186    
187        /**
188         * Gets the value of the statements property.
189         * 
190         * @return
191         *     possible object is
192         *     {@link String }
193         *     
194         */
195        public String getStatements() {
196            return statements;
197        }
198    
199        /**
200         * Sets the value of the statements property.
201         * 
202         * @param value
203         *     allowed object is
204         *     {@link String }
205         *     
206         */
207        public void setStatements(String value) {
208            this.statements = value;
209        }
210    
211        /**
212         * Gets the value of the useExternalMessageReferences property.
213         * 
214         * @return
215         *     possible object is
216         *     {@link Boolean }
217         *     
218         */
219        public Boolean isUseExternalMessageReferences() {
220            return useExternalMessageReferences;
221        }
222    
223        /**
224         * Sets the value of the useExternalMessageReferences property.
225         * 
226         * @param value
227         *     allowed object is
228         *     {@link Boolean }
229         *     
230         */
231        public void setUseExternalMessageReferences(Boolean value) {
232            this.useExternalMessageReferences = value;
233        }
234    
235        /**
236         * Gets the value of the id property.
237         * 
238         * @return
239         *     possible object is
240         *     {@link String }
241         *     
242         */
243        public String getId() {
244            return id;
245        }
246    
247        /**
248         * Sets the value of the id property.
249         * 
250         * @param value
251         *     allowed object is
252         *     {@link String }
253         *     
254         */
255        public void setId(String value) {
256            this.id = value;
257        }
258    
259        /**
260         * Gets a map that contains attributes that aren't bound to any typed property on this class.
261         * 
262         * <p>
263         * the map is keyed by the name of the attribute and 
264         * the value is the string value of the attribute.
265         * 
266         * the map returned by this method is live, and you can add new attribute
267         * by updating the map directly. Because of this design, there's no setter.
268         * 
269         * 
270         * @return
271         *     always non-null
272         */
273        public Map<QName, String> getOtherAttributes() {
274            return otherAttributes;
275        }
276    
277        public String toString() {
278            final ToStringStrategy strategy = JAXBToStringStrategy.INSTANCE;
279            final StringBuilder buffer = new StringBuilder();
280            append(null, buffer, strategy);
281            return buffer.toString();
282        }
283    
284        public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
285            strategy.appendStart(locator, this, buffer);
286            appendFields(locator, buffer, strategy);
287            strategy.appendEnd(locator, this, buffer);
288            return buffer;
289        }
290    
291        public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
292            {
293                List<Object> theStatementsOrAny;
294                theStatementsOrAny = (((this.statementsOrAny!= null)&&(!this.statementsOrAny.isEmpty()))?this.getStatementsOrAny():null);
295                strategy.appendField(locator, this, "statementsOrAny", buffer, theStatementsOrAny);
296            }
297            {
298                Boolean theBatchStatments;
299                theBatchStatments = this.isBatchStatments();
300                strategy.appendField(locator, this, "batchStatments", buffer, theBatchStatments);
301            }
302            {
303                BigInteger theMaxRows;
304                theMaxRows = this.getMaxRows();
305                strategy.appendField(locator, this, "maxRows", buffer, theMaxRows);
306            }
307            {
308                String theStatements;
309                theStatements = this.getStatements();
310                strategy.appendField(locator, this, "statements", buffer, theStatements);
311            }
312            {
313                Boolean theUseExternalMessageReferences;
314                theUseExternalMessageReferences = this.isUseExternalMessageReferences();
315                strategy.appendField(locator, this, "useExternalMessageReferences", buffer, theUseExternalMessageReferences);
316            }
317            {
318                String theId;
319                theId = this.getId();
320                strategy.appendField(locator, this, "id", buffer, theId);
321            }
322            return buffer;
323        }
324    
325        public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
326            int currentHashCode = 1;
327            {
328                List<Object> theStatementsOrAny;
329                theStatementsOrAny = (((this.statementsOrAny!= null)&&(!this.statementsOrAny.isEmpty()))?this.getStatementsOrAny():null);
330                currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "statementsOrAny", theStatementsOrAny), currentHashCode, theStatementsOrAny);
331            }
332            {
333                Boolean theBatchStatments;
334                theBatchStatments = this.isBatchStatments();
335                currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "batchStatments", theBatchStatments), currentHashCode, theBatchStatments);
336            }
337            {
338                BigInteger theMaxRows;
339                theMaxRows = this.getMaxRows();
340                currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "maxRows", theMaxRows), currentHashCode, theMaxRows);
341            }
342            {
343                String theStatements;
344                theStatements = this.getStatements();
345                currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "statements", theStatements), currentHashCode, theStatements);
346            }
347            {
348                Boolean theUseExternalMessageReferences;
349                theUseExternalMessageReferences = this.isUseExternalMessageReferences();
350                currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "useExternalMessageReferences", theUseExternalMessageReferences), currentHashCode, theUseExternalMessageReferences);
351            }
352            {
353                String theId;
354                theId = this.getId();
355                currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "id", theId), currentHashCode, theId);
356            }
357            return currentHashCode;
358        }
359    
360        public int hashCode() {
361            final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
362            return this.hashCode(null, strategy);
363        }
364    
365        public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
366            if (!(object instanceof DtoHsqldbJdbcAdapter)) {
367                return false;
368            }
369            if (this == object) {
370                return true;
371            }
372            final DtoHsqldbJdbcAdapter that = ((DtoHsqldbJdbcAdapter) object);
373            {
374                List<Object> lhsStatementsOrAny;
375                lhsStatementsOrAny = (((this.statementsOrAny!= null)&&(!this.statementsOrAny.isEmpty()))?this.getStatementsOrAny():null);
376                List<Object> rhsStatementsOrAny;
377                rhsStatementsOrAny = (((that.statementsOrAny!= null)&&(!that.statementsOrAny.isEmpty()))?that.getStatementsOrAny():null);
378                if (!strategy.equals(LocatorUtils.property(thisLocator, "statementsOrAny", lhsStatementsOrAny), LocatorUtils.property(thatLocator, "statementsOrAny", rhsStatementsOrAny), lhsStatementsOrAny, rhsStatementsOrAny)) {
379                    return false;
380                }
381            }
382            {
383                Boolean lhsBatchStatments;
384                lhsBatchStatments = this.isBatchStatments();
385                Boolean rhsBatchStatments;
386                rhsBatchStatments = that.isBatchStatments();
387                if (!strategy.equals(LocatorUtils.property(thisLocator, "batchStatments", lhsBatchStatments), LocatorUtils.property(thatLocator, "batchStatments", rhsBatchStatments), lhsBatchStatments, rhsBatchStatments)) {
388                    return false;
389                }
390            }
391            {
392                BigInteger lhsMaxRows;
393                lhsMaxRows = this.getMaxRows();
394                BigInteger rhsMaxRows;
395                rhsMaxRows = that.getMaxRows();
396                if (!strategy.equals(LocatorUtils.property(thisLocator, "maxRows", lhsMaxRows), LocatorUtils.property(thatLocator, "maxRows", rhsMaxRows), lhsMaxRows, rhsMaxRows)) {
397                    return false;
398                }
399            }
400            {
401                String lhsStatements;
402                lhsStatements = this.getStatements();
403                String rhsStatements;
404                rhsStatements = that.getStatements();
405                if (!strategy.equals(LocatorUtils.property(thisLocator, "statements", lhsStatements), LocatorUtils.property(thatLocator, "statements", rhsStatements), lhsStatements, rhsStatements)) {
406                    return false;
407                }
408            }
409            {
410                Boolean lhsUseExternalMessageReferences;
411                lhsUseExternalMessageReferences = this.isUseExternalMessageReferences();
412                Boolean rhsUseExternalMessageReferences;
413                rhsUseExternalMessageReferences = that.isUseExternalMessageReferences();
414                if (!strategy.equals(LocatorUtils.property(thisLocator, "useExternalMessageReferences", lhsUseExternalMessageReferences), LocatorUtils.property(thatLocator, "useExternalMessageReferences", rhsUseExternalMessageReferences), lhsUseExternalMessageReferences, rhsUseExternalMessageReferences)) {
415                    return false;
416                }
417            }
418            {
419                String lhsId;
420                lhsId = this.getId();
421                String rhsId;
422                rhsId = that.getId();
423                if (!strategy.equals(LocatorUtils.property(thisLocator, "id", lhsId), LocatorUtils.property(thatLocator, "id", rhsId), lhsId, rhsId)) {
424                    return false;
425                }
426            }
427            return true;
428        }
429    
430        public boolean equals(Object object) {
431            final EqualsStrategy strategy = new org.apache.activemq.plugin.jaxb2_commons.ElementAwareEqualsStrategy();
432            return equals(null, null, object, strategy);
433        }
434    
435    
436        /**
437         * <p>Java class for anonymous complex type.
438         * 
439         * <p>The following schema fragment specifies the expected content contained within this class.
440         * 
441         * <pre>
442         * &lt;complexType>
443         *   &lt;complexContent>
444         *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
445         *       &lt;choice minOccurs="0">
446         *         &lt;element ref="{http://activemq.apache.org/schema/core}statements"/>
447         *         &lt;any namespace='##other'/>
448         *       &lt;/choice>
449         *     &lt;/restriction>
450         *   &lt;/complexContent>
451         * &lt;/complexType>
452         * </pre>
453         * 
454         * 
455         */
456        @XmlAccessorType(XmlAccessType.FIELD)
457        @XmlType(name = "", propOrder = {
458            "statements",
459            "any"
460        })
461        public static class Statements
462            implements Equals, HashCode, ToString
463        {
464    
465            protected DtoStatements statements;
466            @XmlAnyElement(lax = true)
467            protected Object any;
468    
469            /**
470             * Gets the value of the statements property.
471             * 
472             * @return
473             *     possible object is
474             *     {@link DtoStatements }
475             *     
476             */
477            public DtoStatements getStatements() {
478                return statements;
479            }
480    
481            /**
482             * Sets the value of the statements property.
483             * 
484             * @param value
485             *     allowed object is
486             *     {@link DtoStatements }
487             *     
488             */
489            public void setStatements(DtoStatements value) {
490                this.statements = value;
491            }
492    
493            /**
494             * Gets the value of the any property.
495             * 
496             * @return
497             *     possible object is
498             *     {@link Object }
499             *     
500             */
501            public Object getAny() {
502                return any;
503            }
504    
505            /**
506             * Sets the value of the any property.
507             * 
508             * @param value
509             *     allowed object is
510             *     {@link Object }
511             *     
512             */
513            public void setAny(Object value) {
514                this.any = value;
515            }
516    
517            public String toString() {
518                final ToStringStrategy strategy = JAXBToStringStrategy.INSTANCE;
519                final StringBuilder buffer = new StringBuilder();
520                append(null, buffer, strategy);
521                return buffer.toString();
522            }
523    
524            public StringBuilder append(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
525                strategy.appendStart(locator, this, buffer);
526                appendFields(locator, buffer, strategy);
527                strategy.appendEnd(locator, this, buffer);
528                return buffer;
529            }
530    
531            public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) {
532                {
533                    DtoStatements theStatements;
534                    theStatements = this.getStatements();
535                    strategy.appendField(locator, this, "statements", buffer, theStatements);
536                }
537                {
538                    Object theAny;
539                    theAny = this.getAny();
540                    strategy.appendField(locator, this, "any", buffer, theAny);
541                }
542                return buffer;
543            }
544    
545            public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) {
546                int currentHashCode = 1;
547                {
548                    DtoStatements theStatements;
549                    theStatements = this.getStatements();
550                    currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "statements", theStatements), currentHashCode, theStatements);
551                }
552                {
553                    Object theAny;
554                    theAny = this.getAny();
555                    currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "any", theAny), currentHashCode, theAny);
556                }
557                return currentHashCode;
558            }
559    
560            public int hashCode() {
561                final HashCodeStrategy strategy = JAXBHashCodeStrategy.INSTANCE;
562                return this.hashCode(null, strategy);
563            }
564    
565            public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) {
566                if (!(object instanceof DtoHsqldbJdbcAdapter.Statements)) {
567                    return false;
568                }
569                if (this == object) {
570                    return true;
571                }
572                final DtoHsqldbJdbcAdapter.Statements that = ((DtoHsqldbJdbcAdapter.Statements) object);
573                {
574                    DtoStatements lhsStatements;
575                    lhsStatements = this.getStatements();
576                    DtoStatements rhsStatements;
577                    rhsStatements = that.getStatements();
578                    if (!strategy.equals(LocatorUtils.property(thisLocator, "statements", lhsStatements), LocatorUtils.property(thatLocator, "statements", rhsStatements), lhsStatements, rhsStatements)) {
579                        return false;
580                    }
581                }
582                {
583                    Object lhsAny;
584                    lhsAny = this.getAny();
585                    Object rhsAny;
586                    rhsAny = that.getAny();
587                    if (!strategy.equals(LocatorUtils.property(thisLocator, "any", lhsAny), LocatorUtils.property(thatLocator, "any", rhsAny), lhsAny, rhsAny)) {
588                        return false;
589                    }
590                }
591                return true;
592            }
593    
594            public boolean equals(Object object) {
595                final EqualsStrategy strategy = new org.apache.activemq.plugin.jaxb2_commons.ElementAwareEqualsStrategy();
596                return equals(null, null, object, strategy);
597            }
598    
599        }
600    
601    }