final class ExtractableJsonAstNode extends AnyVal
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- ExtractableJsonAstNode
- AnyVal
- Any
- Hide All
- Show All
Visibility
- Public
- All
Instance Constructors
- new ExtractableJsonAstNode(jv: JValue)
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- Any
-
final
def
##(): Int
- Definition Classes
- Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
extract[A](implicit formats: Formats, mf: Manifest[A]): A
Extract a value from a JSON.
Extract a value from a JSON.
Value can be:
- case class
- primitive (String, Boolean, Date, etc.)
- supported collection type (List, Seq, Map[String, _], Set)
- any type which has a configured custom deserializer
Example:
case class Person(name: String) JObject(JField("name", JString("joe")) :: Nil).extract[Person] == Person("joe")
-
def
extractOpt[A](implicit formats: Formats, mf: Manifest[A]): Option[A]
Extract a value from a JSON.
Extract a value from a JSON.
Value can be:
- case class
- primitive (String, Boolean, Date, etc.)
- supported collection type (List, Seq, Map[String, _], Set)
- any type which has a configured custom deserializer
Example:
case class Person(name: String) JObject(JField("name", JString("joe")) :: Nil).extractOpt[Person] == Some(Person("joe"))
-
def
extractOrElse[A](default: ⇒ A)(implicit formats: Formats, mf: Manifest[A]): A
Extract a value from a JSON using a default value.
Extract a value from a JSON using a default value.
Value can be:
- case class
- primitive (String, Boolean, Date, etc.)
- supported collection type (List, Seq, Map[String, _], Set)
- any type which has a configured custom deserializer
Example:
case class Person(name: String) JNothing.extractOrElse(Person("joe")) == Person("joe")
-
def
getClass(): Class[_ <: AnyVal]
- Definition Classes
- AnyVal → Any
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
toString(): String
- Definition Classes
- Any