nextNPath method

Path nextNPath(
  1. int n
)

Implementation

Path nextNPath(int n) {
  Path nextPath = Path.from(this, growable: true);
  if (isEmpty) {
    return nextPath;
  }
  final last = nextPath.last;
  return nextPath
    ..removeLast()
    ..add(last + n);
}