Package

json

Permalink

package json

Overview

This is the package namespace for everything scala-json ( https://github.com/MediaMath/scala-json/ ). It is recommended to import json._ in your file when working with scala json. The base type for all JSON values is the json.JValue.

JValue Types

Linear Supertypes
Implicits, JSONAnnotations, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. json
  2. Implicits
  3. JSONAnnotations
  4. AnyRef
  5. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Type Members

  1. implicit class AnyValJSEx[T] extends AnyRef

    Permalink

    This is the class extension that allows you to use the .js method on any value

    This is the class extension that allows you to use the .js method on any value

    Definition Classes
    Implicits
  2. abstract class FieldAccessor[T, U] extends Product2[Class[T], String]

    Permalink

    Base accessor class for field accessors in objects (seen via case class macro generally).

    Base accessor class for field accessors in objects (seen via case class macro generally).

    The contains extended run-time info such as field name, field defaults, type access etc.

    T

    type of class that owns the fields

    U

    type of the field

  3. type FieldAccessorAnnotation = json.internal.FieldAccessorAnnotation

    Permalink

    Base type of all annotations, useful when reflecting annos in json.FieldAccessor

    Base type of all annotations, useful when reflecting annos in json.FieldAccessor

    Definition Classes
    JSONAnnotations
  4. trait Implicits extends AnyRef

    Permalink
  5. abstract class JArray extends JValue with JArrayLike with JArrayBase

    Permalink

    JSON array as ordered sequence of JValues

  6. sealed abstract class JBoolean extends JValue with JBooleanBase

    Permalink

    Base type for JSON primitives JTrue and JFalse

  7. case class JDynamic(value: JValue) extends Dynamic with Product with Serializable

    Permalink
  8. sealed abstract class JNumber extends JValue with JNumberBase

    Permalink

    JSON numeric value (stored as 64-bit double)

  9. final case class JObject extends JValue with Iterable[Pair] with IterableLike[Pair, JObject] with JObjectLike with JObjectBase with Product with Serializable

    Permalink

    JSON object as ordered pairs of String -> JValue

  10. type JSONAccessor[T] = JSONAccessorProducer[T, JValue]

    Permalink

    JSONAccessor is shorthand for a JSONAccessorProducer of generic JValue type

    JSONAccessor is shorthand for a JSONAccessorProducer of generic JValue type

    Annotations
    @implicitNotFound( ... )
  11. trait JSONAccessorProducer[T, +JV <: JValue] extends CreateJSON[T, JV]

    Permalink
    Annotations
    @implicitNotFound( ... )
  12. case class JSONBuilderSettings(spaceString: String, newLineString: String, tabString: String) extends Product with Serializable

    Permalink
  13. type JSONException = json.exceptions.JSONException

    Permalink

    Base type for all JSON exceptions.

    Base type for all JSON exceptions. All exceptions are based off of case classes.

  14. implicit class JSONStringOps extends AnyRef

    Permalink
    Definition Classes
    Implicits
  15. final case class JString(value: String) extends JValue with Iterable[JString] with JStringLike with JStringBase with Product with Serializable

    Permalink

    JSON String value

  16. sealed abstract class JValue extends JValueLike with JValueBase

    Permalink

    This is the base type for all JSON values.

    This is the base type for all JSON values. JValue includes JS-like methods for handling data in generic JS type. Like JS, some of these methods are convenient but definitely not type safe, and some may result in odd type conversion or exceptions. For type-safe handling of JValues, consider using pattern matching the good ol' scala way.

  17. trait ObjectAccessor[T] extends JSONAccessorProducer[T, JObject]

    Permalink

    ObjectAccessor is a JSONAccessor for objects that have named fields.

    ObjectAccessor is a JSONAccessor for objects that have named fields. Generally these are mostly seen as auto-generated json.internal.CaseClassObjectAccessor case class accessors. Extend this if you need to make a custom accessor that has named fields.

    T

    The base type this accessor is for.

  18. macro class accessor extends Annotation with StaticAnnotation

    Permalink

    Automatically provides an implicit ObjectAccessor to a class companion object.

    Automatically provides an implicit ObjectAccessor to a class companion object. Requires the macro paradise compiler plugin.

    Annotations
    @compileTimeOnly( ... ) @compileTimeOnly( ... )
  19. type description = FieldDescriptionGeneric

    Permalink

    Provide field description, useful when reflect on accessors for auto-gen docs, etc

    Provide field description, useful when reflect on accessors for auto-gen docs, etc

    Definition Classes
    JSONAnnotations
  20. type ephemeral = EphemeralGeneric

    Permalink

    Marks an internal method/val to be emitted when serialized only, but not needed for construction (basically read only).

    Marks an internal method/val to be emitted when serialized only, but not needed for construction (basically read only).

    @json.accessor case class Foo(bar: String) {
      @json.ephemeral def twice = bar + bar
    }
    Definition Classes
    JSONAnnotations
  21. type name = FieldNameGeneric

    Permalink

    Provide field name that will be used in the JSON.

    Provide field name that will be used in the JSON. Useful when making case classes for existing JSON models that aren't camel cased.

    Definition Classes
    JSONAnnotations

Value Members

  1. object Implicits extends Implicits

    Permalink
  2. object JArray extends JArrayCompanion

    Permalink
  3. object JBoolean

    Permalink
  4. object JFalse extends JBoolean with Product with Serializable

    Permalink
  5. lazy val JNaN: JNumber

    Permalink

    Special NaN JNumber value

  6. object JNull extends JValue with JNullBase with Product with Serializable

    Permalink

    JSON null primitive

  7. object JNumber

    Permalink
  8. object JObject extends JObjectCompanion with Serializable

    Permalink
  9. val JSONAccessor: JSONAccessorProducer.type

    Permalink

    see JSONAccessorProducer

  10. object JSONAccessorProducer

    Permalink
  11. object JSONBuilderSettings extends Serializable

    Permalink
  12. object JTrue extends JBoolean with Product with Serializable

    Permalink
  13. object JUndefined extends JValue with JUndefinedBase with Product with Serializable

    Permalink

    JS undefined primitive (not actually a JSON primitive)

  14. object JValue extends JValueLikeCompanion

    Permalink
  15. object ObjectAccessor

    Permalink
  16. def accessorFor[T](x: T)(implicit acc: JSONAccessor[T]): JSONAccessor[T]

    Permalink
  17. def accessorOf[T](implicit acc: JSONAccessor[T]): JSONAccessor[T]

    Permalink
  18. object accessors extends Accessors

    Permalink
  19. object annotations extends JSONAnnotations

    Permalink

    Package space for all scala-json annotations

  20. def createAccessor[T](toJ: (T) ⇒ JValue, fromJ: (JValue) ⇒ T)(implicit arg0: ClassTag[T]): JSONAccessor[T]

    Permalink

    Create a simple JValue JSONAccessor out of 'to' and 'from' functions.

  21. package exceptions

    Permalink
  22. def fromJSON[T](jval: JValue)(implicit acc: JSONAccessor[T]): T

    Permalink
  23. def toJSONString[T](obj: T)(implicit arg0: JSONAccessor[T]): String

    Permalink
  24. package tools

    Permalink

Inherited from Implicits

Inherited from JSONAnnotations

Inherited from AnyRef

Inherited from Any

Ungrouped