       1 /*
       2  * $Id$
       3  *
       4  * Copyright (c) 2006, 2009, Oracle and/or its affiliates. All rights reserved.
       5  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
       6  *
       7  * This code is free software; you can redistribute it and/or modify it
       8  * under the terms of the GNU General Public License version 2 only, as
       9  * published by the Free Software Foundation.  Oracle designates this
      10  * particular file as subject to the "Classpath" exception as provided
      11  * by Oracle in the LICENSE file that accompanied this code.
      12  *
      13  * This code is distributed in the hope that it will be useful, but WITHOUT
      14  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
      15  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
      16  * version 2 for more details (a copy is included in the LICENSE file that
      17  * accompanied this code).
      18  *
      19  * You should have received a copy of the GNU General Public License version
      20  * 2 along with this work; if not, write to the Free Software Foundation,
      21  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
      22  *
      23  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
      24  * or visit www.oracle.com if you need additional information or have any
      25  * questions.
      26  */
      27 package com.sun.javatest.cof;
      28
      29 import java.util.ArrayList;
      30 import java.util.LinkedHashMap;
      31 import java.util.List;
      32 /*import javax.xml.bind.annotation.XmlAccessType;
      33 import javax.xml.bind.annotation.XmlAccessorType;
      34 import javax.xml.bind.annotation.XmlElement;
      35 import javax.xml.bind.annotation.XmlType;
      36 */
      37
      38 /**
      39  *
      40  *         Some attributes are used by the QARE test database system. One
      41  *         of these is the name of your testing group. The name of the
      42  *         annotation for this is "test_group". An example of such a group
      43  *         is "J2SE QA".
      44  *
      45  *
      46  * <p>Java class for ReportAnnotation complex type.
      47  *
      48  * <p>The following schema fragment specifies the expected content contained within this class.
      49  *
      50  * <pre>
      51  * &lt;complexType name="ReportAnnotation">
      52  *   &lt;complexContent>
      53  *     &lt;restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
      54  *       &lt;sequence>
      55  *         &lt;element name="name" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
      56  *         &lt;element name="value" type="{http://www.w3.org/2001/XMLSchema}string" maxOccurs="unbounded"/>
      57  *       &lt;/sequence>
      58  *     &lt;/restriction>
      59  *   &lt;/complexContent>
      60  * &lt;/complexType>
      61  * </pre>
      62  *
      63  *
      64  */
      65 /*@XmlAccessorType(XmlAccessType.FIELD)
      66 @XmlType(name = "ReportAnnotation", propOrder = {
      67     "name",
      68     "value"
      69 })*/
      70 public class COFReportAnnotation extends COFItem{
      71
      72 static LinkedHashMap<String, String> xmlAttributes;
      73 static LinkedHashMap<String, String> xmlElements;
      74
      75     static String xmlTagName;
      76
      77     static  {
      78                 xmlElements = new LinkedHashMap<>();
      79                 xmlElements.put("name", "name");
      80                 xmlElements.put("value","value");
      81                 xmlTagName = "annotation";
      82         }
      83     //    @XmlElement(namespace = "http://qare.sfbay.sun.com/projects/COF/2003/2_0_2/Schema", required = true)
      84     protected List<String> name;
      85
      86         //    @XmlElement(namespace = "http://qare.sfbay.sun.com/projects/COF/2003/2_0_2/Schema", required = true)
      87     protected List<String> value;
      88
      89         LinkedHashMap<String, String> getItemAttributes() {
      90                 return xmlAttributes;
      91         }
      92
      93         LinkedHashMap<String, String> getItemElements() {
      94                 return xmlElements;
      95         }
      96
      97         String getItemTagName() {
      98                 return xmlTagName;
      99         }
     100
     101         /**
     102      * Gets the value of the name 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 name property.
     109      *
     110      * <p>
     111      * For example, to add a new item, do as follows:
     112      * <pre>
     113      *    getName().add(newItem);
     114      * </pre>
     115      *
     116      *
     117      * <p>
     118      * Objects of the following type(s) are allowed in the list
     119      * {@link String }
     120      *
     121      *
     122      */
     123     public List<String> getName() {
     124         if (name == null) {
     125             name = new ArrayList<>();
     126         }
     127         return this.name;
     128     }
     129
     130         /**
     131      * Gets the value of the value property.
     132      *
     133      * <p>
     134      * This accessor method returns a reference to the live list,
     135      * not a snapshot. Therefore any modification you make to the
     136      * returned list will be present inside the JAXB object.
     137      * This is why there is not a <CODE>set</CODE> method for the value property.
     138      *
     139      * <p>
     140      * For example, to add a new item, do as follows:
     141      * <pre>
     142      *    getValue().add(newItem);
     143      * </pre>
     144      *
     145      *
     146      * <p>
     147      * Objects of the following type(s) are allowed in the list
     148      * {@link String }
     149      *
     150      *
     151      */
     152     public List<String> getValue() {
     153         if (value == null) {
     154             value = new ArrayList<>();
     155         }
     156         return this.value;
     157     }
     158
     159 }