Class AnnList

All Implemented Interfaces:
Iterable<Ann>

public final class AnnList extends ObjectList<Ann,AnnList>
List of annotations.
Author:
BaseX Team 2005-21, BSD License, Christian Gruen
  • Constructor Details

    • AnnList

      public AnnList()
  • Method Details

    • contains

      public boolean contains(Annotation sig)
      Checks if the specified signature is found in the list.
      Parameters:
      sig - signature to be found
      Returns:
      result of check
    • get

      public Ann get(Annotation sig)
      Returns an annotation with the specified signature.
      Parameters:
      sig - signature to be found
      Returns:
      annotation or null
    • intersect

      public AnnList intersect(AnnList anns)
      Returns the intersection of these annotations and the given ones.
      Parameters:
      anns - other annotations
      Returns:
      a new instance with all annotations, or null if intersection is not possible
    • union

      public AnnList union(AnnList anns)
      Returns the unions of these annotations and the given ones.
      Parameters:
      anns - annotations
      Returns:
      a new instance with annotations that are present in both lists
    • check

      public AnnList check(boolean variable, boolean visible) throws QueryException
      Checks all annotations for parsing errors.
      Parameters:
      variable - variable flag (triggers different error codes)
      visible - check visibility annotations
      Returns:
      self reference
      Throws:
      QueryException - query exception
    • newArray

      protected Ann[] newArray(int s)
      Description copied from class: ObjectList
      Creates a resized array.
      Specified by:
      newArray in class ObjectList<Ann,AnnList>
      Parameters:
      s - size
      Returns:
      array
    • plan

      public void plan(QueryString qs)
      Adds the annotations to a query string.
      Parameters:
      qs - query string builder