peekAtDepth method

ParsedLine? peekAtDepth(
  1. int targetDepth
)

Implementation

ParsedLine? peekAtDepth(int targetDepth) {
  final line = peek();
  if (line == null || line.depth < targetDepth) {
    return null;
  }
  if (line.depth == targetDepth) {
    return line;
  }
  return null;
}