EGF Engine
Release 0.1.0

org.eclipse.egf.core.ui.wizard
Class ContextElementWizard

java.lang.Object
  extended by Wizard
      extended by org.eclipse.egf.core.ui.wizard.AbstractModelElementWizard
          extended by org.eclipse.egf.core.ui.wizard.ContextElementWizard

public class ContextElementWizard
extends AbstractModelElementWizard

This wizard allows the end-user to edit a context element.


Field Summary
protected static String CONTEXT_ELEMENT_FIRST_PAGE
          Constant used to identify the context element wizard page.
static String CONTEXT_ELEMENT_KEY_PAGE
          Constant used to identify the context element key wizard page.
static String CONTEXT_ELEMENT_REFERENCE_PAGE
          Constant used to identify the context element reference wizard page.
static String CONTEXT_ELEMENT_VALUE_PAGE
          Constant used to identify the context element value wizard page.
 
Constructor Summary
ContextElementWizard(EObject parent_p, NamedModelElementWithId modelElement_p, boolean readOnlyMode_p)
          Constructor.
 
Method Summary
 void addPages()
           
protected  NamedModelElementWithId doCreateModelElement()
          Create concrete model element.
protected  Command getAddCommandForCreatedElement(AdapterFactoryEditingDomain editingDomain_p, EObject parent_p, NamedModelElementWithId createdElement_p)
          Get the command responsible of adding the created element to given parent when performing finish.
protected  String getCreationDescription()
          Returns the description when this wizard creates the displayed object.
protected  String getEditDescription()
          Returns the description when this wizard modifies the displayed object.
 IWizardPage getPage(String name_p)
           
protected  PluginChangeWrapperCommand getPluginChangeCommand(EditingDomain editingDomain_p, EObject modelElement_p, EStructuralFeature feature_p, Object value_p)
          Get the plugin change command.
protected  String getTitle()
          Returns the title message of this wizard.
protected  boolean handleCanFinish()
          Handle the canFinish condition in wizard mode (Read only or not) context.
 
Methods inherited from class org.eclipse.egf.core.ui.wizard.AbstractModelElementWizard
canFinish, containsChanges, endChangesRecording, getChangeDescription, getChangeRecorder, getDescription, getModelElement, getModifiedFeature, getParent, getWizardDefaultPageImageDescriptor, handleChangeDescription, isInReadOnlyMode, performCancel, performFinish, startChangesRecording
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTEXT_ELEMENT_KEY_PAGE

public static final String CONTEXT_ELEMENT_KEY_PAGE
Constant used to identify the context element key wizard page.

See Also:
Constant Field Values

CONTEXT_ELEMENT_REFERENCE_PAGE

public static final String CONTEXT_ELEMENT_REFERENCE_PAGE
Constant used to identify the context element reference wizard page.

See Also:
Constant Field Values

CONTEXT_ELEMENT_VALUE_PAGE

public static final String CONTEXT_ELEMENT_VALUE_PAGE
Constant used to identify the context element value wizard page.

See Also:
Constant Field Values

CONTEXT_ELEMENT_FIRST_PAGE

protected static final String CONTEXT_ELEMENT_FIRST_PAGE
Constant used to identify the context element wizard page.

See Also:
Constant Field Values
Constructor Detail

ContextElementWizard

public ContextElementWizard(EObject parent_p,
                            NamedModelElementWithId modelElement_p,
                            boolean readOnlyMode_p)
Constructor.

Parameters:
parent_p -
modelElement_p -
readOnlyMode_p -
Method Detail

addPages

public void addPages()
Overrides:
addPages in class AbstractModelElementWizard
See Also:
AbstractModelElementWizard.addPages()

getPage

public IWizardPage getPage(String name_p)
See Also:
org.eclipse.jface.wizard.Wizard#getPage(java.lang.String)

handleCanFinish

protected boolean handleCanFinish()
Description copied from class: AbstractModelElementWizard
Handle the canFinish condition in wizard mode (Read only or not) context.

Overrides:
handleCanFinish in class AbstractModelElementWizard
Returns:
true means (AbstractModelElementWizard.performFinish() method can be called); false otherwise.
See Also:
AbstractModelElementWizard.handleCanFinish()

doCreateModelElement

protected NamedModelElementWithId doCreateModelElement()
Description copied from class: AbstractModelElementWizard
Create concrete model element.

Specified by:
doCreateModelElement in class AbstractModelElementWizard
Returns:
a not null NamedModelElementWithId object.
See Also:
AbstractModelElementWizard.doCreateModelElement()

getAddCommandForCreatedElement

protected Command getAddCommandForCreatedElement(AdapterFactoryEditingDomain editingDomain_p,
                                                 EObject parent_p,
                                                 NamedModelElementWithId createdElement_p)
Description copied from class: AbstractModelElementWizard
Get the command responsible of adding the created element to given parent when performing finish.

Specified by:
getAddCommandForCreatedElement in class AbstractModelElementWizard
See Also:
org.eclipse.egf.core.ui.wizard.AbstractModelElementWizard#getAddCommandForCreatedElement(org.eclipse.emf.edit.domain.AdapterFactoryEditingDomain, org.eclipse.emf.ecore.EObject, org.eclipse.egf.model.NamedModelElementWithId)

getCreationDescription

protected String getCreationDescription()
Description copied from class: AbstractModelElementWizard
Returns the description when this wizard creates the displayed object.

Specified by:
getCreationDescription in class AbstractModelElementWizard
Returns:
a not null String instance.
See Also:
AbstractModelElementWizard.getCreationDescription()

getEditDescription

protected String getEditDescription()
Description copied from class: AbstractModelElementWizard
Returns the description when this wizard modifies the displayed object.

Specified by:
getEditDescription in class AbstractModelElementWizard
Returns:
a not null String instance.
See Also:
AbstractModelElementWizard.getEditDescription()

getPluginChangeCommand

protected PluginChangeWrapperCommand getPluginChangeCommand(EditingDomain editingDomain_p,
                                                            EObject modelElement_p,
                                                            EStructuralFeature feature_p,
                                                            Object value_p)
Description copied from class: AbstractModelElementWizard
Get the plugin change command.

Specified by:
getPluginChangeCommand in class AbstractModelElementWizard
Returns:
See Also:
org.eclipse.egf.core.ui.wizard.AbstractModelElementWizard#getPluginChangeCommand(org.eclipse.emf.edit.domain.EditingDomain, org.eclipse.emf.ecore.EObject, org.eclipse.emf.ecore.EStructuralFeature, java.lang.Object)

getTitle

protected String getTitle()
Description copied from class: AbstractModelElementWizard
Returns the title message of this wizard.

Specified by:
getTitle in class AbstractModelElementWizard
Returns:
See Also:
AbstractModelElementWizard.getTitle()

EGF Engine
Release 0.1.0

Copyright (c) Thales Corporate Services S.A.S, 2009.

This page is made available under license. For full details see the LEGAL in the documentation book that contains this page.