Package com.google.gwt.json.client
Class JSONBoolean
java.lang.Object
com.google.gwt.json.client.JSONValue
com.google.gwt.json.client.JSONBoolean
Represents a JSON boolean value.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Returnstrue
if this is the instance representing "true",false
otherwise.static JSONBoolean
getInstance
(boolean b) Gets a reference to the singleton instance representing eithertrue
orfalse
.(package private) JavaScriptObject
Internal.Returnsthis
, as this is a JSONBoolean.toString()
Returns "true" for the true value, and "false" for the false value.
-
Method Details
-
getInstance
Gets a reference to the singleton instance representing eithertrue
orfalse
.- Parameters:
b
- controls which value to get- Returns:
- if
true
, the JSONBoolean instance representingtrue
is returned; otherwise, the JSONBoolean instance representingfalse
is returned
-
booleanValue
public boolean booleanValue()Returnstrue
if this is the instance representing "true",false
otherwise. -
isBoolean
Returnsthis
, as this is a JSONBoolean. -
toString
Returns "true" for the true value, and "false" for the false value. -
getUnwrapper
JavaScriptObject getUnwrapper()Description copied from class:JSONValue
Internal. Returns a JS func that can unwrap this value. Used from native code.- Specified by:
getUnwrapper
in classJSONValue
-