class GoodType[G] extends AnyRef
Supports the syntax that enables Bad
instances to be created with a specific
Good
type.
- Source
- Or.scala
- Alphabetic
- By Inheritance
- GoodType
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new GoodType()
Value Members
- def orBad[B](b: B): Or[G, B]
Factory method for
Bad
instances whoseGood
type is specified by the type parameter of thisGoodType
.Factory method for
Bad
instances whoseGood
type is specified by the type parameter of thisGoodType
.This method enables this syntax:
Good[Int].orBad("oops") ^
- b
the “bad” value
- returns
a new
Bad
instance containing the passedb
value
- def toString(): String
- Definition Classes
- GoodType → AnyRef → Any