CLASS

HaapiFlowViewController

Contents

public class HaapiFlowViewController: UIViewController,
                                      HaapiFlowViewControllerDelegate,
                                      UIStylable,
                                      HaapiFlowDeepLinkable,
                                      DebugLayout

A view controller that specializes in managing the haapi flow.

Properties

debugDescription

override public var debugDescription: String

Methods

init(haapiUIKitApplication:haapiFlowResult:haapiDeepLinkManageable:nibName:bundle:notificationCenter:)

public convenience init(haapiUIKitApplication: HaapiUIKitApplication,
                        haapiFlowResult: HaapiFlowResult?,
                        haapiDeepLinkManageable: HaapiDeepLinkManageable?,
                        nibName nibNameOrNil: String? = "HaapiFlowViewController",
                        bundle nibBundleOrNil: Bundle? = Bundle(for: HaapiFlowViewController.self),
                        notificationCenter: NotificationCenter = NotificationCenter.default) throws

Initialises a new HaapiFlowViewController.

Parameters

Name Description
haapiUIKitApplication An HaapiUIKitApplication
haapiFlowResult The callback instance on which to deliver the result from the Haapi flow.
haapiDeepLinkManageable The deeplink manager reference.
nibName A nib name.
bundle A specified bundle.
notificationCenter the instance of NotificationCenter that is to be used for notification observation.

deinit

deinit

viewDidLoad()

override public func viewDidLoad()

viewWillAppear(_:)

override public func viewWillAppear(_ animated: Bool)

viewWillDisappear(_:)

override public func viewWillDisappear(_ animated: Bool)

submit(interactionActionModel:parameters:)

public func submit(interactionActionModel: any InteractionActionModel, parameters: [String: Any])

Parameters

Name Description
interactionActionModel The interaction action model.
parameters Parameters to be sent with the form action model.

select(selectorItemModel:)

public func select(selectorItemModel: any SelectorItemInteractionActionModel)

Parameters

Name Description
selectorItemModel The selector item model.

follow(linkItemModel:)

public func follow(linkItemModel: any LinkItemModel)

Parameters

Name Description
linkItemModel The link item model.

handleUIProblem(_:)

public func handleUIProblem(_ uiProblem: UIProblemModel)

Parameters

Name Description
uiProblem A problem model informs something unexpected happened.

interruptHaapiFlowForError(_:title:message:)

public func interruptHaapiFlowForError(_ error: any Error, title: String?, message: String?)

Parameters

Name Description
error An error that leads to interrupting the Haapi flow.
title The title information for interrupting the Haapi flow.
message The message information for interrupting the Haapi flow.

canOpenURL(_:)

public func canOpenURL(_ url: URL) -> Bool

Parameters

Name Description
url A URL

openURL(_:)

public func openURL(_ url: URL)

Parameters

Name Description
url A URL

canHandleUrl(_:)

public func canHandleUrl(_ url: URL) -> Bool

handleUrl(_:)

public func handleUrl(_ url: URL)

apply(style:)

public func apply(style: HaapiFlowViewControllerStyle)

Parameters

Name Description
style The style configuration to be applied to the component