Class DataTypeDialog
java.lang.Object
org.eclipse.jface.window.Window
org.eclipse.jface.dialogs.Dialog
org.eclipse.jface.dialogs.TrayDialog
org.eclipse.jface.dialogs.TitleAreaDialog
org.palladiosimulator.editors.commons.dialogs.datatype.DataTypeDialog
- All Implemented Interfaces:
IShellProvider
- Direct Known Subclasses:
PalladioDataTypeDialog
The dialogue is used in the PCM Bench for the production by Collection or Composite data types.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.jface.window.Window
Window.IExceptionHandler
-
Field Summary
Fields inherited from class org.eclipse.jface.dialogs.TitleAreaDialog
DLG_IMG_TITLE_BANNER, DLG_IMG_TITLE_ERROR, INFO_MESSAGE, WARNING_MESSAGE
Fields inherited from class org.eclipse.jface.dialogs.Dialog
blockedHandler, buttonBar, DIALOG_DEFAULT_BOUNDS, DIALOG_PERSISTLOCATION, DIALOG_PERSISTSIZE, dialogArea, DLG_IMG_ERROR, DLG_IMG_HELP, DLG_IMG_INFO, DLG_IMG_MESSAGE_ERROR, DLG_IMG_MESSAGE_INFO, DLG_IMG_MESSAGE_WARNING, DLG_IMG_QUESTION, DLG_IMG_WARNING, ELLIPSIS
Fields inherited from class org.eclipse.jface.window.Window
CANCEL, OK, resizeHasOccurred
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
configureShell
(Shell newShell) protected void
createButtonsForButtonBar
(Composite parent) abstract void
The method create a new CollectionDataType.abstract void
The method create a new CompositeDataType.protected Control
createDialogArea
(Composite parent) abstract void
The method create the editing area for CompositeDataType.protected Group
Gets the choice type group.protected Button
Gets the collection button.protected Composite
Gets the composite.protected Button
Gets the composite button.protected DataTypeEnum
Gets the edite data type.protected String
Gets the entity name.protected Point
abstract String[]
The method define the list with a loaded repository.abstract String
Gets the selected inner type.protected StackLayout
Gets the stack layout.protected void
init
(DataTypeEnum dataTyp, String repositoryName, String entityName, String entityInnerType) The method is called with the editing of the type of DataType.abstract void
setEditedResource
(String resource) Sets the edited resource.void
setEnabled
(boolean enabled) Enables the receiver all component if the argument is true, and disables it otherwise.protected void
Sets the ok button disabled.protected void
Sets the ok button enabled.protected void
Sets the top collection layout.protected void
The method specified in topControl is visible and all other controls are not visible.abstract boolean
Validate composite data type.void
The method examines whether the straight editing DataTYpe type has all parameters.Methods inherited from class org.eclipse.jface.dialogs.TitleAreaDialog
createContents, getErrorMessage, getMessage, getTitleArea, getTitleImageLabel, setErrorMessage, setMessage, setMessage, setTitle, setTitleAreaColor, setTitleImage
Methods inherited from class org.eclipse.jface.dialogs.TrayDialog
closeTray, createButtonBar, createHelpControl, getLayout, getTray, handleShellCloseEvent, isDialogHelpAvailable, isHelpAvailable, openTray, setDialogHelpAvailable, setHelpAvailable
Methods inherited from class org.eclipse.jface.dialogs.Dialog
applyDialogFont, buttonPressed, cancelPressed, close, convertHeightInCharsToPixels, convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, convertWidthInCharsToPixels, create, createButton, dialogFontIsDefault, getBlockedHandler, getButton, getButtonBar, getCancelButton, getDialogArea, getDialogBoundsSettings, getDialogBoundsStrategy, getImage, getInitialLocation, getOKButton, initializeBounds, initializeDialogUnits, isResizable, okPressed, setBlockedHandler, setButtonLayoutData, setButtonLayoutFormData, shortenText
Methods inherited from class org.eclipse.jface.window.Window
canHandleShellCloseEvent, constrainShellSize, createShell, getConstrainedShellBounds, getContents, getDefaultImage, getDefaultImages, getDefaultOrientation, getParentShell, getReturnCode, getShell, getShellListener, getShellStyle, getWindowManager, handleFontChange, open, setBlockOnOpen, setDefaultImage, setDefaultImages, setDefaultModalParent, setDefaultOrientation, setExceptionHandler, setParentShell, setReturnCode, setShellStyle, setWindowManager
-
Constructor Details
-
DataTypeDialog
Instantiates a new data type dialog.- Parameters:
parentShell
- the parent shell
-
-
Method Details
-
init
protected void init(DataTypeEnum dataTyp, String repositoryName, String entityName, String entityInnerType) The method is called with the editing of the type of DataType.- Parameters:
dataTyp
- the data typrepositoryName
- - the repository name of editing DataTypeentityName
- - the name of the editing DataTypeentityInnerType
- - the inner type of the editing DataType
-
configureShell
- Overrides:
configureShell
in classWindow
-
createDialogArea
- Overrides:
createDialogArea
in classTitleAreaDialog
-
setEnabled
public void setEnabled(boolean enabled) Enables the receiver all component if the argument is true, and disables it otherwise.- Parameters:
enabled
- the new enabled state
-
getInitialSize
- Overrides:
getInitialSize
in classTitleAreaDialog
-
getEditeDataType
Gets the edite data type.- Returns:
- the edite data type
-
createButtonsForButtonBar
- Overrides:
createButtonsForButtonBar
in classDialog
-
setOKButtonEnabled
protected void setOKButtonEnabled()Sets the ok button enabled. -
setOKButtonDisabled
protected void setOKButtonDisabled()Sets the ok button disabled. -
getLoadedRepositories
The method define the list with a loaded repository.- Returns:
- the loaded repositories
-
createInnerSectionCompositeGroup
The method create the editing area for CompositeDataType.- Parameters:
group
- the group
-
getSelectedInnerType
Gets the selected inner type.- Parameters:
event
- the event- Returns:
- the selected inner type
-
setEditedResource
Sets the edited resource.- Parameters:
resource
- the new edited resource
-
createCollectionDataType
public abstract void createCollectionDataType()The method create a new CollectionDataType. -
createCompositeDataType
public abstract void createCompositeDataType()The method create a new CompositeDataType. -
validateCompositeDataType
public abstract boolean validateCompositeDataType()Validate composite data type.- Returns:
- true, if successful
-
getEntityName
Gets the entity name.- Returns:
- the entity name
-
setTopCompositeLayout
protected void setTopCompositeLayout()The method specified in topControl is visible and all other controls are not visible. -
setTopCollectionLayout
protected void setTopCollectionLayout()Sets the top collection layout. -
validateInput
public void validateInput()The method examines whether the straight editing DataTYpe type has all parameters. -
getChoiceTypeGroup
Gets the choice type group.- Returns:
- the choice type group
-
getCompositeButton
Gets the composite button.- Returns:
- the composite button
-
getCollectionButton
Gets the collection button.- Returns:
- the collection button
-
getStackLayout
Gets the stack layout.- Returns:
- the stack layout
-
getComposite
Gets the composite.- Returns:
- the composite
-