|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.swing.visuals.dataselectors.propertyeditor.EntityAttributeValuePanel
public class EntityAttributeValuePanel
EntityAttributeValuePanel is a swing component used to edit entity attribute values. The EntityAttributeValuePanel displays the name of the attribute to be edited as well as its current value when the attribute is selected in the table. The model for this component, which supplies information about the Entity attributes, is an instance of EntityAttributeValueModelInterface: supplies
//Create the model import com.sas.entities.Entity; import com.sas.dataselectors.propertyeditor.EntityAttributeValueSelectorAdapter; import com.sas.swing.visuals.dataselectors.propertyeditor.EntityAttributeValuePanel; Entity = new Entity(); EntityAttributeValueSelectorAdapter selectorAdapter = new EntityAttributeValueSelectorAdapter(entity); EntityAttributeValuePanel propertySheetPanel = new EntityAttributeValuePanel(selectorAdapter);
Field Summary | |
---|---|
protected javax.swing.JPanel |
cardContainer
Panel used for the various containers of the card layout |
protected java.awt.CardLayout |
cardLayout
Layout manager for the various containers in the panel |
protected DateEditorPanel |
datePanelContainer
Container for the DateEditorPanel component with the checkBox component |
protected java.util.Map |
editorMap
Name/value pairs (property name/editor) |
protected javax.swing.JPanel |
emptyContainer
Container used for an empty component (used for spacing) |
protected java.util.Map |
initialValues
Name/value pairs (property name/initial property value(s)) |
protected MultiSelectionListEditorPanel |
multiListContainer
Container for the MultiSelectionListEditorPanel component |
protected EditorPanelInterface |
previousPanel
Previous editor displayed in the panel |
protected int |
previousRow
Previous row selected in the TableView component |
protected java.awt.Container |
promptIdentifierContainer
Name/value pairs (property name/supplemental property value(s) used for informational purposes) |
protected RadioButtonEditorPanel |
radioButtonContainer
Container for the RadioButtonEditorPanel component |
static java.lang.String |
RB_KEY
|
protected DateEditorPanel |
requiredDatePanelContainer
Container for the DateEditorPanel component without the checkBox component |
protected DateEditorPanel |
requiredTimePanelContainer
Container for the DateEditorPanel component with the checkBox component for Time AttributeType |
protected DateEditorPanel |
requiredTimestampPanelContainer
Container for the DateEditorPanel component with the checkBox component for Time AttributeType |
protected javax.swing.ListSelectionModel |
rowSM
RowSelectionModel of the TableView component |
protected EntityAttributeValueModelInterface |
selectorAdapter
Model associated with thie panel |
protected SingleSelectionListEditorPanel |
singleListContainer
Container for the SingleSelectionListEditorPanel component |
protected EntityAttributeValueTableModelAdapter |
tableModel
Model associated with the TableView component of the panel |
protected javax.swing.JScrollPane |
tablePane
JScrollPane component that contains the TableView component of the panel |
protected TableView |
tableView
TableView component of the panel |
protected TextFieldEditorPanel |
textFieldContainer
Container for the TextFieldEditorPanel component |
protected DateEditorPanel |
timePanelContainer
Container for the DateEditorPanel component without the checkBox component for Time AttributeType |
protected DateEditorPanel |
timestampPanelContainer
Container for the DateEditorPanel component without the checkBox component for Time AttributeType |
protected javax.swing.JTextField |
valueField
Deprecated. |
Fields inherited from interface com.sas.swing.visuals.PanelInterface |
---|
CONTENTS_VALID_PROPERTY |
Constructor Summary | |
---|---|
EntityAttributeValuePanel(EntityAttributeValueModelInterface selectorAdapter)
Constructs a new EntityAttributeValuePanel with the specified model selectorAdapter |
Method Summary | |
---|---|
void |
commitLastEditedValue()
Ensures that the last attribute changed is committed to the default adapter instance. |
protected void |
displayContainer(int selectedRow)
Internal method for determining and displaying the appropriate editor for an attribute |
java.lang.String |
getDialogTitle()
Returns a title for this panel that should be displayed on a dialog's title bar. |
java.lang.String |
getHelpID()
Returns the help id for this panel. |
javax.swing.JComponent |
getPanel()
Returns the panel to be displayed. |
java.lang.String |
getTabTitle()
Returns a title for this panel that should be displayed as a title on a tab. |
protected void |
initialize()
Internal method for constructing the various component containers used in the EntityAttributeValuePanel |
protected void |
initializeTableView()
Constructs the various subcomponents used in the EntityAttributeValuePanel (tableView and its model, etc.) |
boolean |
isContentsValid()
Indicates if the panel's contents are in a valid state. |
boolean |
isYesNo()
Indicates if the panel asks a yes-no or ok type question. |
protected java.awt.Container |
makeDefaultValueContainer()
Internal method for constructing the container that displays attribute values |
protected java.awt.Container |
makeLabelContainer()
Internal method for constructing the container that displays the text for selecting a prompt |
protected java.awt.Container |
makePromptIdentifierLabelsContainer()
Internal method for constructing the container that displays information about a prompt |
protected java.awt.Container |
makePromptsContainer()
Internal method for constructing the master container that displays the tableView and attribute values |
protected java.awt.Container |
makeTableContainer()
Internal method for constructing the container that displays the tableView |
protected java.awt.Container |
makeValuesContainer()
Internal method for constructing the master container that displays the attribute values |
void |
onApply()
Apply any changes that may have been made in the panel. |
void |
onCancel()
Cancel any changes that may have been made in the panel. |
void |
onClose()
Indicates that the panel is being closed. |
protected void |
populatePromptIdentifierLabelsContainer(java.util.Map supplementalProperties)
Internal method for populating information about a prompt derived from the supplemental properties of an AttributeDescriptor |
void |
setContentsValid(boolean newValue)
Sets the valid state of the panel's contents. |
void |
setDialogTitle(java.lang.String dialogTitle)
Method from com.sas.swing.visuals.PanelInterface. |
void |
setTabTitle(java.lang.String tabTitle)
Method from com.sas.swing.visuals.PanelInterface. |
protected void |
showEditorPanel(java.lang.String propertyName,
java.lang.String editorType)
Internal method for creating a user-defined property editor |
Field Detail |
---|
public static final java.lang.String RB_KEY
protected TableView tableView
protected EntityAttributeValueTableModelAdapter tableModel
protected EntityAttributeValueModelInterface selectorAdapter
protected java.awt.CardLayout cardLayout
protected javax.swing.JPanel emptyContainer
protected javax.swing.JPanel cardContainer
protected TextFieldEditorPanel textFieldContainer
protected SingleSelectionListEditorPanel singleListContainer
protected MultiSelectionListEditorPanel multiListContainer
protected RadioButtonEditorPanel radioButtonContainer
protected DateEditorPanel datePanelContainer
protected DateEditorPanel requiredDatePanelContainer
protected DateEditorPanel requiredTimePanelContainer
protected DateEditorPanel timePanelContainer
protected DateEditorPanel requiredTimestampPanelContainer
protected DateEditorPanel timestampPanelContainer
protected int previousRow
protected javax.swing.JTextField valueField
protected EditorPanelInterface previousPanel
protected javax.swing.ListSelectionModel rowSM
protected java.util.Map editorMap
protected java.util.Map initialValues
protected java.awt.Container promptIdentifierContainer
protected javax.swing.JScrollPane tablePane
Constructor Detail |
---|
public EntityAttributeValuePanel(EntityAttributeValueModelInterface selectorAdapter)
selectorAdapter
- instance of EntityAttributeValueModelInterfaceMethod Detail |
---|
protected void initialize()
protected java.awt.Container makeLabelContainer()
protected java.awt.Container makePromptsContainer()
protected java.awt.Container makeTableContainer()
protected java.awt.Container makeValuesContainer()
protected java.awt.Container makePromptIdentifierLabelsContainer()
protected java.awt.Container makeDefaultValueContainer()
protected void initializeTableView()
protected void displayContainer(int selectedRow)
selectedRow
- row selected in the table of attributesprotected void populatePromptIdentifierLabelsContainer(java.util.Map supplementalProperties)
supplementalProperties
- supplementalProperties associated with
an AttributeDescriptorprotected void showEditorPanel(java.lang.String propertyName, java.lang.String editorType)
propertyName
- name of the propertyeditorType
- fully-qualified class name of the editor componentpublic void commitLastEditedValue()
public void setDialogTitle(java.lang.String dialogTitle)
public void setTabTitle(java.lang.String tabTitle)
public void onApply()
PanelInterface
onApply
in interface PanelInterface
public void onCancel()
PanelInterface
onCancel
in interface PanelInterface
public void onClose()
PanelInterface
onApply()
or onClose()
is called.
onClose
in interface PanelInterface
public java.lang.String getDialogTitle()
PanelInterface
getDialogTitle
in interface PanelInterface
public java.lang.String getTabTitle()
PanelInterface
getTabTitle
in interface PanelInterface
public javax.swing.JComponent getPanel()
PanelInterface
this
.
getPanel
in interface PanelInterface
public java.lang.String getHelpID()
PanelInterface
null
is returned, a help button is
not added for this panel.
getHelpID
in interface PanelInterface
public boolean isYesNo()
PanelInterface
isYesNo
in interface PanelInterface
true
if the panel asks a yes-no type question,
false
if the panel asks an ok type questionpublic boolean isContentsValid()
PanelInterface
true
except for when the panel is behaving as an editor and incomplete information has been entered.
This state can be used by a dialog, for example, to enable/disable the its "apply" buttons ("OK", "Yes", etc).
isContentsValid
in interface PanelInterface
true
if the panel's contents are valid, otherwise false
PanelInterface.setContentsValid(boolean)
public void setContentsValid(boolean newValue)
PanelInterface
PanelInterface
provides the property name identifier CONTENTS_VALID_PROPERTY
as
a convenience for implementing this as a bound property.
setContentsValid
in interface PanelInterface
newValue
- the new valid state for the panel's contentsPanelInterface.isContentsValid()
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |