trait Json[T <: Json[T]] extends JsValue

Linear Supertypes
JsValue, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Json
  2. JsValue
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def asJsArray: JsArray

    returns this value as a JsArray if it's an array, throwing an UserError otherwise.

    returns this value as a JsArray if it's an array, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isArr

    can help to that purpose.

    isArr }}}

    returns

    this value as a JsArray

    Definition Classes
    JsValue
    Exceptions thrown

    UserError if it's not an array

  2. abstract def asJsObj: JsObj

    returns this value as a JsObj if it's an object, throwing an UserError otherwise.

    returns this value as a JsObj if it's an object, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isObj

    can help to that purpose.

    isObj }}}

    returns

    this value as a JsObj

    Definition Classes
    JsValue
    Exceptions thrown

    UserError if it's not an object

  3. abstract def asJson: Json[_]

    returns this value as a Json if it's an object or an array, throwing an UserError otherwise.

    returns this value as a Json if it's an object or an array, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isJson

    can help to that purpose.

    isJson }}}

    returns

    this value as a Json

    Definition Classes
    JsValue
    Exceptions thrown

    UserError if it's not an array or an object

  4. abstract def empty: T
  5. abstract def filter(p: (JsPath, JsValue) => Boolean): T
  6. abstract def filterJsObj(p: (JsPath, JsObj) => Boolean): T
  7. abstract def filterJsObjRec(p: (JsPath, JsObj) => Boolean): T
  8. abstract def filterKey(p: (JsPath, JsValue) => Boolean): T
  9. abstract def filterKeyRec(p: (JsPath, JsValue) => Boolean): T
  10. abstract def filterRec(p: (JsPath, JsValue) => Boolean): T
  11. abstract def id: Int

    Every implementation of this trait has an unique identifier.

    Every implementation of this trait has an unique identifier.

    returns

    unique identifier of the type

    Definition Classes
    JsValue
  12. abstract def init: T
  13. abstract def inserted(path: JsPath, value: JsValue, padWith: JsValue = JsNull): T
  14. abstract def isArr: Boolean

    returns true if this is an array

    returns true if this is an array

    Definition Classes
    JsValue
  15. abstract def isEmpty: Boolean
  16. abstract def isObj: Boolean

    returns true if this is an object

    returns true if this is an object

    Definition Classes
    JsValue
  17. abstract def map[J <: JsValue](m: (JsPath, JsValue) => J, p: (JsPath, JsValue) => Boolean): T
  18. abstract def mapKey(m: (JsPath, JsValue) => String, p: (JsPath, JsValue) => Boolean): T
  19. abstract def mapKeyRec(m: (JsPath, JsValue) => String, p: (JsPath, JsValue) => Boolean): T
  20. abstract def mapRec[J <: JsValue](m: (JsPath, JsValue) => J, p: (JsPath, JsValue) => Boolean): T
  21. abstract def reduce[V](p: (JsPath, JsValue) => Boolean, m: (JsPath, JsValue) => V, r: (V, V) => V): Option[V]
  22. abstract def reduceRec[V](p: (JsPath, JsValue) => Boolean, m: (JsPath, JsValue) => V, r: (V, V) => V): Option[V]
  23. abstract def removed(path: JsPath): T
  24. abstract def removedAll(xs: IterableOnce[JsPath]): T
  25. abstract def size: Int
  26. abstract def tail: T
  27. abstract def toLazyList: LazyList[(JsPath, JsValue)]
  28. abstract def toLazyListRec: LazyList[(JsPath, JsValue)]
  29. abstract def updated(path: JsPath, value: JsValue): T

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def +(path: JsPath, value: JsValue): T
    Annotations
    @inline()
  4. final def +!(path: JsPath, value: JsValue, padWith: JsValue = JsNull): T
    Annotations
    @inline()
  5. final def -(path: JsPath): T
    Annotations
    @inline()
  6. final def --(xs: IterableOnce[JsPath]): T
    Annotations
    @inline()
  7. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. final def apply(path: JsPath): JsValue
  9. def array(path: JsPath): Option[JsArray]
  10. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  11. def asJsBigDec: JsBigDec

    returns this value as a JsBigDec if it's a decimal number, throwing an UserError otherwise.

    returns this value as a JsBigDec if it's a decimal number, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isDecimal

    can help to that purpose.

    isDecimal }}}

    returns

    this value as a JsBigDec

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if the conversion can't be done

  12. def asJsBigInt: JsBigInt

    returns this value as a JsBigInt if it's an integral number, throwing an UserError otherwise.

    returns this value as a JsBigInt if it's an integral number, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isIntegral

    can help to that purpose.

    isIntegral }}}

    returns

    this value as a JsBigInt

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if the conversion can't be done

  13. def asJsBool: JsBool

    returns this value as a JsBool if it's a boolean, throwing an UserError otherwise.

    returns this value as a JsBool if it's a boolean, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isBool

    can help to that purpose.

    isBool }}}

    returns

    this value as a JsBool

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if it's not a boolean

  14. def asJsDouble: JsDouble

    returns this value as a JsDouble if it is a JsLong or a JsInt or a JsDouble , throwing an UserError otherwise.

    returns this value as a JsDouble if it is a JsLong or a JsInt or a JsDouble , throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isInt || isLong || isDouble

    can help to that purpose.

    isInt || isLong || isDouble }}}

    returns

    this value as a JsDouble

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if the conversion can't be done

  15. def asJsInt: JsInt

    returns this value as a JsInt , throwing an UserError otherwise.

    returns this value as a JsInt , throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isInt

    can help to that purpose.

    isInt }}}

    returns

    this value as a JsInt

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if the conversion can't be done

  16. def asJsLong: JsLong

    returns this value as a JsLong if it is a JsLong or a JsInt , throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    returns this value as a JsLong if it is a JsLong or a JsInt , throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isInt || isLong

    can help to that purpose.

    isInt || isLong }}}

    returns

    this value as a JsLong

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if the conversion can't be done

  17. def asJsNull: JsNull.type

    returns this value as a JsNull if it's null, throwing an UserError otherwise.

    returns this value as a JsNull if it's null, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isNull

    can help to that purpose.

    isNull }}}

    returns

    this value as a JsNull

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if it's not a boolean

  18. def asJsNumber: JsNumber

    returns this value as a JsNumber if it's a number, throwing an UserError otherwise.

    returns this value as a JsNumber if it's a number, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isNumber

    can help to that purpose.

    isNumber }}}

    returns

    this value as a JsNumber

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if it's not a number

  19. def asJsStr: JsStr

    returns this value as a JsStr if it's a string, throwing an UserError otherwise.

    returns this value as a JsStr if it's a string, throwing an UserError otherwise. It's the responsibility of the caller to make sure the call to this function doesn't fail. The guard condition

    isStr

    can help to that purpose.

    isStr }}}

    returns

    this value as a JsStr

    Definition Classes
    JsonJsValue
    Exceptions thrown

    UserError if it's not a string

  20. def bigDecimal(path: JsPath): Option[BigDecimal]
  21. def bigInt(path: JsPath): Option[BigInt]
  22. def bool(path: JsPath): Option[Boolean]
  23. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  24. def containsPath(path: JsPath): Boolean
  25. def count(p: ((JsPath, JsValue)) => Boolean = (_: (JsPath, JsValue)) => true): Int
  26. def countRec(p: ((JsPath, JsValue)) => Boolean = (_: (JsPath, JsValue)) => true): Int
  27. def double(path: JsPath): Option[Double]
  28. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  29. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  30. def exists(p: ((JsPath, JsValue)) => Boolean): Boolean
  31. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  32. def get(path: JsPath): Option[JsValue]
  33. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  34. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  35. def int(path: JsPath): Option[Int]
  36. def isArr(predicate: (JsArray) => Boolean): Boolean

    returns true if this is an array that satisfies a predicate

    returns true if this is an array that satisfies a predicate

    predicate

    the predicate

    Definition Classes
    JsValue
  37. def isBigDec: Boolean

    returns true if this is a big decimal.

    returns true if this is a big decimal.

    returns

    true if this is a big decimal and false otherwise. If this is a double, it returns false.

    Definition Classes
    JsonJsValue
  38. def isBigDec(predicate: (BigDecimal) => Boolean): Boolean

    returns true if this is a big decimal that satisfies a predicate

    returns true if this is a big decimal that satisfies a predicate

    predicate

    the predicate

    returns

    true if this is a big decimal that satisfies the predicate. If this is a double, it returns false

    Definition Classes
    JsValue
  39. def isBigInt: Boolean

    returns true if this is a big integer.

    returns true if this is a big integer.

    returns

    true if this is a big integer and false otherwise. If this is either an integer or a long, it returns false.

    Definition Classes
    JsonJsValue
  40. def isBigInt(predicate: (BigInt) => Boolean): Boolean

    returns true if this is a big integer that satisfies a predicate

    returns true if this is a big integer that satisfies a predicate

    predicate

    the predicate

    returns

    true if this is a big integer that satisfies the predicate. If this is either an integer or a long, it returns false.

    Definition Classes
    JsValue
  41. def isBool: Boolean

    returns true if this is a boolean

    returns true if this is a boolean

    Definition Classes
    JsonJsValue
  42. def isDecimal: Boolean

    returns true if this type is a decimal number

    returns true if this type is a decimal number

    returns

    isDouble || isBigDec
    Definition Classes
    JsValue
  43. def isDouble: Boolean

    returns true if this is a double

    returns true if this is a double

    Definition Classes
    JsonJsValue
  44. def isDouble(predicate: (Double) => Boolean): Boolean

    returns true if this is a double that satisfies a predicate

    returns true if this is a double that satisfies a predicate

    predicate

    the predicate

    returns

    true if this is a double that satisfies the predicate

    Definition Classes
    JsValue
  45. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  46. def isInt: Boolean

    returns true if this is a integer (32 bit precision number)

    returns true if this is a integer (32 bit precision number)

    Definition Classes
    JsonJsValue
  47. def isInt(predicate: (Int) => Boolean): Boolean

    returns true if this is an integer that satisfies a predicate

    returns true if this is an integer that satisfies a predicate

    predicate

    the predicate

    Definition Classes
    JsValue
  48. def isIntegral: Boolean

    returns true if this type is an integral number

    returns true if this type is an integral number

    returns

    isInt || isLong || isBigInt
    Definition Classes
    JsValue
  49. def isJson(predicate: (Json[_]) => Boolean): Boolean

    returns true if this is a json that satisfy a predicate

    returns true if this is a json that satisfy a predicate

    predicate

    the predicate

    Definition Classes
    JsValue
  50. def isJson: Boolean

    returns true is this type is an array or an object

    returns true is this type is an array or an object

    Definition Classes
    JsValue
  51. def isLong: Boolean

    returns true if this is a long (62 bit precision number)

    returns true if this is a long (62 bit precision number)

    returns

    true if this is a long and false otherwise. If this is an integer, it returns false.

    Definition Classes
    JsonJsValue
  52. def isLong(predicate: (Long) => Boolean): Boolean

    returns true if this is a long that satisfies a predicate

    returns true if this is a long that satisfies a predicate

    predicate

    the predicate

    returns

    true if this is a long that satisfies the predicate and false otherwise. If this is an integer, it returns false.

    Definition Classes
    JsValue
  53. def isNotEmpty: Boolean
  54. def isNotJson: Boolean

    returns true if this is neither an object nor an array

    returns true if this is neither an object nor an array

    Definition Classes
    JsValue
  55. def isNotNumber: Boolean

    returns true if this is not a number

    returns true if this is not a number

    Definition Classes
    JsValue
  56. def isNothing: Boolean

    returns true if this is JsNothing

    returns true if this is JsNothing

    returns

    true if this is JsNothing, false otherwise

    Definition Classes
    JsonJsValue
  57. def isNull: Boolean

    returns true if this is JsNull

    returns true if this is JsNull

    returns

    true if this is JsNull, false otherwise

    Definition Classes
    JsonJsValue
  58. def isNumber: Boolean

    returns true if this is a number

    returns true if this is a number

    Definition Classes
    JsonJsValue
  59. def isObj(predicate: (JsObj) => Boolean): Boolean

    returns true if this is an object that satisfies a predicate

    returns true if this is an object that satisfies a predicate

    predicate

    the predicate

    Definition Classes
    JsValue
  60. def isStr: Boolean

    returns true if this is a string

    returns true if this is a string

    Definition Classes
    JsonJsValue
  61. def isStr(predicate: (String) => Boolean): Boolean

    returns true if this is a string that satisfies a predicate

    returns true if this is a string that satisfies a predicate

    predicate

    the predicate

    Definition Classes
    JsValue
  62. def long(path: JsPath): Option[Long]
  63. def mapIfNotNothing[T](default: () => T, map: (JsValue) => T): T

    if this is JsNothing, it returns a value computed by the default supplier.

    if this is JsNothing, it returns a value computed by the default supplier. Otherwise, it returns the result of applying the map function to this.

    T

    the type of the returned value

    default

    the supplier to compute the default value

    map

    the map function

    returns

    a value of type T

    Definition Classes
    JsValue
  64. def mapIfNotNull[T](default: () => T, map: (JsValue) => T): T

    if this is JsNull, it returns a value computed by the default supplier.

    if this is JsNull, it returns a value computed by the default supplier. Otherwise, it returns the result of applying the map function to this.

    T

    the type of the returned value

    default

    the supplier to compute the default value

    map

    the map function

    returns

    a value of type T

    Definition Classes
    JsValue
  65. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  66. final def nonEmpty: Boolean
  67. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  68. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  69. def obj(path: JsPath): Option[JsObj]
  70. def serialize: Array[Byte]
  71. def serialize(outputStream: OutputStream): () => Unit
  72. def string(path: JsPath): Option[String]
  73. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  74. def toPrettyString: String
  75. def toString(): String
    Definition Classes
    Json → AnyRef → Any
  76. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  77. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  78. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from JsValue

Inherited from AnyRef

Inherited from Any

Ungrouped