matchesNext method

bool matchesNext(
  1. RegExp regex
)

Gets whether or not the next line matches the given pattern.

Implementation

bool matchesNext(RegExp regex) {
  if (next == null) return false;
  return regex.hasMatch(next!.content);
}