Package lazyj
Class Format.JSONFragment
java.lang.Object
lazyj.Format.JSONFragment
- All Implemented Interfaces:
CharSequence
- Enclosing class:
- Format
- Since:
- 2019-10-08
- Author:
- costing
-
Constructor Summary
ConstructorsConstructorDescriptionEmpty constructorJSONFragment
(CharSequence toCopy) Copying another char sequence to this object, assuming that the content is a valid JSON fragment. -
Method Summary
Modifier and TypeMethodDescriptionvoid
append
(char c) Append a single charappend
(CharSequence seq) char
charAt
(int index) int
hashCode()
int
length()
subSequence
(int start, int end) 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, isEmpty
-
Constructor Details
-
JSONFragment
public JSONFragment()Empty constructor -
JSONFragment
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 interfaceCharSequence
-
charAt
public char charAt(int index) - Specified by:
charAt
in interfaceCharSequence
-
subSequence
- Specified by:
subSequence
in interfaceCharSequence
-
toString
- Specified by:
toString
in interfaceCharSequence
- Overrides:
toString
in classObject
-
hashCode
public int hashCode() -
append
public void append(char c) Append a single char- Parameters:
c
-
-
append
- Parameters:
seq
-- Returns:
- the same object, to continue appending to if needed
-