Class ArrayType


  • public class ArrayType
    extends JavaClass
    Describes a Java Array type For multi-dimensional arrays, it is unlikely that the component type will be specified directly. This would require instantiating a chain of component types such as String[][][][]->String[][][]->String[][]->String[]->String. The component type relationship will be computed if the finalComponentType and array dimensions is specified. For this reason, the preferred way to create is through the JavaRefFactory factory method: createArrayType(JavaClass finalComponentType, int dimensions) Java class for ArrayType complex type. The following schema fragment specifies the expected content contained within this class.
     <complexType name="ArrayType">
       <complexContent>
         <extension base="{java.xmi}JavaClass">
           <choice maxOccurs="unbounded" minOccurs="0">
             <element name="componentType" type="{http://www.eclipse.org/emf/2002/Ecore}EClassifier"/>
           </choice>
           <attribute name="arrayDimensions" type="{http://www.w3.org/2001/XMLSchema}int" />
           <attribute name="componentType" type="{http://www.w3.org/2001/XMLSchema}string" />
         </extension>
       </complexContent>
     </complexType>
     
    • Field Detail

      • arrayDimensions

        protected Integer arrayDimensions
      • componentType

        protected String componentType
    • Constructor Detail

      • ArrayType

        public ArrayType()
    • Method Detail

      • getComponentTypes

        public List<EClassifier> getComponentTypes()
        Gets the value of the componentTypes property. This accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the JAXB object. This is why there is not a set method for the componentTypes property. For example, to add a new item, do as follows:
         getComponentTypes().add(newItem);
         
        Objects of the following type(s) are allowed in the list EClassifier
      • getArrayDimensions

        public Integer getArrayDimensions()
        Gets the value of the arrayDimensions property.
        Returns:
        possible object is Integer
      • setArrayDimensions

        public void setArrayDimensions​(Integer value)
        Sets the value of the arrayDimensions property.
        Parameters:
        value - allowed object is Integer
      • getComponentType

        public String getComponentType()
        Gets the value of the componentType property.
        Returns:
        possible object is String
      • setComponentType

        public void setComponentType​(String value)
        Sets the value of the componentType property.
        Parameters:
        value - allowed object is String