public interface Condition extends Iterable<ConditionLeaf>
Condition may be one of three types:
If it's one of the first two types, then you can get the children
conditions by calling the getChildren() method.
If it's a leaf, then you can get it using toLeaf() method
The Condition implements Iterable<ClassCondition>
so that you can easily inspect all the leaves if you only
care about the conditions leaves in separation from the expression
structure. The order of iteration is undefined.
| Modifier and Type | Interface and Description |
|---|---|
static class |
Condition.Type |
| Modifier and Type | Method and Description |
|---|---|
io.atlassian.fugue.Maybe<List<Condition>> |
getChildren()
Returns a list of sub-conditions if this condition is
of type
Condition.Type.CONJUNCTION or Condition.Type.ALTERNATIVE,
otherwise none. |
Condition.Type |
getType()
Returns this condition type.
|
io.atlassian.fugue.Maybe<ConditionLeaf> |
toLeaf()
Returns itself if this object is a leaf, otherwise none.
|
forEach, iterator, spliteratorCondition.Type getType()
getChildren() or toLeaf().io.atlassian.fugue.Maybe<List<Condition>> getChildren()
Condition.Type.CONJUNCTION or Condition.Type.ALTERNATIVE,
otherwise none.
The returned list is immutable.
io.atlassian.fugue.Maybe<ConditionLeaf> toLeaf()
Copyright © 2023 Atlassian. All rights reserved.