Class SecurityController
- java.lang.Object
-
- org.pentaho.ui.xul.XulEventSourceAdapter
-
- org.pentaho.ui.xul.impl.AbstractXulEventHandler
-
- org.pentaho.di.ui.repository.repositoryexplorer.controllers.LazilyInitializedController
-
- org.pentaho.di.ui.repository.repositoryexplorer.controllers.SecurityController
-
- All Implemented Interfaces:
IUISupportController,org.pentaho.ui.xul.impl.XulEventHandler,org.pentaho.ui.xul.XulEventSource
public class SecurityController extends LazilyInitializedController implements IUISupportController
XulEventHandlerfor the Security panel of the repository explorer.This class handles only user-related functionality. If supported, other controllers handle roles, etc.
-
-
Field Summary
Fields Modifier and Type Field Description protected org.pentaho.ui.xul.binding.BindingFactorybfprotected MainControllermainControllerprotected booleanmanagedprotected org.pentaho.ui.xul.components.XulMessageBoxmessageBoxprotected UISecuritysecurityprotected UISecurityUsersecurityUserprotected org.pentaho.di.repository.RepositorySecurityManagerservicestatic intUSER_DECKprotected org.pentaho.ui.xul.components.XulTextboxuserDescriptionprotected org.pentaho.ui.xul.containers.XulDialoguserDialogprotected org.pentaho.ui.xul.components.XulTextboxuserPassword-
Fields inherited from class org.pentaho.di.ui.repository.repositoryexplorer.controllers.LazilyInitializedController
initialized, repository
-
-
Constructor Summary
Constructors Constructor Description SecurityController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidaddUser()addRole method is called when user has click ok on a add role dialog.voidcancelAddUserDialog()voidchangeToUserDeck()protected voidcreateBindings()protected voidcreateModel()protected voidcreateSecurity()protected voidcreateSecurityUser()protected booleandoLazyInit()protected voidenableButtons(boolean enableNew, boolean enableEdit, boolean enableRemove)org.pentaho.ui.xul.components.XulMessageBoxgetMessageBox()StringgetName()voidinit(org.pentaho.di.repository.Repository rep)protected booleaninitService()voidremoveUser()removeUser method is called when user has click on a remove button in a user deck.voidsaveUser()saveUser method is called when the user click on the ok button of a Add or Edit User dialog Depending on the mode it calls add of update user methodvoidsetEnableButtons(int selectedIndex)protected voidsetInitialDeck()voidsetMessageBox(org.pentaho.ui.xul.components.XulMessageBox messageBox)voidshowAddUserDialog()protected voidshowButtons(boolean showNew, boolean showEdit, boolean showRemove)voidshowEditUserDialog()voidtabClicked()protected voidupdateUser()updateUser method is called when user has click ok on a edit user dialog.-
Methods inherited from class org.pentaho.di.ui.repository.repositoryexplorer.controllers.LazilyInitializedController
doInEventThread, doWithBusyIndicator, lazyInit
-
Methods inherited from class org.pentaho.ui.xul.impl.AbstractXulEventHandler
bind, bind, getData, getXulDomContainer, setData, setName, setXulDomContainer
-
-
-
-
Field Detail
-
USER_DECK
public static final int USER_DECK
- See Also:
- Constant Field Values
-
userDialog
protected org.pentaho.ui.xul.containers.XulDialog userDialog
-
userPassword
protected org.pentaho.ui.xul.components.XulTextbox userPassword
-
userDescription
protected org.pentaho.ui.xul.components.XulTextbox userDescription
-
service
protected org.pentaho.di.repository.RepositorySecurityManager service
-
mainController
protected MainController mainController
-
security
protected UISecurity security
-
bf
protected org.pentaho.ui.xul.binding.BindingFactory bf
-
securityUser
protected UISecurityUser securityUser
-
messageBox
protected org.pentaho.ui.xul.components.XulMessageBox messageBox
-
managed
protected boolean managed
-
-
Method Detail
-
init
public void init(org.pentaho.di.repository.Repository rep) throws ControllerInitializationException- Specified by:
initin interfaceIUISupportController- Overrides:
initin classLazilyInitializedController- Throws:
ControllerInitializationException
-
doLazyInit
protected boolean doLazyInit()
- Specified by:
doLazyInitin classLazilyInitializedController
-
initService
protected boolean initService()
-
setInitialDeck
protected void setInitialDeck()
-
getMessageBox
public org.pentaho.ui.xul.components.XulMessageBox getMessageBox()
-
setMessageBox
public void setMessageBox(org.pentaho.ui.xul.components.XulMessageBox messageBox)
-
createBindings
protected void createBindings()
-
getName
public String getName()
- Specified by:
getNamein interfaceIUISupportController- Specified by:
getNamein interfaceorg.pentaho.ui.xul.impl.XulEventHandler- Overrides:
getNamein classorg.pentaho.ui.xul.impl.AbstractXulEventHandler
-
addUser
protected void addUser()
addRole method is called when user has click ok on a add role dialog. The method add the role- Throws:
Exception
-
updateUser
protected void updateUser()
updateUser method is called when user has click ok on a edit user dialog. The method updates the user- Throws:
Exception
-
removeUser
public void removeUser() throws ExceptionremoveUser method is called when user has click on a remove button in a user deck. It first displays a confirmation message to the user and once the user selects ok, it remove the user- Throws:
Exception
-
changeToUserDeck
public void changeToUserDeck()
-
saveUser
public void saveUser() throws ExceptionsaveUser method is called when the user click on the ok button of a Add or Edit User dialog Depending on the mode it calls add of update user method- Throws:
Exception
-
setEnableButtons
public void setEnableButtons(int selectedIndex)
-
enableButtons
protected void enableButtons(boolean enableNew, boolean enableEdit, boolean enableRemove)
-
showButtons
protected void showButtons(boolean showNew, boolean showEdit, boolean showRemove)
-
tabClicked
public void tabClicked()
-
-