Package com.adobe.xfa

Class SchemaPairs


  • public final class SchemaPairs
    extends Object
    This class is used to store schema relationships. It stores an array of schema tags along with either a corresponding array of either ChildReln or an Attribute.
    • Constructor Detail

      • SchemaPairs

        public SchemaPairs​(SchemaPairs other)
      • SchemaPairs

        public SchemaPairs()
    • Method Detail

      • get

        public Object get​(int eTag)
        Gets the value for a specific key (tag)
        Parameters:
        eTag - the tag to search for
        Returns:
        the Schema object corresponding to the tag. null if not found.
      • key

        public int key​(int index)
        Returns the key (tag) at this position in the list.
        Parameters:
        index - the position in the list
        Returns:
        the tag number
      • put

        public void put​(int eTag,
                        Object schema)
        Adds a schema pair to the list. We first check if the value exists and if it does we replace the existing value. We sort the internal list by tag number.
        Parameters:
        eTag - the tag of the schema element we're adding
        schema - the schema object - Normally a ChildReln or an Attribute
      • size

        public int size()
        Returns the size of the list.
        Returns:
        the list size.
      • value

        public Object value​(int index)
        Returns the schema object at this position in the list
        Parameters:
        index - the position in the list
        Returns:
        the schema object