public class ACLRightsEditor extends RightsComponent
,
Serialized FormRightsComponent.ACLGroupIDComparator, RightsComponent.ACLGroupNameComparator, RightsComponent.GroupsListModel, RightsComponent.IDComparator, RightsComponent.IDSortComparator, RightsComponent.ListMouseListener, RightsComponent.RightGroupIDComparator, RightsComponent.RightGroupNameComparator, RightsComponent.RightsTableModel, RightsComponent.TableCellRenderer, RightsComponent.TableMouseListener
javax.swing.JPanel.AccessibleJPanel
javax.swing.JComponent.AccessibleJComponent
Modifier and Type | Field and Description |
---|---|
protected ACL[] |
initRights |
protected ACL[] |
rights |
aclGroupIdComparator, aclGroupNameComparator, addRoles, aeID, borderTitle, deleteRights, groups, idComparator, idSort, idSortComparator, list, listPopup, makesSense, readOnlyMode, RIGHT_STRINGS, rightGroupIdComparator, rightGroupNameComparator, roleTitle, splitter, table, tablePopup, tPanel
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Constructor and Description |
---|
ACLRightsEditor(OdsxSelectHelper.NameId[] groups,
int makesSense,
ACL[] rights,
java.lang.String roleTitle)
Creates a new instance of SecurityLevelComponent
|
ACLRightsEditor(OdsxSelectHelper.NameId[] groups,
int makesSense,
java.lang.String roleTitle)
the constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addRightsForRoles(T_LONGLONG[] id,
T_LONGLONG refAid)
Add rights for role.
|
void |
commit(RightsHolderInterface holder,
ApplicationElement groupAe,
java.util.HashMap groupMap)
Commit the changes (Transaction must be activated before.)
|
protected void |
deleteRights(int[] idx)
Delete rights.
|
int |
findRightsForGroup(T_LONGLONG id)
Find rights index using the group id.
|
ACL[] |
getACLRights()
Get the initial rights.
|
ACL[] |
getACLToAdd()
Get all rights to be written.
|
ACL[] |
getACLToRemove()
Get all rights to be removed.
|
ACL[] |
getACLToSet()
Get all rights to be set.
|
java.lang.String |
getBorderTitle()
get the border title.
|
java.lang.String |
getRightsGroupName(int idx)
Get the group name belongs to a right
|
int |
getRightsLength()
Get the total number of available rights.
|
int |
getRightsValue(int idx)
Get the right value belongs to right.
|
void |
setACLRights(ACL[] rights)
Set rigths.
|
void |
setInitialACL(ACL[] rights)
Set the initial rights.
|
void |
setRightsValue(int idx,
int rights)
Set the right value belongs to right.
|
protected void |
sort()
Sort the internal arrays.
|
addNewRoles, cloneACL, cloneRight, createButtonPanel, createListPopup, createPanel, createTablePopup, deleteRights, getAeID, getGroupForId, getGroupName, getGroupName, getListPopup, getRightString, getTablePopup, hasRight, initialize, makesSense, setAeID, setBorderTitle, setGroups, setSensitivity, toggleRight, updateUI
getAccessibleContext, getUI, getUIClassID, paramString, setUI
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
public ACLRightsEditor(OdsxSelectHelper.NameId[] groups, int makesSense, java.lang.String roleTitle)
groups
- a list of available user groups.makesSense
- a bit mask that signals what right makes currently sense.
e.g. It makes no sense to set the insert right for attributes.roleTitle
- the title of the listbox that holds that list of roles.public ACLRightsEditor(OdsxSelectHelper.NameId[] groups, int makesSense, ACL[] rights, java.lang.String roleTitle)
groups
- a list of available user groups.rights
- the initial rights.roleTitle
- the title of the listbox that holds that list of roles.public java.lang.String getBorderTitle()
getBorderTitle
in class RightsComponent
protected void sort()
sort
in class RightsComponent
public void setInitialACL(ACL[] rights)
public ACL[] getACLRights()
public void setACLRights(ACL[] rights)
public int getRightsLength()
getRightsLength
in class RightsComponent
public java.lang.String getRightsGroupName(int idx)
getRightsGroupName
in class RightsComponent
public int getRightsValue(int idx)
getRightsValue
in class RightsComponent
public void setRightsValue(int idx, int rights)
setRightsValue
in class RightsComponent
public int findRightsForGroup(T_LONGLONG id)
findRightsForGroup
in class RightsComponent
public ACL[] getACLToSet()
public ACL[] getACLToAdd()
public ACL[] getACLToRemove()
public void commit(RightsHolderInterface holder, ApplicationElement groupAe, java.util.HashMap groupMap) throws AoException
aeObj
- The application element.groupAe
- The application element belongs to aousergroup.groupMap
- the map to cache the group instance elements.AoException
protected void addRightsForRoles(T_LONGLONG[] id, T_LONGLONG refAid)
addRightsForRoles
in class RightsComponent
protected void deleteRights(int[] idx)
deleteRights
in class RightsComponent