de.sciss.synth.Optional.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of scalacollider_2.10.0-RC2 Show documentation
Show all versions of scalacollider_2.10.0-RC2 Show documentation
A sound synthesis library for the SuperCollider server
The newest version!
package de.sciss.synth
object Optional {
implicit def some[ @specialized A ]( a: A ) = Optional( Some( a ))
implicit def wrap[ A ]( a: Option[ A ]) = Optional( a )
implicit def unwrap[ A ]( a: Optional[ A ]) = a.option
}
final case class Optional[ A ]( option: Option[ A ])