x/monads/docs/interfaces/resright.md
@hqoss/monads › Globals › ResRight
Interface: ResRight ‹L, R›
Type parameters
▪ L
▪ R
Hierarchy
Either‹L, R›
↳ ResRight
Index
Properties
Methods
- isLeft
- isRight
- left
- leftAndThen
- map
- mapLeft
- mapRight
- match
- right
- rightAndThen
- unwrap
- unwrapLeft
- unwrapLeftOr
- unwrapLeftOrElse
- unwrapRight
- unwrapRightOr
- unwrapRightOrElse
Properties
type
• type: symbol
Defined in lib/either/either.ts:14
Methods
isLeft
▸ isLeft(): boolean
Defined in lib/either/either.ts:15
Returns: boolean
isRight
▸ isRight(): boolean
Defined in lib/either/either.ts:16
Returns: boolean
left
▸ left(): Option‹L›
Defined in lib/either/either.ts:17
Returns: Option‹L›
leftAndThen
▸ leftAndThen‹U›(fn
: function): Either‹U, R›
Inherited from Either.leftAndThen
Defined in lib/either/either.ts:18
Type parameters:
▪ U
Parameters:
▪ fn: function
▸ (val
: L): Either‹U, R›
Parameters:
Name | Type |
---|---|
val |
L |
Returns: Either‹U, R›
map
▸ map‹U›(fn
: function): ResRight‹never, U›
Defined in lib/either/either.ts:49
Type parameters:
▪ U
Parameters:
▪ fn: function
▸ (val
: L | R): U
Parameters:
Name | Type |
---|---|
val |
L | R |
Returns: ResRight‹never, U›
mapLeft
▸ mapLeft‹U›(fn
: function): Either‹never, R›
Defined in lib/either/either.ts:50
Type parameters:
▪ U
Parameters:
▪ fn: function
▸ (left
: L): U
Parameters:
Name | Type |
---|---|
left |
L |
Returns: Either‹never, R›
mapRight
▸ mapRight‹U›(fn
: function): ResRight‹never, U›
Defined in lib/either/either.ts:51
Type parameters:
▪ U
Parameters:
▪ fn: function
▸ (right
: R): U
Parameters:
Name | Type |
---|---|
right |
R |
Returns: ResRight‹never, U›
match
▸ match‹U›(fn
: Match‹never, R, U›): U
Defined in lib/either/either.ts:48
Type parameters:
▪ U
Parameters:
Name | Type |
---|---|
fn |
Match‹never, R, U› |
Returns: U
right
▸ right(): Option‹R›
Defined in lib/either/either.ts:19
Returns: Option‹R›
rightAndThen
▸ rightAndThen‹U›(fn
: function): Either‹L, U›
Inherited from Either.rightAndThen
Defined in lib/either/either.ts:20
Type parameters:
▪ U
Parameters:
▪ fn: function
▸ (val
: R): Either‹L, U›
Parameters:
Name | Type |
---|---|
val |
R |
Returns: Either‹L, U›
unwrap
▸ unwrap(): R
Defined in lib/either/either.ts:45
Returns: R
unwrapLeft
▸ unwrapLeft(): never
Overrides Either.unwrapLeft
Defined in lib/either/either.ts:46
Returns: never
unwrapLeftOr
▸ unwrapLeftOr(other
: L): L
Inherited from Either.unwrapLeftOr
Defined in lib/either/either.ts:23
Parameters:
Name | Type |
---|---|
other |
L |
Returns: L
unwrapLeftOrElse
▸ unwrapLeftOrElse(fn
: function): L
Inherited from Either.unwrapLeftOrElse
Defined in lib/either/either.ts:24
Parameters:
▪ fn: function
▸ (right
: R): L
Parameters:
Name | Type |
---|---|
right |
R |
Returns: L
unwrapRight
▸ unwrapRight(): R
Overrides Either.unwrapRight
Defined in lib/either/either.ts:47
Returns: R
unwrapRightOr
▸ unwrapRightOr(other
: R): R
Inherited from Either.unwrapRightOr
Defined in lib/either/either.ts:26
Parameters:
Name | Type |
---|---|
other |
R |
Returns: R
unwrapRightOrElse
▸ unwrapRightOrElse(fn
: function): R
Inherited from Either.unwrapRightOrElse
Defined in lib/either/either.ts:27
Parameters:
▪ fn: function
▸ (left
: L): R
Parameters:
Name | Type |
---|---|
left |
L |
Returns: R