net.sf.saxon.query

## Class Annotation

- java.lang.Object
- - net.sf.saxon.query.Annotation

- Direct Known Subclasses:
    Annotation30

      public abstract class Annotation
      extends Object

  This class represents an annotation that appears in a function or variable declarations

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static StructuredQName` | `PRIVATE`
    `static StructuredQName` | `PUBLIC`
    `static StructuredQName` | `SIMPLE`
    `static StructuredQName` | `UPDATING`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `Annotation()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract void` | `addAnnotationParameter(AtomicValue value)` Add a value to the list of annotation parameters
    `abstract List<AtomicValue>` | `getAnnotationParameters()` Get the list of annotation parameters
    `abstract StructuredQName` | `getAnnotationQName()` Get the name of the annotation (a QName)
    `static boolean` | `mutuallyExclusive(Annotation one, Annotation two)` Determine whether two annotations are mutually exclusive

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### UPDATING

          public static final StructuredQName UPDATING

    - #### SIMPLE

          public static final StructuredQName SIMPLE

    - #### PRIVATE

          public static final StructuredQName PRIVATE

    - #### PUBLIC

          public static final StructuredQName PUBLIC

  - ### Constructor Detail

    - #### Annotation

          public Annotation()

  - ### Method Detail

    - #### getAnnotationQName

          public abstract StructuredQName getAnnotationQName()

      Get the name of the annotation (a QName)
      Returns:
        the annotation name

    - #### addAnnotationParameter

          public abstract void addAnnotationParameter(AtomicValue value)

      Add a value to the list of annotation parameters
      Parameters:
        `value` - the value to be added. This will always be a string or number, but Saxon enforces this only at the level of the query parser

    - #### getAnnotationParameters

          public abstract List<AtomicValue> getAnnotationParameters()

      Get the list of annotation parameters
      Returns:
        the list of parameters

    - #### mutuallyExclusive

          public static boolean mutuallyExclusive(Annotation one,
                                  Annotation two)

      Determine whether two annotations are mutually exclusive
      Parameters:
        `one` - the first annotation
        `two` - the second annotation
      Returns:
        true if these two annotations cannot appear together on the same function or variable declaration

Copyright (c) 2004-2013 Saxonica Limited. All rights reserved.