ch.sahits.codegen.wizards
Class MinimalArtifactDelegate

java.lang.Object
  extended by OutputFileModel
      extended by ch.sahits.codegen.wizards.MinimalArtifactDelegate
All Implemented Interfaces:
ICodeGeneratorDelegate, IInputObjectModel

public class MinimalArtifactDelegate
extends OutputFileModel
implements ICodeGeneratorDelegate

Delegate for the Artefact Generator for Headless use

Since:
2.1.0 TODO don't use the OutputfileModel directly
Author:
Andi Hotz

Constructor Summary
MinimalArtifactDelegate()
           
 
Method Summary
 int computeWorkload()
          Compute the workload for the model generation Any UI implementation must override this method
static MinimalArtifactDelegate convert(IOutputFileModel model)
          Convert an object of the superclass into an object of this class
 int getModelBase()
          This method is a wrapper method for #getInputMethod()
 IGeneratedObject initModel(IProgressMonitor monitor, IBasicDBDefinitionPage dbDefinitionPage)
          Delegate the generation of the model to BasicModelGenerator.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MinimalArtifactDelegate

public MinimalArtifactDelegate()
Method Detail

computeWorkload

public int computeWorkload()
Compute the workload for the model generation Any UI implementation must override this method

Specified by:
computeWorkload in interface ICodeGeneratorDelegate
Returns:
workload for the computation.

getModelBase

public final int getModelBase()
This method is a wrapper method for #getInputMethod()

Specified by:
getModelBase in interface ICodeGeneratorDelegate
Returns:
Constant from DynamicDBGenerationCode defining the input Method

initModel

public final IGeneratedObject initModel(IProgressMonitor monitor,
                                        IBasicDBDefinitionPage dbDefinitionPage)
                                 throws java.io.FileNotFoundException,
                                        java.io.IOException,
                                        java.lang.ClassNotFoundException
Delegate the generation of the model to BasicModelGenerator.

Specified by:
initModel in interface ICodeGeneratorDelegate
Parameters:
monitor - Progress monitor
dbDefinitionPage - current database definition page
Returns:
Instance of a generated Object
Throws:
java.io.FileNotFoundException - Input data file could not be found
java.io.IOException - Input data file could not be accessed
java.lang.ClassNotFoundException - Parser class could not be found

convert

public static MinimalArtifactDelegate convert(IOutputFileModel model)
Convert an object of the superclass into an object of this class

Parameters:
model - super class object
Returns:
Instance of this class