play.api.libs.json

JsObject

case class JsObject(fields: Seq[(String, JsValue)]) extends JsValue with Product with Serializable

Represent a Json object value.

Source
JsValue.scala
Linear Supertypes
Serializable, Serializable, Product, Equals, JsValue, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. JsObject
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. JsValue
  7. AnyRef
  8. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new JsObject(fields: Seq[(String, JsValue)])

Value Members

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

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. def +(otherField: (String, JsValue)): JsObject

    adds one field from JsObject

  5. def ++(other: JsObject): JsObject

    Merge this object with an other one.

    Merge this object with an other one. Values from other override value of the current object.

  6. def -(otherField: String): JsObject

    removes one field from JsObject

  7. final def ==(arg0: AnyRef): Boolean

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

    Definition Classes
    Any
  9. def \(fieldName: String): JsValue

    Return the property corresponding to the fieldName, supposing we have a JsObject.

    Return the property corresponding to the fieldName, supposing we have a JsObject.

    fieldName

    the name of the property to lookup

    returns

    the resulting JsValue. If the current node is not a JsObject or doesn't have the property, a JsUndefined will be returned.

    Definition Classes
    JsObjectJsValue
  10. def \\(fieldName: String): Seq[JsValue]

    Lookup for fieldName in the current object and all descendants.

    Lookup for fieldName in the current object and all descendants.

    returns

    the list of matching nodes

    Definition Classes
    JsObjectJsValue
  11. def apply(idx: Int): JsValue

    Return the element at a given index, supposing we have a JsArray.

    Return the element at a given index, supposing we have a JsArray.

    idx

    the index to lookup

    Definition Classes
    JsValue
  12. def as[T](implicit fjs: Reads[T]): T

    Tries to convert the node into a T, throwing an exception if it can't.

    Tries to convert the node into a T, throwing an exception if it can't. An implicit Reads[T] must be defined.

    Definition Classes
    JsValue
  13. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  14. def asOpt[T](implicit fjs: Reads[T]): Option[T]

    Tries to convert the node into a T.

    Tries to convert the node into a T. An implicit Reads[T] must be defined. Any error is mapped to None

    returns

    Some[T] if it succeeds, None if it fails.

    Definition Classes
    JsValue
  15. def canEqual(other: Any): Boolean

    Definition Classes
    JsObject → Equals
  16. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  17. def deepMerge(other: JsObject): JsObject

    merges everything in depth and doesn't stop at first level as ++ TODO : improve because coding is nasty there

  18. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  19. def equals(other: Any): Boolean

    Definition Classes
    JsObject → Equals → AnyRef → Any
  20. def fieldSet: Set[(String, JsValue)]

  21. val fields: Seq[(String, JsValue)]

  22. def finalize(): Unit

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

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

    Definition Classes
    JsObject → AnyRef → Any
  25. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  26. def keys: Set[String]

    Return all keys

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

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

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

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

    Definition Classes
    AnyRef
  31. def toString(): String

    Definition Classes
    JsValue → AnyRef → Any
  32. def transform[A <: JsValue](rds: Reads[A]): JsResult[A]

    Transforms a JsValue into another JsValue using provided Json transformer Reads[JsValue]

    Transforms a JsValue into another JsValue using provided Json transformer Reads[JsValue]

    Definition Classes
    JsValue
  33. def validate[T](implicit rds: Reads[T]): JsResult[T]

    Tries to convert the node into a JsResult[T] (Success or Error).

    Tries to convert the node into a JsResult[T] (Success or Error). An implicit Reads[T] must be defined.

    Definition Classes
    JsValue
  34. lazy val value: Map[String, JsValue]

  35. def values: Set[JsValue]

    Return all values

  36. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from JsValue

Inherited from AnyRef

Inherited from Any

Ungrouped