JawnParser

io.circe.jawn.JawnParser
See theJawnParser companion class
object JawnParser

Attributes

Companion
class
Source
JawnParser.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
JawnParser.type

Members list

Value members

Concrete methods

def apply(maxValueSize: Int, allowDuplicateKeys: Boolean): JawnParser

Returns a parser that fails on:

Returns a parser that fails on:

- JSON strings, object keys, or numbers that exceed a given length

- encountering duplicate keys as per JSONlint

In some cases excessively long values (e.g. JSON numbers with millions of digits) may support denial-of-service attacks. For example, the string constructor for Java's BigInteger is quadratic with the length of the input, and decoding a ten-million digit JSON number into a BigInteger may take minutes.

If allowDuplicateKeys is set to true, the parser will not fail if it encounters an object containing duplicate keys. Note that duplicate keys are not prohibited by the JSON specification, but many linters and other processors do not handle them.

Attributes

Source
JawnParser.scala
def apply(maxValueSize: Int): JawnParser

Returns a parser that fails on:

Returns a parser that fails on:

- JSON strings, object keys, or numbers that exceed a given length

- encountering duplicate keys as per JSONlint

In some cases excessively long values (e.g. JSON numbers with millions of digits) may support denial-of-service attacks. For example, the string constructor for Java's BigInteger is quadratic with the length of the input, and decoding a ten-million digit JSON number into a BigInteger may take minutes.

Attributes

Source
JawnParser.scala
def apply(allowDuplicateKeys: Boolean): JawnParser

If allowDuplicateKeys is set to true, the parser will not fail if it encounters an object containing duplicate keys.

If allowDuplicateKeys is set to true, the parser will not fail if it encounters an object containing duplicate keys. Note that duplicate keys are not prohibited by the JSON specification, but many linters and other processors do not handle them.

Attributes

Source
JawnParser.scala