InvokeMethodExpr constructor

InvokeMethodExpr(
  1. Expression receiver,
  2. dynamic method,
  3. List<Expression> args, {
  4. OutputType? outputType,
  5. required bool checked,
  6. List<NamedExpr>? namedArgs = const [],
})

Implementation

InvokeMethodExpr(
  this.receiver,
  dynamic /* String | BuiltinMethod */ method,
  this.args, {
  OutputType? outputType,
  required this.checked,
  this.namedArgs = const [],
}) : super(outputType) {
  if (method is String) {
    name = method;
    builtin = null;
  } else {
    name = null;
    builtin = method as BuiltinMethod?;
  }
}