org.openpermis.editor.policy.view
Class DecisionTool

java.lang.Object
  extended by org.openpermis.editor.policy.view.AbstractView
      extended by org.openpermis.editor.policy.view.AbstractToolView<DecisionPresenter>
          extended by org.openpermis.editor.policy.view.DecisionTool
All Implemented Interfaces:
ErrorReporter, Tool, View

public class DecisionTool
extends AbstractToolView<DecisionPresenter>

Displays the resulting access decision for selected roles and actions.

Since:
0.3.0

Field Summary
private  JComboBox actionList
           
private  JComboBox authorityList
           
private  JLabel decisionLabel
           
private  JPanel decisionPanel
           
private static bibliothek.gui.dock.common.CLocation DEFAULT_LOCATION
          Place the tool by default in the right part of the window and give it enough space.
private  JTable parameterTable
           
private  JComboBox resourceDomainList
           
private  CheckList<org.openpermis.policy.Role> roleList
           
private  TimeStampPicker timeStampPicker
           
 
Constructor Summary
DecisionTool(org.jdesktop.application.ApplicationContext context, AdapterTrader trader)
          Creates a decision tool view.
 
Method Summary
protected  void attachPresenter(DecisionPresenter presenter, org.jdesktop.beansbinding.BindingGroup bindings)
          Attaches any listeners required to the new presenter and binds components.
private  void bindComboBox(org.jdesktop.beansbinding.BindingGroup bindings, JComboBox comboBox, DecisionPresenter presenter, String presenterProperty, org.jdesktop.observablecollections.ObservableList<? extends org.openpermis.policy.bean.PartBean> beanList)
           
private  void bindPresenterProperties(DecisionPresenter presenter, org.jdesktop.beansbinding.BindingGroup bindings)
           
protected  JComponent createContentPane()
          Creates the content pane of this view.
private  JPanel createDecisionPane(JLabel label)
           
private  CheckList<org.openpermis.policy.Role> createRoleList()
           
 bibliothek.gui.dock.common.CLocation getDefaultLocation()
          Returns the desired default location relative to the working area for this tool view.
 void refresh(org.openpermis.policy.bean.PolicyBean policy, PolicyContext context)
          Instructs the tool to refresh itself with the specified policy.
 
Methods inherited from class org.openpermis.editor.policy.view.AbstractToolView
contentPaneCreated, createToolBar, detachPresenter, getPresenter, getToolBar, getToolIdentifier, setPresenter, updateActions
 
Methods inherited from class org.openpermis.editor.policy.view.AbstractView
attach, canClose, canEditPart, closeView, detach, editPart, getActionMap, getAdapteeTrader, getContentPane, getIcon, getResourceMap, getTitle, getTitleParameters, getViewContext, label, openView, showStatusError, toolBar, updateTitle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.openpermis.editor.policy.view.View
attach, canClose, detach, getContentPane, getIcon, getTitle
 

Field Detail

DEFAULT_LOCATION

private static final bibliothek.gui.dock.common.CLocation DEFAULT_LOCATION
Place the tool by default in the right part of the window and give it enough space.

Since:
0.3.0

authorityList

private JComboBox authorityList
Since:
0.3.0

resourceDomainList

private JComboBox resourceDomainList
Since:
0.3.0

actionList

private JComboBox actionList
Since:
0.3.0

roleList

private CheckList<org.openpermis.policy.Role> roleList
Since:
0.3.0

timeStampPicker

private TimeStampPicker timeStampPicker
Since:
0.3.0

decisionLabel

private JLabel decisionLabel
Since:
0.3.0

decisionPanel

private JPanel decisionPanel
Since:
0.3.0

parameterTable

private JTable parameterTable
Since:
0.3.0
Constructor Detail

DecisionTool

public DecisionTool(org.jdesktop.application.ApplicationContext context,
                    AdapterTrader trader)
Creates a decision tool view.

Parameters:
context - application meta data for the tool.
Since:
0.3.0
Method Detail

bindPresenterProperties

private void bindPresenterProperties(DecisionPresenter presenter,
                                     org.jdesktop.beansbinding.BindingGroup bindings)
Since:
0.3.0

bindComboBox

private void bindComboBox(org.jdesktop.beansbinding.BindingGroup bindings,
                          JComboBox comboBox,
                          DecisionPresenter presenter,
                          String presenterProperty,
                          org.jdesktop.observablecollections.ObservableList<? extends org.openpermis.policy.bean.PartBean> beanList)
Since:
0.3.0

createRoleList

private CheckList<org.openpermis.policy.Role> createRoleList()
Since:
0.3.0

createDecisionPane

private JPanel createDecisionPane(JLabel label)
Since:
0.3.0

refresh

public void refresh(org.openpermis.policy.bean.PolicyBean policy,
                    PolicyContext context)
Description copied from interface: Tool
Instructs the tool to refresh itself with the specified policy.

Called whenever the policy that this view renders changes.

Parameters:
policy - the policy to refresh with.
context - the policy context to use.
Since:
0.3.0

attachPresenter

protected void attachPresenter(DecisionPresenter presenter,
                               org.jdesktop.beansbinding.BindingGroup bindings)
Description copied from class: AbstractToolView
Attaches any listeners required to the new presenter and binds components.

The default implementation initializes the content pane if necessary.

Overrides:
attachPresenter in class AbstractToolView<DecisionPresenter>
Parameters:
presenter - the new presenter to attach to.
bindings - the binding group to add bindings to.
Since:
0.3.0

createContentPane

protected JComponent createContentPane()
Description copied from class: AbstractView
Creates the content pane of this view.

Specified by:
createContentPane in class AbstractView
Returns:
the content pane of this view, must not be null.
Since:
0.3.0

getDefaultLocation

public bibliothek.gui.dock.common.CLocation getDefaultLocation()
Description copied from interface: Tool
Returns the desired default location relative to the working area for this tool view.

Specified by:
getDefaultLocation in interface Tool
Overrides:
getDefaultLocation in class AbstractToolView<DecisionPresenter>
Returns:
the desired default location of this tool view.
Since:
0.3.0


PERMIS Role Based Access Control 0.3.0 (Build 14)
2009/05/08 09:06:48
Copyright (c) 2002-2007 Ergon Informatik AG