class Parsing[A] extends PathBindable[A]

A helper class for creating PathBindables to map the value of a path pattern/segment

A

the type being parsed

Source
Binders.scala
Linear Supertypes
PathBindable[A], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Parsing
  2. PathBindable
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new Parsing(parse: (String) => A, serialize: (A) => String, error: (String, Exception) => String)

    parse

    a function to parse the path value

    serialize

    a function to serialize the path value to a string

    error

    a function for rendering an error message if an error occurs

Value Members

  1. def bind(key: String, value: String): Either[String, A]

    Bind an URL path parameter.

    Bind an URL path parameter.

    key

    Parameter key

    value

    The value as String (extracted from the URL path)

    returns

    Right of the value or Left of an error message if the binding failed

    Definition Classes
    PathBindable
  2. def javascriptUnbind: String

    Javascript function to unbind in the Javascript router.

    Javascript function to unbind in the Javascript router.

    Definition Classes
    PathBindable
  3. def transform[B](toB: (A) => B, toA: (B) => A): PathBindable[B]

    Transform this PathBinding[A] to PathBinding[B]

    Transform this PathBinding[A] to PathBinding[B]

    Definition Classes
    PathBindable
  4. def unbind(key: String, value: A): String

    Unbind a URL path parameter.

    Unbind a URL path parameter.

    key

    Parameter key

    value

    Parameter value.

    Definition Classes
    PathBindable