Package org.yamcs.xtce.util
Class UnresolvedNameReference
- java.lang.Object
-
- org.yamcs.xtce.util.AbstractNameReference
-
- org.yamcs.xtce.util.UnresolvedNameReference
-
- All Implemented Interfaces:
NameReference
- Direct Known Subclasses:
UnresolvedArgumentReference
,UnresolvedParameterReference
public class UnresolvedNameReference extends AbstractNameReference
Stores actions related to unresolved references and calls them once the reference has been resolved.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.yamcs.xtce.util.NameReference
NameReference.ResolvedAction, NameReference.Type
-
-
Field Summary
-
Fields inherited from class org.yamcs.xtce.util.AbstractNameReference
ref, type
-
-
Constructor Summary
Constructors Constructor Description UnresolvedNameReference(String ref, NameReference.Type type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UnresolvedNameReference
addResolvedAction(NameReference.ResolvedAction action)
Adds an action to the list to be executed when the reference is resolved and returns this.CompletableFuture<NameDescription>
getResolvedFuture()
returns a future that is called when the reference is resolvedboolean
isResolved()
boolean
tryResolve(NameDescription nd)
Execute all the actions (if not already executed) and return true if the reference has been resolved.-
Methods inherited from class org.yamcs.xtce.util.AbstractNameReference
getReference, getType, toString
-
-
-
-
Constructor Detail
-
UnresolvedNameReference
public UnresolvedNameReference(String ref, NameReference.Type type)
-
-
Method Detail
-
tryResolve
public boolean tryResolve(NameDescription nd)
Description copied from interface:NameReference
Execute all the actions (if not already executed) and return true if the reference has been resolved.- Returns:
- true if the reference has been resolved
-
addResolvedAction
public UnresolvedNameReference addResolvedAction(NameReference.ResolvedAction action)
Description copied from interface:NameReference
Adds an action to the list to be executed when the reference is resolved and returns this. If the reference is already resolved, execute the action immediately.- Returns:
- this
-
isResolved
public boolean isResolved()
-
getResolvedFuture
public CompletableFuture<NameDescription> getResolvedFuture()
Description copied from interface:NameReference
returns a future that is called when the reference is resolved- Returns:
-
-