Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Treatment map

std/ops/option/block::map


Generics

◻ T (any)

Inputs

⇥ option: Block<Option<T>>

Outputs

↦ none: Block<void>
↦ value: Block<T>


Map an option

Takes a blocking option and either emit the contained value on value or none if empty.

ℹ️ This treatment aims to be used in conjuction with reduce.