Type Aliases
The following type aliases are available globally.
-
Typealias for simple interaction callback. For more complex interactions (that contains parameters) define your own closure.
Declaration
Swift
public typealias Interaction = () -> Void
-
Typealias for simple interaction callback with a single parameter. For more complex interactions (that contains multiple parameters) define your own closure.
Declaration
Swift
public typealias CustomInteraction<T> = (T) -> Void
-
Closure used by a
NavigationInstruction
of type.custom
.Declaration
Swift
public typealias CustomNavigationOptionClosure = ( _ identifier: RouteElementIdentifier, _ from: RouteElementIdentifier, _ animated: Bool, _ context: Any?, _ completion: @escaping RoutingCompletion ) -> Void
-
Closure used by a
NavigationInstruction
of type.optionalCustom
. The return value determines whether the navigation has been handled or not. If not, the routing continues as if the navigation instruction is not definedDeclaration
Swift
public typealias OptionalCustomNavigationOptionClosure = ( _ identifier: RouteElementIdentifier, _ from: RouteElementIdentifier, _ animated: Bool, _ context: Any?, _ completion: @escaping RoutingCompletion ) -> Bool
-
Identifier to be used for a
Routable
.Declaration
Swift
public typealias RouteElementIdentifier = String
-
A path to identify a specific navigation state.
Declaration
Swift
public typealias Route = [RouteElementIdentifier]
-
Closure called when a navigation action is completed.
Declaration
Swift
public typealias RoutingCompletion = () -> Void