public abstract class Matcher<T> extends java.lang.Object implements ToNode
| Modifier and Type | Class and Description |
|---|---|
static class |
Matcher.ErrorTypeMember
Matches if an operation returns an error, and the error matches the
expected error type.
|
static class |
Matcher.InputOutputMember |
static class |
Matcher.OutputMember |
static class |
Matcher.SuccessMember
When set to true, matches when a call returns a success response.
|
static class |
Matcher.UnknownMember
Represents an union value.
|
static interface |
Matcher.Visitor<T>
Visits the variants of the Matcher union type.
|
| Modifier and Type | Method and Description |
|---|---|
abstract <U> U |
accept(Matcher.Visitor<U> visitor)
Visits the Matcher union type.
|
boolean |
equals(java.lang.Object o) |
static Matcher<?> |
fromNode(Node node)
Creates a
Matcher from a Node. |
abstract java.lang.String |
getMemberName()
Gets the member name of the matcher.
|
abstract T |
getValue()
Gets the value of the set matcher variant.
|
int |
hashCode() |
public abstract T getValue()
public abstract java.lang.String getMemberName()
public abstract <U> U accept(Matcher.Visitor<U> visitor)
U - The type returned by the visitor.visitor - Visitor to apply.public final int hashCode()
hashCode in class java.lang.Objectpublic final boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic static Matcher<?> fromNode(Node node)
Matcher from a Node.node - Node to create a Matcher from.Matcher.ExpectationNotMetException - if the given node is invalid.