EGF Engine
Release 0.1.0

org.eclipse.egf.core.ui.actions
Class AbstractGenerateCodeOperation

java.lang.Object
  extended by WorkspaceModifyOperation
      extended by org.eclipse.egf.core.ui.actions.AbstractGenerateCodeOperation

public abstract class AbstractGenerateCodeOperation
extends WorkspaceModifyOperation

This operation provides a template to perform code generation that modifies the workspace content.


Constructor Summary
protected AbstractGenerateCodeOperation()
          Constructor.
 
Method Summary
protected abstract  boolean doExecute(IProgressMonitor monitor_p)
          Performs the steps that are to be treated as a single logical workspace change.
protected  void execute(IProgressMonitor monitor_p)
           
protected  GeneratorAdapterFactory getGeneratorAdapterFactory()
          Return the generator adapter factory.
protected  String getModelPath()
          Return the model path against the eclipse platform.
 boolean getResult()
          Return if the Emf generation is successful or not.
protected  GenModel loadExistingGenModel(IPath modelFileName_p, Collection<IEmfExtensionDescriptor> extensions_p)
          Load potentially existing GenModel for given model file path.
 void setGeneratorAdapterFactory(GeneratorAdapterFactory generatorAdapterFactory_p)
          Set the the generator adapter factory.
 void setModelPath(String modelPath_p)
          Set the model path against the eclipse platform.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractGenerateCodeOperation

protected AbstractGenerateCodeOperation()
Constructor.

Method Detail

getResult

public boolean getResult()
Return if the Emf generation is successful or not.

Returns:

execute

protected final void execute(IProgressMonitor monitor_p)
                      throws CoreException,
                             InvocationTargetException,
                             InterruptedException
Throws:
CoreException
InvocationTargetException
InterruptedException
See Also:
org.eclipse.ui.actions.WorkspaceModifyOperation#execute(org.eclipse.core.runtime.IProgressMonitor)

doExecute

protected abstract boolean doExecute(IProgressMonitor monitor_p)
                              throws CoreException,
                                     InvocationTargetException,
                                     InterruptedException
Performs the steps that are to be treated as a single logical workspace change.

Subclasses must implement this method.

Parameters:
monitor_p -
Returns:
Throws:
CoreException
InvocationTargetException
InterruptedException

loadExistingGenModel

protected GenModel loadExistingGenModel(IPath modelFileName_p,
                                        Collection<IEmfExtensionDescriptor> extensions_p)
Load potentially existing GenModel for given model file path.

Parameters:
modelFileName_p -
extensions_p - existing EMF generated_package extensions, whether in the workspace or in target platform.
Returns:

getModelPath

protected String getModelPath()
Return the model path against the eclipse platform.

Returns:
the modelPath

setModelPath

public void setModelPath(String modelPath_p)
Set the model path against the eclipse platform.

Parameters:
modelPath_p - the modelPath to set

getGeneratorAdapterFactory

protected GeneratorAdapterFactory getGeneratorAdapterFactory()
Return the generator adapter factory.

Returns:
the generatorAdapterFactory

setGeneratorAdapterFactory

public void setGeneratorAdapterFactory(GeneratorAdapterFactory generatorAdapterFactory_p)
Set the the generator adapter factory.

Parameters:
generatorAdapterFactory_p - the generatorAdapterFactory to set

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.