Skip to content

Instantly share code, notes, and snippets.

@albertodebortoli
Created December 18, 2019 14:28
Show Gist options
  • Save albertodebortoli/d19762b8231ff5048895b7817972e69a to your computer and use it in GitHub Desktop.
Save albertodebortoli/d19762b8231ff5048895b7817972e69a to your computer and use it in GitHub Desktop.
used by 'Modular iOS Architecture @ Just Eat' article on Medium
public typealias PasswordManagementService = ForgottenPasswordServiceProtocol & ResetPasswordServiceProtocol
public typealias AuthenticationService = LoginServiceProtocol & SignUpServiceProtocol & PasswordManagementService & RecaptchaServiceProtocol
public typealias UserAccountService = AccountInfoServiceProtocol & ChangePasswordServiceProtocol & ForgottenPasswordServiceProtocol & AccountCreditServiceProtocol
public class AccountModule {
public init(settings: Settings,
authenticationService: AuthenticationService,
userAccountService: UserAccountService,
socialLoginServices: [SocialLoginService],
userInfoProvider: UserInfoProvider)
public func startLogin(on viewController: UIViewController) -> FlowCoordinator
public func startResetPassword(on viewController: UIViewController, token: Token) -> FlowCoordinator
public func startAccountInfo(on navigationController: UINavigationController) -> FlowCoordinator
public func startAccountCredit(on navigationController: UINavigationController) -> FlowCoordinator
public func loginUsingSharedWebCredentials(handler: @escaping (LoginResult) -> Void)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment