Repeat the given navigation operator N times and return the final result or Option.none if the operator fails along the way.
Option.none
See repeat for an unsafe version.
The underlying type of the tree.
The zipper that will be navigated.
How many times to apply the given navigation. No matter the navigation repeated, if n=0 the given zipper will be returned unchanged.
n=0
An updated zipper pointing at a new focus or Option.none() if the navigation failed because the path is invalid.
Option.none()
Repeat the given navigation operator N times and return the final result or
Option.noneif the operator fails along the way.See repeat for an unsafe version.
Type Param: A
The underlying type of the tree.
Param: self
The zipper that will be navigated.
Param: n
How many times to apply the given navigation. No matter the navigation repeated, if
n=0the given zipper will be returned unchanged.Returns
An updated zipper pointing at a new focus or
Option.none()if the navigation failed because the path is invalid.