Package io.jans.casa.ui.vm.user
Class OTPViewModel
java.lang.Object
io.jans.casa.ui.vm.user.UserViewModel
io.jans.casa.ui.vm.user.OTPViewModel
This is the ViewModel of page otp-detail.zul. It controls the CRUD of HOTP/TOTP devices
- Author:
- jgomer
-
Field Summary
Fields inherited from class io.jans.casa.ui.vm.user.UserViewModel
sessionContext -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd()voidafterCompose(org.zkoss.zk.ui.Component view) voidcancel()voidcancelUpdate(org.zkoss.zk.ui.event.Event event) voidchangeHardType(boolean timeBased) voidchangeTokenPressing(org.zkoss.zk.ui.HtmlBasedComponent comp) voidvoidchooseType(String type, org.zkoss.zk.ui.HtmlBasedComponent comp) voidgetCode()intintbooleanbooleanbooleanvoidvoidvoidsetNewDevice(OTPDevice newDevice) voidsetSecretKeyString(String secretKeyString) voidshowQR(org.zkoss.zk.ui.HtmlBasedComponent comp) voidtimedOut(org.zkoss.zk.ui.event.Event event) voidupdate()voidMethods inherited from class io.jans.casa.ui.vm.user.UserViewModel
getAuthnMethodPageUrl, getPst, init
-
Constructor Details
-
OTPViewModel
public OTPViewModel()
-
-
Method Details
-
isUiCorrectCode
public boolean isUiCorrectCode() -
isUiQRShown
public boolean isUiQRShown() -
isUiTokenPressing
public boolean isUiTokenPressing() -
getEditingId
public int getEditingId() -
getDigitLength
public int getDigitLength() -
getTokenType
-
getHardTokenType
-
getCode
-
getNewDevice
-
getDevices
-
getSecretKeyString
-
setSecretKeyString
-
setNewDevice
-
setCode
-
childInit
- Throws:
Exception
-
chooseType
-
showQR
public void showQR(org.zkoss.zk.ui.HtmlBasedComponent comp) -
afterCompose
public void afterCompose(org.zkoss.zk.ui.Component view) -
timedOut
- Throws:
Exception
-
cancel
public void cancel() -
changeHardType
public void changeHardType(boolean timeBased) -
changeTokenPressing
public void changeTokenPressing(org.zkoss.zk.ui.HtmlBasedComponent comp) -
validateCode
public void validateCode() -
add
public void add() -
prepareForUpdate
-
cancelUpdate
public void cancelUpdate(org.zkoss.zk.ui.event.Event event) -
update
public void update() -
delete
-