Class Annotation

All Implemented Interfaces:
IKeyed<Annotation>, INamed, NamespacedEntity, NamespaceProvider, ClassifierInstance<Concept>, HasFeatureValues, Node

public class Annotation extends Classifier<Annotation>
This represents additional metadata relative to some orthogonal concern.

While an AnnotationInstance implements HasFeatureValues, it is forbidden to hold any Containment links. This is checked during validation.

A DocumentationComment could be specified as an annotation.

See Also:
  • Constructor Details

    • Annotation

      public Annotation(@Nonnull LionWebVersion lionWebVersion)
    • Annotation

      public Annotation()
    • Annotation

      public Annotation(@Nullable Language language, @Nullable String name)
    • Annotation

      public Annotation(@Nullable Language language, @Nullable String name, @Nonnull String id)
    • Annotation

      public Annotation(@Nullable Language language, @Nullable String name, @Nonnull String id, @Nullable String key)
  • Method Details

    • getAnnotates

      @Nullable public Classifier<?> getAnnotates()
    • getEffectivelyAnnotated

      @Nullable public Classifier<?> getEffectivelyAnnotated()
      An Annotation extending another annotation should not redefine annotates. So the value is effectively inherited from the super annotation.
    • getExtendedAnnotation

      @Nullable public Annotation getExtendedAnnotation()
    • getImplemented

      @Nonnull public List<Interface> getImplemented()
    • addImplementedInterface

      public void addImplementedInterface(@Nonnull Interface iface)
    • setExtendedAnnotation

      public void setExtendedAnnotation(@Nullable Annotation extended)
    • setAnnotates

      public void setAnnotates(@Nullable Classifier<?> target)
    • directAncestors

      @Nonnull public List<Classifier<?>> directAncestors()
      Specified by:
      directAncestors in class Classifier<Annotation>
    • inheritedFeatures

      @Nonnull public List<Feature<?>> inheritedFeatures()
      Specified by:
      inheritedFeatures in class Classifier<Annotation>
    • getClassifier

      public Concept getClassifier()
      Description copied from interface: Node
      The concept of which this Node is an instance. The Concept should not be abstract.