Last active
April 8, 2019 06:01
-
-
Save LiewJunTung/b5b4e52a90dd790e83e1367ebaa843d2 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.netvirta.common.login | |
| class LoginPresenterImpl(private val loginView: LoginView): LoginPresenter { | |
| val user = User("John", 1234) | |
| override fun processLogin(password: String) { | |
| if (password.toInt() == user.password){ | |
| loginView.loginResult("Login Successful! Welcome ${user.username}.") | |
| } else { | |
| loginView.loginResult("Login Failed! Try again.") | |
| } | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment