BasicJSONEncoder (Grails 6.0.0)

Package: org.grails.encoder.impl

## [Java] Class BasicJSONEncoder

- org.grails.encoder.impl.BasicJSONEncoder

-     public class BasicJSONEncoder
      extends AbstractCharReplacementEncoder

  Escapes characters in JSON output

  Authors:
    Lari Hotari
  Since:
    2.3.4

- - ### Field Summary

    Fields
    Modifiers | Name | Description
    --- | --- | ---
    `static CodecIdentifier` | `JSON_CODEC_IDENTIFIER` |

  - Inherited fields
    Fields inherited from class | Fields
    --- | ---
    `class AbstractCharReplacementEncoder` | `codecIdentifier`

  - ### Constructor Summary

    Constructors
    Constructor and description
    `BasicJSONEncoder ()`

  - ### Methods Summary

    Methods
    Type Params | Return Type | Name and description
    --- | --- | ---
    `` | `protected java.lang.Object` | `doEncode(java.lang.Object o)`
    `` | `public final java.lang.Object` | `encode(java.lang.Object o)`
    `` | `protected java.lang.Object` | `encodeAsJsonObject(java.lang.Object o)`
    `` | `protected java.lang.String` | `escapeCharacter(char ch, char previousChar)`
    `` | `public boolean` | `isApplyToSafelyEncoded()`
    `` | `public boolean` | `isEquivalent(CodecIdentifier other)`

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class AbstractCharReplacementEncoder` | `convertToString, createChainingEncodesToWriter, doCharReplacementEncoding, encode, encodeToStream, encodeToWriter, encodeToWriter, escapeCharSequence, escapeCharacter, getCodecIdentifier, isApplyToSafelyEncoded, isSafe, markEncoded`

- - ### Field Detail

    - #### public static final CodecIdentifier JSON_CODEC_IDENTIFIER

  - ### Constructor Detail

    - #### public BasicJSONEncoder()

  - ### Method Detail

    - #### protected java.lang.Object doEncode(java.lang.Object o)

    - #### @java.lang.Override public final java.lang.Object encode(java.lang.Object o)

    - #### protected java.lang.Object encodeAsJsonObject(java.lang.Object o)

    - #### @java.lang.Override protected java.lang.String escapeCharacter(char ch, char previousChar)

    - #### @java.lang.Override public boolean isApplyToSafelyEncoded()

    - #### public boolean isEquivalent(CodecIdentifier other)