Iterable<Parameter> get namedParameters => optionalParameters.any((p) => p.named) ? optionalParameters : [];