oracle.dbtools.plugin.api.di

## Class AnnotationsProvider

- java.lang.Object
- - oracle.dbtools.plugin.api.di.AnnotationsProvider

- All Implemented Interfaces:
    Annotations

      public class AnnotationsProvider
      extends Object
      implements Annotations

  Provides methods for working with annotations.
  Author:
    cdivilly

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from interface oracle.dbtools.plugin.api.di.Annotations

      `Annotations.Builder<T extends Annotation>`

  - ### Field Summary

    - ### Fields inherited from interface oracle.dbtools.plugin.api.di.Annotations

      `INSTANCE`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `<T extends Annotation> Annotations.Builder<T>` | `create(Class<T> type)` Create an `Annotation` literal `Annotations.Builder`.
    `boolean` | `equals(Annotation[] expected, Annotation[] actual)` Determines if one array of annotations is exactly equivalent to another
    `<T extends Annotation> T` | `literal(Class<T> type)` Create an `Annotation` literal value that has no properties.
    `<T extends Annotation> T` | `literal(Class<T> type, Object value)` Create an `Annotation` literal value for the specified `Annotation` type, using the specified #value() property.
    `boolean` | `matches(Iterable<? extends Annotation> expected, Iterable<? extends Annotation> actual)` Determines if one array of annotations is a subset of another
    `<T extends Annotation> Annotations.Builder<T>` | `modify(T annotation)` Create an `Annotation` literal `Annotations.Builder` initialized with the values of an existing annotation.

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

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

    - ### Methods inherited from interface oracle.dbtools.plugin.api.di.Annotations

      `instance, matches`

- - ### Method Detail

    - #### create

          public <T extends Annotation> Annotations.Builder<T> create(Class<T> type)

      Description copied from interface: `Annotations`
      Create an `Annotation` literal `Annotations.Builder`.
      Specified by:
        `create` in interface `Annotations`
      Type Parameters:
        `T` - An instance of an `Annotation` sub-type
      Parameters:
        `type` - The type of annotation to build
      Returns:
        a `Annotations.Builder` instance.
      See Also:
        `Annotations.Builder`

    - #### equals

          public boolean equals(Annotation[] expected,
                                Annotation[] actual)

      Description copied from interface: `Annotations`
      Determines if one array of annotations is exactly equivalent to another
      Specified by:
        `equals` in interface `Annotations`
      Parameters:
        `expected` - The annotations that must be present
        `actual` - The annotations that are present
      Returns:
        true if the actual set of annotations is identical to the expected set of annotations

    - #### literal

          public <T extends Annotation> T literal(Class<T> type)

      Description copied from interface: `Annotations`
      Create an `Annotation` literal value that has no properties.
      Specified by:
        `literal` in interface `Annotations`
      Type Parameters:
        `T` - An instance of an `Annotation` sub-type
      Parameters:
        `type` - The type of annotation to instantiate
      Returns:
        Annotation instance

    - #### literal

          public <T extends Annotation> T literal(Class<T> type,
                                                  Object value)

      Description copied from interface: `Annotations`
      Create an `Annotation` literal value for the specified `Annotation` type, using the specified #value() property.
      Specified by:
        `literal` in interface `Annotations`
      Type Parameters:
        `T` - An instance of an `Annotation` sub-type
      Parameters:
        `type` - The type of annotation to instantiate
        `value` - The value to assign to the `#value()` property
      Returns:
        Annotation instance

    - #### matches

          public boolean matches(Iterable<? extends Annotation> expected,
                                 Iterable<? extends Annotation> actual)

      Description copied from interface: `Annotations`
      Determines if one array of annotations is a subset of another
      Specified by:
        `matches` in interface `Annotations`
      Parameters:
        `expected` - The annotations that must be present
        `actual` - The annotations that are present
      Returns:
        true if the actual set of annotations contains every annotation in the expected set, false otherwise

    - #### modify

          public <T extends Annotation> Annotations.Builder<T> modify(T annotation)

      Description copied from interface: `Annotations`
      Create an `Annotation` literal `Annotations.Builder` initialized with the values of an existing annotation.
      Specified by:
        `modify` in interface `Annotations`
      Type Parameters:
        `T` - An instance of an `Annotation` sub-type
      Parameters:
        `annotation` - The existing annotation instance
      Returns:
        `Annotations.Builder` instance

Copyright © 2010, 2022, Oracle and/or its affiliates.