IsObject()
Determines whether a value is an object.
- True, if the value represents a CFML object.
- False if the value is any other type of data, such as an integer, string, date, or struct.
IsObject( value=any );
Returns: Boolean
| Argument | Description |
|---|---|
|
value
any,
required
|
edit
A value, typically the name of a variable. |
Examples
editwriteDump(label:"String value", var:isObject("Susi"));
writeDump(label:"isObject() with array function", var:isObject(arrayNew(1)));
writeDump(label:"CreateObject in Java", var:isObject(createObject('java','java.util.HashMap')));
writeDump(label:"CreateObject in Java with init()", var:isObject(createObject('java',"java.lang.StringBuffer").init()));
See also
- Decision logic
- Objects
- Search Issue Tracker open_in_new
- Search Lucee Test Cases open_in_new (good for further, detailed examples)