AutoTraversal
public protocol AutoTraversal : AutoLens
Protocol for automatic derivation of Traversal
-
traversal(for:)Extension methodProvides a Traversal focused on the items of the field given by a key path.
Declaration
Swift
static func traversal<T>(for path: WritableKeyPath<Self, Array<T>>) -> Traversal<Self, T>Parameters
pathKey path to a field containing an array of items.
Return Value
A Traversal focused on the items of the field.
-
traversal(for:)Extension methodProvides a Traversal focused on the items of the field given by a key path.
Declaration
Swift
static func traversal<T>(for path: WritableKeyPath<Self, ArrayK<T>>) -> Traversal<Self, T>Parameters
pathKey path to a field containing an
ArrayKof items.Return Value
A Traversal focused on the items of the field.
-
traversal(for:)Extension method
Install in Dash
AutoTraversal Protocol Reference