Classic ASP Framework
org.classicasp.primitive.BooleanEx

A Boolean object is a data type that can have one of two values, either true or false, used for logical operations. Use the Boolean class to retrieve the core data type or string representation of a Boolean object.

To create a BooleanEx object, you can use the constructor or the global function, or assign a literal value.

Example

	
  Response.Write BooleanEx(True).toJSON()
  

Output

True

Summary

Returns a Bencoded string representation of the object.
Returns a json encoded string representation of the object.
Returns a string representation of the object.
Returns an XML encoded string representation of the object.
Writes a json encoded string representation of the object.
Writes an XML encoded string representation of the object.

toBencode

Public Function toBencode()
Returns a Bencoded string representation of the object.

Returns

String

Example

		
	  Response.Write BooleanEx(True).toBencode()
	  

Output

4:True

toJSON

Public Function toJSON()
Returns a json encoded string representation of the object.

Returns

String

Example

		
	  Response.Write BooleanEx(True).toJSON()
	  

Output

True

toString

Public Function toString()
Returns a string representation of the object.

Returns

StringEx

toXML

Public Function toXML()
Returns an XML encoded string representation of the object.

Returns

String

Example

		
	  Response.Write BooleanEx(True).toXML()
	  

Output

<data type="Boolean">True</data>

writeJSON

Public Sub writeJSON()
Writes a json encoded string representation of the object.

Returns

N/A

Example

		
	  Call BooleanEx(True).writeJSON()
	  

Output

True

writeXML

Public Sub writeXML()
Writes an XML encoded string representation of the object.

Returns

N/A

Example

		
	  Call BooleanEx(True).writeXML()
	  

Output

<data type="Boolean">True</data>

'***ClassicASP.org
'Copyright 2010 ClassicASP.org

'This file is part of ClassicASP Framework.

'ClassicASP-Framework is free software: you can redistribute it and/or modify
'it under the terms of the GNU General Public License as published by
'the Free Software Foundation, version 3 of the License.

'ClassicASP-Framework is distributed in the hope that it will be useful,
'but WITHOUT ANY WARRANTY; without even the implied warranty of
'MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
'GNU General Public License for more details.

'You should have received a copy of the GNU General Public License
'along with ClassicASP-Framework. If not, see .

'For additional information please visit .