klyn.reflection.Constructor.operator
method
public operator ()(args as Object[]) as Object throws Exception
Description

Direct call operator.

Parameters
ParameterDescription
argsConstructor arguments as an Object[].
Returns

New instance.

Throws
  • TypeError if the declaring type is abstract or an interface, or the constructor is inaccessible or the arguments do not match.
  • Exception if argument binding or constructor execution fails.
Example
ctor = User.type.getConstructor()
user = ctor() as User