Monaden & Co. Funktionale Konzepte in Scala - Lars Hupel
Monaden & Co. Funktionale Konzepte in Scala - Lars Hupel
Monaden & Co. Funktionale Konzepte in Scala - Lars Hupel
Sie wollen auch ein ePaper? Erhöhen Sie die Reichweite Ihrer Titel.
YUMPU macht aus Druck-PDFs automatisch weboptimierte ePaper, die Google liebt.
<strong>Scala</strong>z – Functorstrait Functor[F[_]] {def fmap[A, B](f: A => B, r: F[A]): F[B]}implicit val optionFunctor =new Functor[Option] {def fmap[A, B](f: A => B, r: Option[A]) =r map f}<strong>Monaden</strong> & <strong>Co</strong>. – <strong>Lars</strong> <strong>Hupel</strong> <strong>Co</strong>pyright © 2011 MATHEMA Software GmbH 24