Class

play.api.data

ObjectMapping7

Related Doc: package data

Permalink

class ObjectMapping7[R, A1, A2, A3, A4, A5, A6, A7] extends Mapping[R] with ObjectMapping

Source
ObjectMappings.scala
Linear Supertypes
ObjectMapping, Mapping[R], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ObjectMapping7
  2. ObjectMapping
  3. Mapping
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new ObjectMapping7(apply: (A1, A2, A3, A4, A5, A6, A7) ⇒ R, unapply: (R) ⇒ Option[(A1, A2, A3, A4, A5, A6, A7)], f1: (String, Mapping[A1]), f2: (String, Mapping[A2]), f3: (String, Mapping[A3]), f4: (String, Mapping[A4]), f5: (String, Mapping[A5]), f6: (String, Mapping[A6]), f7: (String, Mapping[A7]), key: String = "", constraints: Seq[Constraint[R]] = Nil)

    Permalink

Value Members

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

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

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

    Permalink
    Definition Classes
    AnyRef → Any
  4. def addPrefix(prefix: String): Option[String]

    Permalink
    Attributes
    protected
    Definition Classes
    Mapping
  5. def applyConstraints(t: R): Either[Seq[FormError], R]

    Permalink
    Attributes
    protected
    Definition Classes
    Mapping
  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. def bind(data: Map[String, String]): Either[Seq[FormError], R]

    Permalink

    Binds this field, i.e.

    Binds this field, i.e. construct a concrete value from submitted data.

    data

    the submitted data

    returns

    either a concrete value of type T or a set of errors, if the binding failed

    Definition Classes
    ObjectMapping7Mapping
  8. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  9. def collectErrors(t: R): Seq[FormError]

    Permalink
    Attributes
    protected
    Definition Classes
    Mapping
  10. val constraints: Seq[Constraint[R]]

    Permalink

    The constraints associated with this field.

    The constraints associated with this field.

    Definition Classes
    ObjectMapping7Mapping
  11. final def eq(arg0: AnyRef): Boolean

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

    Permalink
    Definition Classes
    AnyRef → Any
  13. val field1: Mapping[A1]

    Permalink
  14. val field2: Mapping[A2]

    Permalink
  15. val field3: Mapping[A3]

    Permalink
  16. val field4: Mapping[A4]

    Permalink
  17. val field5: Mapping[A5]

    Permalink
  18. val field6: Mapping[A6]

    Permalink
  19. val field7: Mapping[A7]

    Permalink
  20. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  21. val format: Option[(String, Seq[Any])]

    Permalink

    The Format expected for this field, if it exists.

    The Format expected for this field, if it exists.

    Definition Classes
    Mapping
  22. final def getClass(): Class[_]

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

    Permalink
    Definition Classes
    AnyRef → Any
  24. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  25. val key: String

    Permalink

    The field key.

    The field key.

    Definition Classes
    ObjectMapping7Mapping
  26. val mappings: Seq[Mapping[_]]

    Permalink

    Sub-mappings (these can be seen as sub-keys).

    Sub-mappings (these can be seen as sub-keys).

    Definition Classes
    ObjectMapping7Mapping
  27. def merge(results: Either[Seq[FormError], Any]*): Either[Seq[FormError], Seq[Any]]

    Permalink

    Merges the result of multiple bindings.

    Merges the result of multiple bindings.

    Definition Classes
    ObjectMapping
    See also

    bind()

  28. def merge2(a: Either[Seq[FormError], Seq[Any]], b: Either[Seq[FormError], Seq[Any]]): Either[Seq[FormError], Seq[Any]]

    Permalink

    Merges the result of two bindings.

    Merges the result of two bindings.

    Definition Classes
    ObjectMapping
    See also

    bind()

  29. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  30. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  31. final def notifyAll(): Unit

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

    Permalink
    Definition Classes
    AnyRef
  33. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  34. def transform[B](f1: (R) ⇒ B, f2: (B) ⇒ R): Mapping[B]

    Permalink

    Transform this Mapping[T] to a Mapping[B].

    Transform this Mapping[T] to a Mapping[B].

    B

    The type of the new mapping.

    f1

    Transform value of T to a value of B

    f2

    Transform value of B to a value of T

    Definition Classes
    Mapping
  35. def unbind(value: R): Map[String, String]

    Permalink

    Unbinds this field, i.e.

    Unbinds this field, i.e. transforms a concrete value to plain data.

    value

    the value to unbind

    returns

    the plain data

    Definition Classes
    ObjectMapping7Mapping
  36. def unbindAndValidate(value: R): (Map[String, String], Seq[FormError])

    Permalink

    Unbinds this field, i.e.

    Unbinds this field, i.e. transforms a concrete value to plain data, and applies validation.

    value

    the value to unbind

    returns

    the plain data and any errors in the plain data

    Definition Classes
    ObjectMapping7Mapping
  37. def verifying(addConstraints: Constraint[R]*): ObjectMapping7[R, A1, A2, A3, A4, A5, A6, A7]

    Permalink

    Constructs a new Mapping based on this one, by adding new constraints.

    Constructs a new Mapping based on this one, by adding new constraints.

    For example:

    import play.api.data._
    import validation.Constraints._
    
    Form("phonenumber" -> text.verifying(required) )
    returns

    the new mapping

    Definition Classes
    ObjectMapping7Mapping
  38. def verifying(error: ⇒ String, constraint: (R) ⇒ Boolean): Mapping[R]

    Permalink

    Constructs a new Mapping based on this one, by adding a new ad-hoc constraint.

    Constructs a new Mapping based on this one, by adding a new ad-hoc constraint.

    For example:

    import play.api.data._
    import validation.Constraints._
    
    Form("phonenumber" -> text.verifying("Bad phone number", {_.grouped(2).size == 5}))
    error

    The error message used if the constraint fails

    constraint

    a function describing the constraint that returns false on failure

    returns

    the new mapping

    Definition Classes
    Mapping
  39. def verifying(constraint: (R) ⇒ Boolean): Mapping[R]

    Permalink

    Constructs a new Mapping based on this one, by adding a new ad-hoc constraint.

    Constructs a new Mapping based on this one, by adding a new ad-hoc constraint.

    For example:

    import play.api.data._
    import validation.Constraints._
    
    Form("phonenumber" -> text.verifying {_.grouped(2).size == 5})
    constraint

    a function describing the constraint that returns false on failure

    returns

    the new mapping

    Definition Classes
    Mapping
  40. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  43. def withPrefix(prefix: String): ObjectMapping7[R, A1, A2, A3, A4, A5, A6, A7]

    Permalink

    Constructs a new Mapping based on this one, adding a prefix to the key.

    Constructs a new Mapping based on this one, adding a prefix to the key.

    prefix

    the prefix to add to the key

    returns

    the same mapping, with only the key changed

    Definition Classes
    ObjectMapping7Mapping

Inherited from ObjectMapping

Inherited from Mapping[R]

Inherited from AnyRef

Inherited from Any

Ungrouped