UIHostingControllerWithContextFinder
@available(iOS 13.0, macOS 10.15, tvOS 13.0, watchOS 6.0, *)
public struct UIHostingControllerWithContextFinder<ContentView> : StackIteratingFinder where ContentView : ContextChecking, ContentView : View
A default implementation of the finder, that searches for a UIHostingController
with a specific View
and its Context
instance.
The View
should conform to the ContextChecking
to be used with this finder.
-
Declaration
Swift
public typealias ViewController = UIHostingController<ContentView>
-
Declaration
Swift
public typealias Context = ContentView.Context
-
A
StackIterator
is to be used byClassWithContextFinder
Declaration
Swift
public let iterator: StackIterator
-
Constructor
Declaration
Swift
public init(iterator: StackIterator = RouteComposerDefaults.shared.stackIterator)
Parameters
iterator
A
StackIterator
is to be used byClassWithContextFinder
-
Declaration
Swift
public func isTarget(_ viewController: ViewController, with context: Context) -> Bool
-
Constructor
Parameters
- options: A combination of the
SearchOptions
- startingPoint:
DefaultStackIterator.StartingPoint
value - windowProvider:
WindowProvider
instance. - containerAdapterLocator: A
ContainerAdapterLocator
instance.
Declaration
Swift
init(options: SearchOptions, startingPoint: DefaultStackIterator.StartingPoint = .topmost, windowProvider: WindowProvider = RouteComposerDefaults.shared.windowProvider, containerAdapterLocator: ContainerAdapterLocator = RouteComposerDefaults.shared.containerAdapterLocator)
- options: A combination of the