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 TypeMethodDescriptionbooleanReturnstrueif this is the instance representing "true",falseotherwise.static JSONBooleangetInstance(boolean b) Gets a reference to the singleton instance representing eithertrueorfalse.(package private) JavaScriptObjectInternal.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 eithertrueorfalse.- Parameters:
b- controls which value to get- Returns:
- if
true, the JSONBoolean instance representingtrueis returned; otherwise, the JSONBoolean instance representingfalseis returned
-
booleanValue
public boolean booleanValue()Returnstrueif this is the instance representing "true",falseotherwise. -
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:JSONValueInternal. Returns a JS func that can unwrap this value. Used from native code.- Specified by:
getUnwrapperin classJSONValue
-