程序包 com.sh.json
类 JSONNull
java.lang.Object
com.sh.json.JSONNull
- 所有已实现的接口:
JSON,Serializable
JSONNull is equivalent to the value that JavaScript calls null, whilst Java's
null is equivalent to the value that JavaScript calls undefined.
- 另请参阅:
-
方法概要
修饰符和类型方法说明booleanA Null object is equal to the null value and to itself.static JSONNullReturns the singleton instance of JSONNullinthashCode()booleanisArray()Returns true if this object is a JSONArray, false otherwise.booleanisEmpty()Returns true if this object has no elements or keys.intsize()Returns the number of properties in an object or the size of the array.toString()Get the "null" string value.toString(int indentFactor) Make a prettyprinted JSON text.toString(int indentFactor, int indent) Make a prettyprinted JSON text.Write the contents as JSON text to a writer.
-
方法详细资料
-
getInstance
Returns the singleton instance of JSONNull -
equals
A Null object is equal to the null value and to itself. -
hashCode
public int hashCode() -
isArray
public boolean isArray()从接口复制的说明:JSONReturns true if this object is a JSONArray, false otherwise. -
isEmpty
public boolean isEmpty()从接口复制的说明:JSONReturns true if this object has no elements or keys. -
size
public int size()从接口复制的说明:JSONReturns the number of properties in an object or the size of the array. -
toString
Get the "null" string value. -
toString
从接口复制的说明:JSONMake a prettyprinted JSON text.Warning: This method assumes that the data structure is acyclical.
-
toString
从接口复制的说明:JSONMake a prettyprinted JSON text.Warning: This method assumes that the data structure is acyclical.
-
write
从接口复制的说明:JSONWrite the contents as JSON text to a writer. For compactness, no whitespace is added.Warning: This method assumes that the data structure is acyclical.
-