Class ResourceReferences<R>
java.lang.Object
com.inductiveautomation.ignition.gateway.config.ResourceReferences<R>
- Type Parameters:
R- the config object type of the resource that holds the references.
All of the references held by a single resource to one other resource, along with the decoded
resource that holds them.
Returned by ResourceReferenceDelegate.getResourceReferences(ConfigurationManager, ResourcePath), one instance per referring resource. Grouping the references this way allows a
rename to rewrite every reference within a resource and emit a single change operation for it.
-
Constructor Summary
ConstructorsConstructorDescriptionResourceReferences(List<ResourceReference<R>> references, DecodedResource<R> decodedResource) -
Method Summary
Modifier and TypeMethodDescriptionbooleanisEmpty()updateReferences(ResourcePath newTargetReference) Rewrites every reference held by this resource to point at the given path.
-
Constructor Details
-
ResourceReferences
public ResourceReferences(List<ResourceReference<R>> references, DecodedResource<R> decodedResource)
-
-
Method Details
-
getReferences
- Returns:
- the individual references held by this resource.
-
isEmpty
public boolean isEmpty()- Returns:
- true if this resource holds no references to the target resource.
-
updateReferences
Rewrites every reference held by this resource to point at the given path.Calling this updates the resource held by this instance, so it must only be called once per rename.
- Parameters:
newTargetReference- the new path of the resource being referenced.- Returns:
- a single modify operation carrying the rewritten resource.
-