Version: v0.7.1 - Beta.  We welcome contributors & feedback.

Object.zHasMethod

zHasMethod($methodName) -> boolean

Description

Return true or false if the object has the given method.

class MyClass {

    fn myMethod($color) {
        ...
    }
}

$object = MyClass()

$object.zHasMethod('myMethod')     //= true
$object.zHasMethod('otherMethod')  //= false

See Also