Package io.atlassian.fugue
Class Either.Right<L,R>
java.lang.Object
io.atlassian.fugue.Either<L,R>
io.atlassian.fugue.Either.Right<L,R>
- All Implemented Interfaces:
Serializable
-
Nested Class Summary
Nested classes/interfaces inherited from class io.atlassian.fugue.Either
Either.AbstractProjection<A,B>, Either.Left<L, R>, Either.LeftProjection, Either.Projection<A, B, L, R>, Either.Right<L, R>, Either.RightProjection -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<LL,RR> Either <LL, RR> Map the given functions across the appropriate side.boolean<V> VApplies the function to the wrapped value, applying ifLeft if this is a Left and ifRight if this is a Right.(package private) final RgetRight()inthashCode()booleanisLeft()Returnstrueif this either is a left,falseotherwise.booleanisRight()Returnstrueif this either is a right,falseotherwise.swap()If this is a left, then return the left value in right, or vice versa.toString()Methods inherited from class io.atlassian.fugue.Either
ap, apply, contains, exists, filter, filterOrElse, flatMap, forall, foreach, forEach, getLeft, getOr, getOrElse, getOrElse, getOrError, getOrNull, getOrThrow, left, left, leftMap, leftOr, map, orElse, orElse, right, right, rightOr, sequence, toOption, toOptional, toStream, valueOr
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
value
-
-
Constructor Details
-
Right
-
-
Method Details
-
getRight
-
isRight
public boolean isRight()Description copied from class:EitherReturnstrueif this either is a right,falseotherwise. -
isLeft
public boolean isLeft()Description copied from class:EitherReturnstrueif this either is a left,falseotherwise. -
swap
Description copied from class:EitherIf this is a left, then return the left value in right, or vice versa. -
fold
Description copied from class:EitherApplies the function to the wrapped value, applying ifLeft if this is a Left and ifRight if this is a Right. -
bimap
public <LL,RR> Either<LL,RR> bimap(Function<? super L, ? extends LL> ifLeft, Function<? super R, ? extends RR> ifRight) Description copied from class:EitherMap the given functions across the appropriate side. -
equals
-
hashCode
public int hashCode() -
toString
-