com.twitter.util

Bijection

trait Bijection[A, B] extends (A) ⇒ B

A bijection is a function for which every value in its codomain (set of all possible results) is equivalent to application of the function on a unique value in its domain (all possible inputs). This trait in particular provides an interface for functions that can be 'unapplied' as well as applied. A codec that can convert to and from a set of objects and their serialized form is an example of a bijection.

Self Type
Bijection[A, B]
Annotations
@deprecated
Deprecated

(Since version 2014-06-05) Prefer using com.twitter.bijection.Bijection

Linear Supertypes
(A) ⇒ B, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Bijection
  2. Function1
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def apply(a: A): B

    Definition Classes
    Bijection → Function1
  2. abstract def invert(b: B): A

Concrete Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  4. def andThen[C](g: Bijection[B, C]): Bijection[A, C]

    Composes two instances of Bijection in a new Bijection, with this one applied first.

  5. def andThen[A](g: (B) ⇒ A): (A) ⇒ A

    Definition Classes
    Function1
    Annotations
    @unspecialized()
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def compose[T](g: Bijection[T, A]): Bijection[T, B]

    Composes two instances of Bijection in a new Bijection, with this one applied last.

  9. def compose[A](g: (A) ⇒ A): (A) ⇒ B

    Definition Classes
    Function1
    Annotations
    @unspecialized()
  10. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  11. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  12. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  15. def inverse: Bijection[B, A]

    Return a Bijection that is the inverse of this one.

  16. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  17. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  18. final def notify(): Unit

    Definition Classes
    AnyRef
  19. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  20. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  21. def toString(): String

    Definition Classes
    Function1 → AnyRef → Any
  22. def unapply(b: B): Option[A]

  23. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from (A) ⇒ B

Inherited from AnyRef

Inherited from Any

Ungrouped