ClosureMirror class

A ClosureMirror reflects a closure.

A ClosureMirror reflects a closure.

A ClosureMirror provides the ability to execute its reflectee and introspect its function.

Implements:

Constructors

ClosureMirror ( )

Instance Properties

function MethodMirror
read-only
hasReflectee bool Inherited
read-only
reflectee dynamic Inherited
read-only
type ClassMirror Inherited
read-only

Instance Methods

apply ( List positionalArguments, [Map<Symbol> namedArguments] ) → InstanceMirror
Executes the closure and returns a mirror on the result. Let f be the closure reflected by this mirror, let a1, ..., an be the elements of positionalArguments let k1, ..., km be the identifiers deno...
setField Inherited ( Symbol fieldName, Object value ) → InstanceMirror
Invokes a setter and returns a mirror on the result. The setter may be either the implicit setter for a non-final field or a user-defined setter method.
delegate Inherited ( Invocation invocation ) → dynamic
Perform invocation on reflectee. Equivalent to
getField Inherited ( Symbol fieldName ) → InstanceMirror
Invokes a getter and returns a mirror on the result. The getter can be the implicit getter for a field or a user-defined getter method.
invoke Inherited ( Symbol memberName, List positionalArguments, [Map<Symbol> namedArguments] ) → InstanceMirror
Invokes the named function and returns a mirror on the result.