Present

zio.prelude.data.Optional.Present
final case class Present[+A](get: A) extends Optional[A]

Optional value that is present

Type parameters

A

type of the value

Value parameters

get

the value

Attributes

Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait Optional[A]
class Object
trait Matchable
class Any
Show all

Members list

Type members

Inherited classlikes

class WithFilter(p: A => Boolean)

Attributes

Inherited from:
Optional
Supertypes
class Object
trait Matchable
class Any

Value members

Inherited methods

final def collect[B](pf: PartialFunction[A, B]): Optional[B]

Attributes

Inherited from:
Optional
final def contains[A1 >: A](elem: A1): Boolean

Attributes

Inherited from:
Optional
final def exists(p: A => Boolean): Boolean

Attributes

Inherited from:
Optional
final def filter(p: A => Boolean): Optional[A]

Attributes

Inherited from:
Optional
final def filterNot(p: A => Boolean): Optional[A]

Attributes

Inherited from:
Optional
final def flatMap[B](f: A => Optional[B]): Optional[B]

Attributes

Inherited from:
Optional
final def flatten[B](implicit ev: A <:< Option[B]): Option[B]

Attributes

Inherited from:
Optional
final def fold[B](ifEmpty: => B)(f: A => B): B

Attributes

Inherited from:
Optional
final def forall(p: A => Boolean): Boolean

Attributes

Inherited from:
Optional
final def foreach[U](f: A => U): Unit

Attributes

Inherited from:
Optional
final def getOrElse[A0 >: A](default: => A0): A0

Attributes

Inherited from:
Optional
final def iterator: Iterator[A]

Attributes

Inherited from:
Optional
final def map[B](f: A => B): Optional[B]

Attributes

Inherited from:
Optional
final def orElse[B >: A](other: Optional[B]): Optional[B]

Attributes

Inherited from:
Optional

Attributes

Inherited from:
Product

Attributes

Inherited from:
Product
final def toChunk: Chunk[A]

Attributes

Inherited from:
Optional
final def toLeft[R](right: R): Either[A, R]

Attributes

Inherited from:
Optional
final def toList: List[A]

Attributes

Inherited from:
Optional
final def toOption: Option[A]

Converts this optional value to standard scala.Option

Converts this optional value to standard scala.Option

Attributes

Inherited from:
Optional
final def toRight[L](left: L): Either[L, A]

Attributes

Inherited from:
Optional
final def toVector: Vector[A]

Attributes

Inherited from:
Optional
final def withFilter(p: A => Boolean): WithFilter

Attributes

Inherited from:
Optional

Concrete fields

override val isDefined: Boolean
override val isEmpty: Boolean
override val nonEmpty: Boolean