001    //
002    // This file was generated by the JavaTM Architecture for XML Binding(JAXB) Reference Implementation, vhudson-jaxb-ri-2.1-833 
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: 2009.10.02 at 06:12:00 PM UTC 
006    //
007    
008    
009    package org.jomc.model.test;
010    
011    import java.util.ArrayList;
012    import java.util.Iterator;
013    import java.util.List;
014    import javax.annotation.Generated;
015    import javax.xml.bind.annotation.XmlAccessType;
016    import javax.xml.bind.annotation.XmlAccessorType;
017    import javax.xml.bind.annotation.XmlAttribute;
018    import javax.xml.bind.annotation.XmlType;
019    
020    
021    /**
022     * Performs modules validation.
023     * 
024     * 
025     * 
026     */
027    @XmlAccessorType(XmlAccessType.FIELD)
028    @XmlType(name = "ModulesConstraintsTest", propOrder = {
029        "modules",
030        "detail"
031    })
032    @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
033    public class ModulesConstraintsTest
034        implements Cloneable
035    {
036    
037        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
038        protected AnyModelObject modules;
039        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
040        protected List<ModelExceptionDetail> detail;
041        @XmlAttribute(required = true)
042        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
043        protected String identifier;
044    
045        /**
046         * Creates a new {@code ModulesConstraintsTest} instance.
047         * 
048         */
049        public ModulesConstraintsTest() {
050             // CC-XJC Version 1.0 Build 2009-09-18T15:48:40+0000
051            super();
052        }
053    
054        /**
055         * Creates a new {@code ModulesConstraintsTest} instance by deeply copying a given instance.
056         * 
057         * @param o
058         *     The instance to copy or {@code null}.
059         */
060        public ModulesConstraintsTest(final ModulesConstraintsTest o) {
061             // CC-XJC Version 1.0 Build 2009-09-18T15:48:40+0000
062            super();
063            if (o!= null) {
064                {
065                    // CClassInfo: org.jomc.model.test.AnyModelObject
066                    this.modules = ((((AnyModelObject) o.getModules()) == null)?null:((AnyModelObject) o.getModules()).clone());
067                    // 'Detail' collection.
068                    copyDetail(o.getDetail(), getDetail());
069                    // CBuiltinLeafInfo: java.lang.String
070                    this.identifier = ((String) o.getIdentifier());
071                }
072            }
073        }
074    
075        /**
076         * Gets the value of the modules property.
077         * 
078         * @return
079         *     possible object is
080         *     {@link AnyModelObject }
081         *     
082         */
083        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
084        public AnyModelObject getModules() {
085            return modules;
086        }
087    
088        /**
089         * Sets the value of the modules property.
090         * 
091         * @param value
092         *     allowed object is
093         *     {@link AnyModelObject }
094         *     
095         */
096        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
097        public void setModules(AnyModelObject value) {
098            this.modules = value;
099        }
100    
101        /**
102         * Gets the value of the detail property.
103         * 
104         * <p>
105         * This accessor method returns a reference to the live list,
106         * not a snapshot. Therefore any modification you make to the
107         * returned list will be present inside the JAXB object.
108         * This is why there is not a <CODE>set</CODE> method for the detail property.
109         * 
110         * <p>
111         * For example, to add a new item, do as follows:
112         * <pre>
113         *    getDetail().add(newItem);
114         * </pre>
115         * 
116         * 
117         * <p>
118         * Objects of the following type(s) are allowed in the list
119         * {@link ModelExceptionDetail }
120         * 
121         * 
122         */
123        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
124        public List<ModelExceptionDetail> getDetail() {
125            if (detail == null) {
126                detail = new ArrayList<ModelExceptionDetail>();
127            }
128            return this.detail;
129        }
130    
131        /**
132         * Identifier of this test.
133         * 
134         * @return
135         *     possible object is
136         *     {@link String }
137         *     
138         */
139        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
140        public String getIdentifier() {
141            return identifier;
142        }
143    
144        /**
145         * Sets the value of the identifier property.
146         * 
147         * @param value
148         *     allowed object is
149         *     {@link String }
150         *     
151         */
152        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
153        public void setIdentifier(String value) {
154            this.identifier = value;
155        }
156    
157        /**
158         * Copies all values of property {@code Detail} deeply.
159         * 
160         * @param target
161         *     The target to copy {@code source} to.
162         * @param source
163         *     The source to copy from.
164         * @throws NullPointerException
165         *     if {@code source} or {@code target} is {@code null}.
166         */
167        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
168        private static void copyDetail(final List<ModelExceptionDetail> source, final List<ModelExceptionDetail> target) {
169            // CC-XJC Version 1.0 Build 2009-09-18T15:48:40+0000
170            if (!source.isEmpty()) {
171                for (Iterator it = source.iterator(); it.hasNext(); ) {
172                    final Object next = it.next();
173                    if (next instanceof ModelExceptionDetail) {
174                        // CClassInfo: org.jomc.model.test.ModelExceptionDetail
175                        target.add(((ModelExceptionDetail) next).clone());
176                        continue;
177                    }
178                    // Please report this at https://apps.sourceforge.net/mantisbt/ccxjc/
179                    throw new AssertionError((("Unexpected instance '"+ next)+"' for property 'Detail' of class 'org.jomc.model.test.ModulesConstraintsTest'."));
180                }
181            }
182        }
183    
184        /**
185         * Creates and returns a deep copy of this object.
186         * 
187         * 
188         * @return
189         *     A deep copy of this object.
190         */
191        @Override
192        @Generated(value = "com.sun.tools.xjc.Driver", date = "2009-10-02T06:12:00+00:00", comments = "JAXB RI vhudson-jaxb-ri-2.1-833")
193        public ModulesConstraintsTest clone() {
194             // CC-XJC Version 1.0 Build 2009-09-18T15:48:40+0000
195            return new ModulesConstraintsTest(this);
196        }
197    
198    }