EGF Engine
Release 0.1.0

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

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

public class ContractElementWizard
extends AbstractModelElementWizard

This wizard allows the end-user to create or edit a contract element.


Field Summary
protected static String CONTRACT_ELEMENT_FIRST_PAGE
          Constant used to identify the contract element wizard page.
static String CONTRACT_ELEMENT_REFERENCE_PAGE
          Constant used to identify the contract element reference wizard page.
static String CONTRACT_ELEMENT_TYPE_PAGE
          Constant used to identify the contract element type wizard page.
 
Constructor Summary
ContractElementWizard(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.
 boolean performFinish()
           
 
Methods inherited from class org.eclipse.egf.core.ui.wizard.AbstractModelElementWizard
canFinish, containsChanges, endChangesRecording, getChangeDescription, getChangeRecorder, getDescription, getModelElement, getModifiedFeature, getParent, getWizardDefaultPageImageDescriptor, handleChangeDescription, isInReadOnlyMode, performCancel, startChangesRecording
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONTRACT_ELEMENT_TYPE_PAGE

public static final String CONTRACT_ELEMENT_TYPE_PAGE
Constant used to identify the contract element type wizard page.

See Also:
Constant Field Values

CONTRACT_ELEMENT_REFERENCE_PAGE

public static final String CONTRACT_ELEMENT_REFERENCE_PAGE
Constant used to identify the contract element reference wizard page.

See Also:
Constant Field Values

CONTRACT_ELEMENT_FIRST_PAGE

protected static final String CONTRACT_ELEMENT_FIRST_PAGE
Constant used to identify the contract element wizard page.

See Also:
Constant Field Values
Constructor Detail

ContractElementWizard

public ContractElementWizard(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()

performFinish

public boolean performFinish()
Overrides:
performFinish in class AbstractModelElementWizard
See Also:
AbstractModelElementWizard.performFinish()

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)

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()

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)

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.