public class ConformEditor extends AbstractOfficeFloorEditor<Model,Object>
paletteRoot
Constructor and Description |
---|
ConformEditor(org.eclipse.gef.RootEditPart rootEditPart,
org.eclipse.swt.widgets.Shell shell)
Initialise.
|
Modifier and Type | Method and Description |
---|---|
protected Object |
createModelChanges(Model model)
Creates the
Model change functionality. |
org.eclipse.gef.RootEditPart |
getRootEditPart()
Obtains the
RootEditPart . |
void |
mapModelToEditPart(Class<?> modelType,
Class<? extends org.eclipse.gef.EditPart> editPartType)
Maps a
Model type to its respective EditPart type. |
void |
messageStatus(org.eclipse.core.runtime.IStatus status,
String title)
Displays a
Dialog for the IStatus . |
protected void |
populateEditPartTypes(Map<Class<?>,Class<? extends org.eclipse.gef.EditPart>> map)
Populates the
EditPart types for their respective model. |
protected void |
populateGraphicalEditPolicy(OfficeFloorGraphicalNodeEditPolicy policy)
Populates the
OfficeFloorGraphicalNodeEditPolicy . |
protected void |
populateLayoutEditPolicy(OfficeFloorLayoutEditPolicy policy)
Populates the
OfficeFloorLayoutEditPolicy . |
protected void |
populateOperations(List<Operation> list)
Populates the listing of
Operation instances. |
protected Model |
retrieveModel(ConfigurationItem configuration)
Retrieves the Model.
|
protected void |
storeModel(Model model,
ConfigurationItem configuration)
Stores the Model.
|
createEditPart, createGraphicalEditPolicy, createLayoutEditPolicy, doSave, doSaveAs, getCastedModel, getModelChanges, getPalettePreferences, getPaletteRoot, initialiseContextMenu, initialisePaletteRoot, initializeGraphicalViewer, isSaveAsAllowed, loadEditPartTypes, messageError, messageError, messageError, messageError, messageWarning, setCastedModel, setInput
createPaletteComposite, createPalettePage, createPaletteViewerProvider, createPartControl, getAdapter, getGraphicalControl, getPaletteViewerProvider, setEditDomain
commandStackChanged, configureGraphicalViewer, createActions, createGraphicalViewer, dispose, firePropertyChange, getActionRegistry, getCommandStack, getEditDomain, getGraphicalViewer, getPropertyActions, getSelectionActions, getSelectionSynchronizer, getStackActions, hookGraphicalViewer, init, initializeActionRegistry, isDirty, selectionChanged, setActionRegistry, setFocus, setGraphicalViewer, updateActions
checkSite, getEditorInput, getEditorSite, getTitleToolTip, isSaveOnCloseNeeded, setContentDescription, setInitializationData, setInputWithNotify, setPartName
addPartPropertyListener, addPropertyListener, firePartPropertyChanged, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
public ConformEditor(org.eclipse.gef.RootEditPart rootEditPart, org.eclipse.swt.widgets.Shell shell)
rootEditPart
- RootEditPart
.shell
- Shell
.public void mapModelToEditPart(Class<?> modelType, Class<? extends org.eclipse.gef.EditPart> editPartType)
Model
type to its respective EditPart
type.modelType
- Model
type.editPartType
- EditPart
type.public org.eclipse.gef.RootEditPart getRootEditPart()
AbstractOfficeFloorEditor
RootEditPart
.getRootEditPart
in class AbstractOfficeFloorEditor<Model,Object>
RootEditPart
.public void messageStatus(org.eclipse.core.runtime.IStatus status, String title)
AbstractOfficeFloorEditor
Dialog
for the IStatus
.messageStatus
in class AbstractOfficeFloorEditor<Model,Object>
status
- IStatus
.title
- Title for Dialog
.protected Object createModelChanges(Model model)
AbstractOfficeFloorEditor
Model
change functionality.createModelChanges
in class AbstractOfficeFloorEditor<Model,Object>
model
- Root Model
.Model
change functionality.protected void populateEditPartTypes(Map<Class<?>,Class<? extends org.eclipse.gef.EditPart>> map)
AbstractOfficeFloorEditor
EditPart
types for their respective model.populateEditPartTypes
in class AbstractOfficeFloorEditor<Model,Object>
map
- Registry to load the mappings.protected void populateGraphicalEditPolicy(OfficeFloorGraphicalNodeEditPolicy policy)
AbstractOfficeFloorEditor
OfficeFloorGraphicalNodeEditPolicy
.populateGraphicalEditPolicy
in class AbstractOfficeFloorEditor<Model,Object>
policy
- OfficeFloorGraphicalNodeEditPolicy
.protected void populateLayoutEditPolicy(OfficeFloorLayoutEditPolicy policy)
AbstractOfficeFloorEditor
OfficeFloorLayoutEditPolicy
.populateLayoutEditPolicy
in class AbstractOfficeFloorEditor<Model,Object>
policy
- OfficeFloorLayoutEditPolicy
.protected void populateOperations(List<Operation> list)
AbstractOfficeFloorEditor
Operation
instances.populateOperations
in class AbstractOfficeFloorEditor<Model,Object>
list
- Listing to add Operation
instances.protected Model retrieveModel(ConfigurationItem configuration) throws Exception
AbstractOfficeFloorEditor
retrieveModel
in class AbstractOfficeFloorEditor<Model,Object>
configuration
- Configuration of the Model.Exception
- If fails to obtain the Model.protected void storeModel(Model model, ConfigurationItem configuration) throws Exception
AbstractOfficeFloorEditor
storeModel
in class AbstractOfficeFloorEditor<Model,Object>
model
- Model to be stored.configuration
- Configuration of the Model.Exception
- If fails to store the Model.Copyright © 2005–2016. All rights reserved.