@Deprecated(since="8.3.2", forRemoval=true) public interface Reference
Deprecated, for removal: This API element is subject to removal in a future version.
Deprecated since 8.3.2. Targeted for removal in version 2027. Use ResourceReference instead.
A reference represents when a property of a resource references another resource. For example, a database alarm journal profile may reference a database connection. In this example, the alarm journal represents the "source" of the reference, and the database connection is the "target".

References are used to find dependencies between resources so that rename and delete operations can be performed safely. When a rename or delete operation detects a reference, it can force the user to confirm that the operation will break references (delete), or by automatically updating references to the new name (rename).

To support rename, the reference must also contain the logic to create a new copy of the relevant source configuration with the reference updated to a new name.

Note that it is not common to use this class directly. Instead, you will register ReferenceProperty objects to describe the reference properties within your resource type or extension point, which will then be automatically used by the system to create these Reference objects.

  • Method Details

    • getSourceResource

      ResourcePath getSourceResource()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getSourceProperty

      String getSourceProperty()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getTargetResource

      ResourcePath getTargetResource()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • updateReference

      Optional<ChangeOperation> updateReference(ResourcePath newTargetReference)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • create

      static Reference create(ResourcePath sourceResource, String sourceProperty, ResourcePath targetResource, Function<ResourcePath,ChangeOperation> updateFunction)
      Deprecated, for removal: This API element is subject to removal in a future version.