replaceAllWithOptions method

void replaceAllWithOptions(
  1. AFCommandContext context,
  2. dynamic id,
  3. List<String> createValue(
    1. AFCommandContext context,
    2. List<String> options
    )
)

Replaces all the instances of id with the lines returned by createValue.

Implementation

void replaceAllWithOptions(AFCommandContext context, dynamic id, List<String> Function(AFCommandContext context, List<String> options) createValue) {
  final idCode = id.toString();
  for(var i = 0; i < lines.length; i++) {
    replaceInLine(context, i, idCode, createValue);
  }
}