Class NamespaceKeyCriterion<K>
- java.lang.Object
-
- org.opendaylight.yangtools.yang.parser.spi.meta.NamespaceKeyCriterion<K>
-
-
Constructor Summary
Constructors Constructor Description NamespaceKeyCriterion()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected MoreObjects.ToStringHelper
addToStringAttributes(MoreObjects.ToStringHelper toStringHelper)
boolean
equals(Object obj)
int
hashCode()
static NamespaceKeyCriterion<SourceIdentifier>
latestRevisionModule(String moduleName)
Return a criterion which selects the latest known revision of a particular module.abstract boolean
match(@NonNull K key)
Match a key against this criterion.abstract K
select(@NonNull K first, @NonNull K second)
Select the better match from two candidate keys.String
toString()
-
-
-
Method Detail
-
latestRevisionModule
public static NamespaceKeyCriterion<SourceIdentifier> latestRevisionModule(String moduleName)
Return a criterion which selects the latest known revision of a particular module.- Parameters:
moduleName
- Module name- Returns:
- A criterion object.
-
match
public abstract boolean match(@NonNull K key)
Match a key against this criterion.- Parameters:
key
- Key to be matched- Returns:
- True if the key matches this criterion, false otherwise.
-
select
public abstract K select(@NonNull K first, @NonNull K second)
Select the better match from two candidate keys.- Parameters:
first
- First keysecond
- Second key- Returns:
- Selected key, must be either first or second key, by identity.
-
addToStringAttributes
protected MoreObjects.ToStringHelper addToStringAttributes(MoreObjects.ToStringHelper toStringHelper)
-
-