All Implemented Interfaces:
IDatatype, IDatatypeVisitable, IModelElement

public class Sequence extends Container
Realizes a sequence container. This represents an array.
Author:
heiko beck, Holger Eichelberger
  • Field Details

    • DTYPE

      static final DelegatingType DTYPE
    • TYPE

      public static final IDatatype TYPE
      This constant represents the common type of all sets. Each specific sequence type is assignable to this type.
    • INDEX_ACCESS

      public static final Operation INDEX_ACCESS
    • AT

      public static final Operation AT
    • FIRST

      public static final Operation FIRST
    • LAST

      public static final Operation LAST
    • AS_SET

      public static final Operation AS_SET
    • TO_SET

      public static final Operation TO_SET
    • AS_SEQUENCE

      public static final Operation AS_SEQUENCE
    • TO_SEQUENCE

      public static final Operation TO_SEQUENCE
    • UNION

      public static final Operation UNION
    • APPEND

      public static final Operation APPEND
    • PREPEND

      public static final Operation PREPEND
    • INSERT_AT

      public static final Operation INSERT_AT
    • INDEX_OF

      public static final Operation INDEX_OF
    • HAS_DUPLICATES

      public static final Operation HAS_DUPLICATES
    • EXCLUDING

      public static final Operation EXCLUDING
    • INCLUDING

      public static final Operation INCLUDING
    • REVERSE

      public static final Operation REVERSE
    • SUBSEQUENCE

      public static final Operation SUBSEQUENCE
    • ADD

      public static final Operation ADD
    • ISSUBSEQUENCE

      public static final Operation ISSUBSEQUENCE
    • OVERLAPS

      public static final Operation OVERLAPS
    • FLATTEN

      public static final Operation FLATTEN
    • EQUALS

      public static final Operation EQUALS
    • ASSIGNMENT

      public static final Operation ASSIGNMENT
  • Constructor Details

    • Sequence

      private Sequence()
      Creates the singleton instance.
    • Sequence

      public Sequence(String name, IDatatype type, IModelElement parent)
      Constructor for the container.
      Parameters:
      name - Name of the container
      type - data type of the container elements
      parent - the object, in which this specific one is embedded
  • Method Details

    • accept

      public void accept(IModelVisitor visitor)
      Accept method for the visitor.
      Specified by:
      accept in interface IModelElement
      Overrides:
      accept in class Container
      Parameters:
      visitor - The visitor, which should process this model element.
    • accept

      public void accept(IDatatypeVisitor visitor)
      Description copied from interface: IDatatypeVisitable
      Accepts a specialized visitor for creating a textual representation of the identity of this type.
      Specified by:
      accept in interface IDatatypeVisitable
      Overrides:
      accept in class Container
      Parameters:
      visitor - the visitor to accept
    • isSequence

      public static final boolean isSequence(IDatatype type, IDatatype... generics)
      Returns whether type is a squence and the given generics match.
      Parameters:
      type - the type to check for
      generics - the generics to be considered
      Returns:
      true if type is sequenceOf(generics), false else