org.openbp.cockpit.generator
Class GeneratorSettings

java.lang.Object
  extended by org.openbp.cockpit.generator.GeneratorSettings
All Implemented Interfaces:
java.lang.Cloneable, Copyable, Validatable
Direct Known Subclasses:
ProcessEntrySettingsImpl

public class GeneratorSettings
extends java.lang.Object
implements java.lang.Cloneable, Copyable, Validatable

General settings object for a generator. This object may hold various information that is edited using a custom property browser page.

Author:
Heiko Erhardt

Field Summary
 
Fields inherited from interface org.openbp.common.generic.Copyable
COPY_DEEP, COPY_FIRST_LEVEL, COPY_SHALLOW
 
Constructor Summary
GeneratorSettings()
          Default constructor.
 
Method Summary
 void afterDeserialization(MsgContainer msgs)
          This template method is called after the settings object has been deserialized.
 void beforeSerialization()
          This template method is called before the settings object is being serialized.
 java.lang.Object clone()
          Creates a clone of this object.
 void copyFrom(java.lang.Object source, int copyMode)
          Copies the values of the source object to this object.
 java.lang.String getGeneratorName()
          Gets the generator name.
 Model getModel()
          Gets the model that will be used to resolve item references (e\.g\. data types).
 void setGeneratorName(java.lang.String generatorName)
          Sets the generator name.
 void setModel(Model model)
          Sets the model that will be used to resolve item references (e\.g\. data types).
 boolean validate(MsgContainer msgContainer)
          Checks if the object is valid.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GeneratorSettings

public GeneratorSettings()
Default constructor.

Method Detail

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Creates a clone of this object.

Specified by:
clone in interface Copyable
Overrides:
clone in class java.lang.Object
Returns:
The clone (a deep copy of this object)
Throws:
java.lang.CloneNotSupportedException - If the cloning of one of the contained members failed

copyFrom

public void copyFrom(java.lang.Object source,
                     int copyMode)
              throws java.lang.CloneNotSupportedException
Copies the values of the source object to this object.

Specified by:
copyFrom in interface Copyable
Parameters:
source - The source object. Must be of the same type as this object.
copyMode - Determines if a deep copy, a first level copy or a shallow copy is to be performed. See the constants of the org.openbp.common.generic.description.Copyable class.
Throws:
java.lang.CloneNotSupportedException - If the cloning of one of the contained objects failed

beforeSerialization

public void beforeSerialization()
This template method is called before the settings object is being serialized. It can be overridden to implement custom operations.


afterDeserialization

public void afterDeserialization(MsgContainer msgs)
This template method is called after the settings object has been deserialized. It can be overridden to implement custom initializations.

Parameters:
msgs - Container for error messages

validate

public boolean validate(MsgContainer msgContainer)
Checks if the object is valid.

Specified by:
validate in interface Validatable
Parameters:
msgContainer - Any errors will be logged to this message container
Returns:
true: The object is valid.
false: Errors were found within the object or its sub objects.

getGeneratorName

public java.lang.String getGeneratorName()
Gets the generator name.


setGeneratorName

public void setGeneratorName(java.lang.String generatorName)
Sets the generator name.


getModel

public Model getModel()
Gets the model that will be used to resolve item references (e\.g\. data types).


setModel

public void setModel(Model model)
Sets the model that will be used to resolve item references (e\.g\. data types).



Copyright © 2011. All Rights Reserved.