toGetter method

DeclareFunctionStmt toGetter(
  1. String name, {
  2. List<Expression> annotations = const [],
})

Implementation

DeclareFunctionStmt toGetter(
  String name, {
  List<Expression> annotations = const [],
}) {
  return DeclareFunctionStmt(
    name,
    [],
    statements,
    annotations: annotations,
    type: type,
    isGetter: true,
  );
}