Traversal
public typealias Traversal<S, A> = PTraversal<S, S, A, A>
-
Focuses on a specific index of this traversal.
Declaration
Swift
func at(_ i: A.AtIndex) -> Traversal<S, A.AtFoci>
Parameters
i
Index to focus.
Return Value
A traversal from this structure to the focused index.
-
Provides a traversal over all elements of the foci of this traversal.
Declaration
Swift
var every: Traversal<S, A.EachFoci> { get }
-
Provides a traversal focused on an index of the focus of this traversal.
Declaration
Swift
func index(_ i: A.IndexType) -> Traversal<S, A.IndexFoci>
Parameters
i
Index to focus.
Return Value
A traversal focused on an index of the focus of this traversal.
-
Provides a traversal focused on an index of the focus of this traversal.
Declaration
Swift
subscript(i: A.IndexType) -> Traversal<S, A.IndexFoci> { get }
Parameters
i
Index to focus.
Return Value
A traversal focused on an index of the focus of this traversal.
-
Provides an identity Traversal
Declaration
Swift
static var identity: Traversal<S, S> { get }
-
Provides a Traversal that takes an
S
or anS
and strips the choice ofS
.Declaration
Swift
static var codiagonal: Traversal<Either<S, S>, S> { get }