public abstract class AbstractRecursiveRequirement<A,B> extends java.lang.Object implements Requirement<A,B,java.util.List<Requirement<A,B,?>>>
Modifier and Type | Field and Description |
---|---|
protected java.util.List<Requirement<A,B,?>> |
requirements |
Constructor and Description |
---|
AbstractRecursiveRequirement(java.lang.Class<? extends Specification<A,B>> clazz,
java.util.Set<java.lang.String> keys) |
AbstractRecursiveRequirement(java.lang.Class<? extends Specification<A,B>> clazz,
java.util.Set<java.lang.String> keys,
java.util.List<Requirement<A,B,?>> requirements) |
Modifier and Type | Method and Description |
---|---|
java.util.List<Requirement<A,B,?>> |
create(java.lang.String spec)
Creates a list of requirements from the spec being parsed
|
boolean |
fits(java.lang.String spec)
Checks if the given fits for this requirement
|
java.util.List<java.lang.String> |
getAliases() |
int |
getPriority()
Gets the order priority of the requirement.
|
java.util.List<Requirement<A,B,?>> |
getValue()
Gets the internal value of the requirement
|
boolean |
shouldContinue()
If the spec should continue processing the results after applying this requirement
For example, for a logical AND this would return false as it handles the processing of the remaining requirements
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
applyData, applyMinecraft, createInstance, isDataMatch, isMinecraftMatch
protected java.util.List<Requirement<A,B,?>> requirements
public AbstractRecursiveRequirement(java.lang.Class<? extends Specification<A,B>> clazz, java.util.Set<java.lang.String> keys)
public AbstractRecursiveRequirement(java.lang.Class<? extends Specification<A,B>> clazz, java.util.Set<java.lang.String> keys, java.util.List<Requirement<A,B,?>> requirements)
public java.util.List<java.lang.String> getAliases()
getAliases
in interface Requirement<A,B,java.util.List<Requirement<A,B,?>>>
public int getPriority()
Requirement
getPriority
in interface Requirement<A,B,java.util.List<Requirement<A,B,?>>>
public boolean shouldContinue()
Requirement
shouldContinue
in interface Requirement<A,B,java.util.List<Requirement<A,B,?>>>
public boolean fits(java.lang.String spec)
Requirement
fits
in interface Requirement<A,B,java.util.List<Requirement<A,B,?>>>
spec
- The parsed specpublic java.util.List<Requirement<A,B,?>> create(java.lang.String spec)
Requirement
create
in interface Requirement<A,B,java.util.List<Requirement<A,B,?>>>
spec
- The spec being parsedpublic java.util.List<Requirement<A,B,?>> getValue()
Requirement
getValue
in interface Requirement<A,B,java.util.List<Requirement<A,B,?>>>