C-DEngine 5.105

TheCommonUtils..::..CBool Method

Converts an object to boolean.

Namespace:  nsCDEngine.BaseClasses
Assembly:  C-DEngine (in C-DEngine.dll)

Syntax


public static bool CBool(
	Object inObj
)
Public Shared Function CBool ( _
	inObj As Object _
) As Boolean
public:
static bool^ CBool(
	Object^ inObj
)

Parameters

inObj
Type: Object
Input to be converted.

Return Value

The converted value.

Remarks


A safe, efficient function to convert any input to a boolean value. Safe means that no unhandled exceptions are generated. A null value is interpreted as 'false', as is any invalid value, or a string containing "0". A string containing "1" will be interpreted as 'true'.