Modifier and Type | Method and Description |
---|---|
B |
bad()
Returns the bad value if this is a Bad, or throws an exception if this is a Good.
|
boolean |
equals(Object other) |
G |
good()
Returns the good value if this is a Good, or throws an exception if this is a Bad.
|
int |
hashCode() |
boolean |
isBad()
Returns true if this Or has a bad value.
|
boolean |
isGood()
Returns true if this Or has a good value.
|
<R> R |
match(Fn1<G,R> fg,
Fn1<B,R> fb)
Exactly one of these functions will be executed - determined by whether this is a Good or a Bad.
|
String |
toString() |
public boolean isGood()
public boolean isBad()
public G good()
public B bad()
public <R> R match(Fn1<G,R> fg, Fn1<B,R> fb)
Copyright © 2017. All rights reserved.