com.bowstreet.generation
Class GenerationManager

java.lang.Object
  extended by com.bowstreet.generation.GenerationManager

public class GenerationManager
extends java.lang.Object

GenerationManager is a Singleton which provides access to all the Generation operations. Note that this is after the caching of Generation results.


Field Summary
static java.lang.String HTTP_REQUEST
           
static java.lang.String MODEL_INSTANCE_CREATOR
           
 
Method Summary
static GenContainer generate(GenerationSource sourceModel, ProfileData profileData, boolean isDesignTime)
          Generate with the default phases, {"Construction", "PostConstruction", "Validation"}
static GenContainer generate(GenerationSource sourceModel, ProfileData profileData, boolean isDesignTime, GenContainer genContainer, com.bowstreet.generation.implementation.ProfileDataManager profileDataManager)
          Generate with the default phases, {"Construction", "PostConstruction", "Validation"} This version is used for runtime generation of new models
static GenContainer generate(GenerationSource sourceModel, ProfileData profileData, boolean isDesignTime, GenContainer genContainer, java.lang.String[] phaseArray)
          Generate with the phases you pass in.
static GenContainer generate(GenerationSource sourceModel, ProfileData profileData, java.util.List precedeList, java.util.List followList)
          Generate with the default phases, adding extra BuilderCalls
static boolean isGenerationActive()
          Is generation currently happening on this thread or one of its ancestors?
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HTTP_REQUEST

public static final java.lang.String HTTP_REQUEST
See Also:
Constant Field Values

MODEL_INSTANCE_CREATOR

public static final java.lang.String MODEL_INSTANCE_CREATOR
See Also:
Constant Field Values
Method Detail

generate

public static GenContainer generate(GenerationSource sourceModel,
                                    ProfileData profileData,
                                    boolean isDesignTime)
Generate with the default phases, {"Construction", "PostConstruction", "Validation"}

Parameters:
sourceModel - The Model to Generate
profileData - Profile Data to use for this Generation
isDesignTime - true if Builders should perform extra debugging and error checking tasks
Returns:
result of the Generation in the GenContainer

generate

public static GenContainer generate(GenerationSource sourceModel,
                                    ProfileData profileData,
                                    boolean isDesignTime,
                                    GenContainer genContainer,
                                    com.bowstreet.generation.implementation.ProfileDataManager profileDataManager)
Generate with the default phases, {"Construction", "PostConstruction", "Validation"} This version is used for runtime generation of new models

Parameters:
sourceModel - The Model to Generate
profileData - Profile Data to use for this Generation
isDesignTime - true if Builders should perform extra debugging and error checking tasks
genContainer - Use to pass in a pre-constructed genContainer. Can be null.
profileDataManager - Must be a valid ProfileDataManager
Returns:
result of the Generation in the GenContainer

generate

public static GenContainer generate(GenerationSource sourceModel,
                                    ProfileData profileData,
                                    boolean isDesignTime,
                                    GenContainer genContainer,
                                    java.lang.String[] phaseArray)
Generate with the phases you pass in. Note that if the first phase is not "Construction" then this will prepend that phase to your list. If the list itself is null or empty, then the default phases {"Construction", "PostConstruction", "Validation"} will be used.

Parameters:
sourceModel - The Model to Generate
profileData - Profile Data to use for this Generation
isDesignTime - true if Builders should perform extra debugging and error checking tasks
genContainer - Use to pass in a pre-constructed genContainer. Can be null.
phaseArray - Array of strings for the phases to call. "Construction" will be prepended if not first.
Returns:
result of the Generation in the GenContainer

generate

public static GenContainer generate(GenerationSource sourceModel,
                                    ProfileData profileData,
                                    java.util.List precedeList,
                                    java.util.List followList)
Generate with the default phases, adding extra BuilderCalls

Parameters:
sourceModel - The Model to Generate
profileData - Profile Data to use for this Generation
precedeList - A List of extra BuilderCalls
followList -
Returns:
result of the Generation in the GenContainer

isGenerationActive

public static boolean isGenerationActive()
Is generation currently happening on this thread or one of its ancestors?

Returns:
true if generation is active


Copyright © 2009 IBM. All Rights Reserved.