Package lazyj

Class Format.JSONFragment

java.lang.Object
lazyj.Format.JSONFragment
All Implemented Interfaces:
java.lang.CharSequence
Enclosing class:
Format

public static class Format.JSONFragment
extends java.lang.Object
implements java.lang.CharSequence
Since:
2019-10-08
Author:
costing
  • Constructor Summary

    Constructors 
    Constructor Description
    JSONFragment()
    Empty constructor
    JSONFragment​(java.lang.CharSequence toCopy)
    Copying another char sequence to this object, assuming that the content is a valid JSON fragment.
  • Method Summary

    Modifier and Type Method Description
    void append​(char c)
    Append a single char
    Format.JSONFragment append​(java.lang.CharSequence seq)  
    char charAt​(int index)  
    int hashCode()  
    int length()  
    java.lang.CharSequence subSequence​(int start, int end)  
    java.lang.String toString()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface java.lang.CharSequence

    chars, codePoints
  • Constructor Details

    • JSONFragment

      public JSONFragment()
      Empty constructor
    • JSONFragment

      public JSONFragment​(java.lang.CharSequence toCopy)
      Copying another char sequence to this object, assuming that the content is a valid JSON fragment. No checks are done on the validity of the content.
      Parameters:
      toCopy -
  • Method Details

    • length

      public int length()
      Specified by:
      length in interface java.lang.CharSequence
    • charAt

      public char charAt​(int index)
      Specified by:
      charAt in interface java.lang.CharSequence
    • subSequence

      public java.lang.CharSequence subSequence​(int start, int end)
      Specified by:
      subSequence in interface java.lang.CharSequence
    • toString

      public java.lang.String toString()
      Specified by:
      toString in interface java.lang.CharSequence
      Overrides:
      toString in class java.lang.Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class java.lang.Object
    • append

      public void append​(char c)
      Append a single char
      Parameters:
      c -
    • append

      public Format.JSONFragment append​(java.lang.CharSequence seq)
      Parameters:
      seq -
      Returns:
      the same object, to continue appending to if needed