Skip navigation links

Oracle® Data Integrator Java API Reference
11g Release 1 (11.1.1.6.0)

E17060-03


oracle.odi.domain.runtime.loadplan
Class OdiLoadPlan

java.lang.Object
  extended by oracle.odi.domain.support.BusinessObject
      extended by oracle.odi.domain.support.AbstractRepositoryEntity
          extended by oracle.odi.domain.support.AbstractOdiEntity
              extended by oracle.odi.domain.runtime.loadplan.OdiLoadPlan

All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, IFlexFieldUser, IExportable, IOdiEntity, IRepositoryEntity, IWorkRuntimeOdiEntity, ISmartExportable

public class OdiLoadPlan
extends oracle.odi.domain.support.AbstractOdiEntity
implements IWorkRuntimeOdiEntity, IExportable, IFlexFieldUser, ISmartExportable

An OdiLoadPlan is the root entity of the Load Plan aggregate.
Thus an instance of OdiLoadPlan controls the life cycle of every object of this aggregate and provides auditing information about it.
As such, it implements the IOdiEntity interface.

An OdiLoadPlan has an ID that can be obtained from getLoadPlanId() method call. This ID is assigned when an OdiLoadPlan is stored into the runtime repository.
This ID represents the identity of an OdiLoadPlan.
#equals() / AbstractOdiEntity.hashCode() methods are implemented according to this identity.

An OdiLoadPlan life cycle begins when a user creates an instance of this object. It is then stored inside ODI runtime repository.
The users can modify it in order to make it fit their needs.
The life cycle ends when a user deletes the instance from runtime repository (i.e. using IOdiEntityManager.remove()).

This class is offered to the user in order to create the objects so it mostly propose methods to build a load plan, add children components, etc?

Step moves:

Since:
11.1.1.5.0
See Also:
OdiLoadPlanStep, OdiLoadPlanVariable, OdiLoadPlanException, IOdiEntityManager, IOdiEntity, Serialized Form

Nested Class Summary
static class OdiLoadPlan.SessionLogsBehavior
          Indicates how logs will be maintained by default for the session of each of the scenarios started by the Load Plan.
static class OdiLoadPlan.SessionStepLogsBehavior
          Indicates how logs will be maintained by default for the session steps of each of the scenarios started by the Load Plan.

 

Field Summary
static int NAME_MAX_LENGTH
          Maximum length for the name of the OdiLoadPlan
static java.lang.String ROOT_STEP
          Name of the Root Step for the load plan
static int SESSION_KEYWORDS_MAX_LENGTH
          Maximum length for session keywords strings

 

Fields inherited from class oracle.odi.domain.support.AbstractOdiEntity
STARTING_INTERNAL_VERSION

 

Constructor Summary
OdiLoadPlan(java.lang.String pName)
          Create an OdiLoadPlan instance.
Creates a default root OdiLoadPlanStep.

 

Method Summary
 OdiLoadPlanException addException(java.lang.String pName)
          Creates an OdiLoadPlanException and adds it to the list of OdiLoadPlanException available for this OdiLoadPlan.
 OdiLoadPlanVariable addVariable(OdiVariable pVariable, IOdiVariableTextGenerator pGenerator)
          Calls the code generation service and creates an instance of OdiLoadPlanVariable from an OdiLoadPlanException.
adds the created OdiLoadPlanVariable to the list of OdiLoadPlanVariable available for this OdiLoadPlan and returns it.
If a OdiLoadPlanVariable corresponding to the parameter OdiVariable already exists, then the existing OdiLoadPlanVariable will be updated with the result of the code generation service.
If the created OdiLoadPlanVariable needs other Variables for its refresh, these OdiVariable will also be added to the Load Plan.
 java.lang.String getDescription()
           
 java.util.Collection<OdiLoadPlanException> getExceptions()
           
 java.util.Collection<IFlexFieldValue> getFlexFieldsValues()
          Obtains flex fields values related to this IFlexFieldUser.
 java.util.List<OdiLoadPlanInstance> getInstances()
           
 java.io.Serializable getInternalId()
          Provides a common getter for the persistence layer to obtain an identity, irrespective of the actual type of identity used.
 java.lang.Number getLoadPlanId()
           
 int getLogHistoryRetainedNbDays()
           
 java.lang.String getName()
          Returns the name of this entity instance.
 OdiLoadPlanStepSerial getRootStep()
           
 OdiScenarioFolder getScenarioFolder()
           
 IRepositoryEntity getSecurityContainer()
          Define a generic way to retrieve container for entities.
 java.lang.String getSessionKeywordsAsString()
           
 OdiLoadPlan.SessionLogsBehavior getSessionLogsDefaultBehaviorForScenarios()
          Indicates how logs will be maintained by default for the sessions of each of the scenarios started by the OdiLoadPlan.
 OdiLoadPlan.SessionStepLogsBehavior getSessionLogsDefaultBehaviorForScenarioSteps()
          Indicates how logs will be maintained by default for the session steps of each of the scenarios started by the Load Plan.
 int getTaskLogLevel()
           
 OdiLoadPlanVariable getVariableIfExistsInLoadPlan(java.lang.String pLoadPlanVariableName)
          Retrieve the OdiLoadPlanVariable if it exists in the LoadPlan
 java.util.List<OdiLoadPlanVariable> getVariables()
           
 void initFlexFields(IOdiFlexFieldFinder odiFlexFieldFinder)
          Initialize flex fields related to this IFlexFieldUser.
 void moveStepIntoStepContainer(OdiLoadPlanStep pStepToMove, OdiLoadPlanStepContainer pTargetContainer)
          Moves an OdiLoadPlanStep into a new step container and puts it at the end of the children list.
 void removeException(OdiLoadPlanException pLoadPlanStepException)
          Removes the given OdiLoadPlanException of the list of OdiLoadPlanException available for this OdiLoadPlan.
The OdiLoadPlanException must not be null and must have the same parent OdiLoadPlan.
 void removeVariable(OdiLoadPlanVariable pLoadPlanVariable)
          Removes the given OdiLoadPlanVariable of the list of OdiLoadPlanVariable available for this OdiLoadPlan.
If the variable is overridden on one or several steps, these usages will also be removed.
If the variable is used as a test variable in a StepCase, the step case and its hierarchy of steps will be removed.
The OdiLoadPlanVariable must not be null and must have the same parent OdiLoadPlan.
 void setDescription(java.lang.String pDescription)
           
 void setLogHistoryRetainedNbDays(int logHistoryRetainedNbDays)
           
 void setName(java.lang.String pName)
           
 void setScenarioFolder(OdiScenarioFolder pScenarioFolder)
           
 void setSessionKeywordsAsString(java.lang.String sessionKeywordsAsString)
           
 void setSessionLogsDefaultBehaviorForScenarios(OdiLoadPlan.SessionLogsBehavior sessionLogsDefaultBehaviorForScenarios)
          Indicates how logs will be maintained by default for the sessions of each of the scenarios started by the OdiLoadPlan.
Must not be null.
 void setSessionLogsDefaultBehaviorForScenarioSteps(OdiLoadPlan.SessionStepLogsBehavior sessionLogsDefaultBehaviorForScenarioSteps)
          Indicates how logs will be maintained by default for the session steps of each of the scenarios started by the Load Plan.
Must not be null
 void setTaskLogLevel(int taskLogLevel)
           

 

Methods inherited from class oracle.odi.domain.support.AbstractOdiEntity
equals, getFirstDate, getFirstUser, getInternalVersion, getLastDate, getLastUser, hashCode, isInstanceLevelSecurityNeeded, isNew, toString

 

Methods inherited from class oracle.odi.domain.support.BusinessObject
clone

 

Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait

 

Methods inherited from interface oracle.odi.domain.IOdiEntity
getFirstDate, getFirstUser, getLastDate, getLastUser, isInstanceLevelSecurityNeeded

 

Field Detail

NAME_MAX_LENGTH

public static final int NAME_MAX_LENGTH
Maximum length for the name of the OdiLoadPlan
See Also:
setName(String), getName(), name, Constant Field Values

SESSION_KEYWORDS_MAX_LENGTH

public static final int SESSION_KEYWORDS_MAX_LENGTH
Maximum length for session keywords strings
See Also:
sessionKeywordsAsString, getSessionKeywordsAsString(), setSessionKeywordsAsString(String), Constant Field Values

ROOT_STEP

public static final java.lang.String ROOT_STEP
Name of the Root Step for the load plan
See Also:
Constant Field Values

Constructor Detail

OdiLoadPlan

public OdiLoadPlan(java.lang.String pName)
Create an OdiLoadPlan instance.
Creates a default root OdiLoadPlanStep.
Parameters:
pName - the name of the OdiLoadPlan instances. Must not be null, empty or longer than NAME_MAX_LENGTH
Throws:
DomainRuntimeException - if the name is null, empty or longer than NAME_MAX_LENGTH

Method Detail

addException

public OdiLoadPlanException addException(java.lang.String pName)
Creates an OdiLoadPlanException and adds it to the list of OdiLoadPlanException available for this OdiLoadPlan.
Parameters:
pName - the name of the OdiLoadPlanException created.
Returns:
the OdiLoadPlanException instance created
See Also:
OdiLoadPlanException, removeException(OdiLoadPlanException), getExceptions()

removeException

public void removeException(OdiLoadPlanException pLoadPlanStepException)
Removes the given OdiLoadPlanException of the list of OdiLoadPlanException available for this OdiLoadPlan.
The OdiLoadPlanException must not be null and must have the same parent OdiLoadPlan.
Parameters:
pLoadPlanStepException - the OdiLoadPlanException to remove from the list
Throws:
DomainRuntimeException - if the exception is not defined in the load plan or is null
See Also:
OdiLoadPlanException, addException(String), getExceptions()

addVariable

public OdiLoadPlanVariable addVariable(OdiVariable pVariable,
                                       IOdiVariableTextGenerator pGenerator)
                                throws OdiVariableChangedDatatypeException,
                                       OdiVariableTextGeneratorException
Calls the code generation service and creates an instance of OdiLoadPlanVariable from an OdiLoadPlanException.
adds the created OdiLoadPlanVariable to the list of OdiLoadPlanVariable available for this OdiLoadPlan and returns it.
If a OdiLoadPlanVariable corresponding to the parameter OdiVariable already exists, then the existing OdiLoadPlanVariable will be updated with the result of the code generation service.
If the created OdiLoadPlanVariable needs other Variables for its refresh, these OdiVariable will also be added to the Load Plan.
Parameters:
pVariable - the source OdiVariable that will be used to create the OdiLoadPlanVariable. Must not be null.
pGenerator - the service in charge of the first step of code generation of the variable refresh sql text. Must not be null.
Returns:
the OdiLoadPlanVariable created.
Throws:
OdiVariableChangedDatatypeException - if we try to add again a variable whose datatype changed in between
OdiVariableTextGeneratorException - if variable refresh text generation failed
OdiRuntimeException - Context specific errors
DomainRuntimeException - if the variable and/or the generator is null
See Also:
OdiLoadPlanVariable, removeVariable(OdiLoadPlanVariable), getVariables(), OdiVariableTextGeneratorFactory

getVariableIfExistsInLoadPlan

public OdiLoadPlanVariable getVariableIfExistsInLoadPlan(java.lang.String pLoadPlanVariableName)
Retrieve the OdiLoadPlanVariable if it exists in the LoadPlan
Parameters:
pLoadPlanVariableName - fully qualified name for this variable
Returns:
OdiLoadPlanVariable

removeVariable

public void removeVariable(OdiLoadPlanVariable pLoadPlanVariable)
                    throws OdiLoadPlanVariableUsedException
Removes the given OdiLoadPlanVariable of the list of OdiLoadPlanVariable available for this OdiLoadPlan.
If the variable is overridden on one or several steps, these usages will also be removed.
If the variable is used as a test variable in a StepCase, the step case and its hierarchy of steps will be removed.
The OdiLoadPlanVariable must not be null and must have the same parent OdiLoadPlan.
Parameters:
pLoadPlanVariable -
Throws:
OdiLoadPlanVariableUsedException
{@link - IllegalArgumentException} if the LoadPlanVariable is null or not defined under the same loadplan
See Also:
OdiLoadPlanVariable, #addVariable(OdiVariable), getVariables()

setScenarioFolder

public void setScenarioFolder(OdiScenarioFolder pScenarioFolder)

getScenarioFolder

public OdiScenarioFolder getScenarioFolder()

getInternalId

public java.io.Serializable getInternalId()
Description copied from interface: IRepositoryEntity
Provides a common getter for the persistence layer to obtain an identity, irrespective of the actual type of identity used.

Typically a subclass will delegate to a public SomePrimitiveWrapper getId() method. The necessity for the getInternalId() abstract method is solely because the persistence layer needs a way of obtaining the identity irrespective of the actual identity implementation choice.

Returning null from this method will indicate the object has never been saved. This will likely be relied on by some DAO implementations.

Specified by:
getInternalId in interface IRepositoryEntity
Returns:
the persistence identity of this instance

getFlexFieldsValues

public java.util.Collection<IFlexFieldValue> getFlexFieldsValues()
Description copied from interface: IFlexFieldUser
Obtains flex fields values related to this IFlexFieldUser.
Specified by:
getFlexFieldsValues in interface IFlexFieldUser
Returns:
an unmodifiable Collection of flex field values

initFlexFields

public void initFlexFields(IOdiFlexFieldFinder odiFlexFieldFinder)
Description copied from interface: IFlexFieldUser
Initialize flex fields related to this IFlexFieldUser.
Specified by:
initFlexFields in interface IFlexFieldUser
Parameters:
odiFlexFieldFinder - OdiFlexField finder to be used to query flex fields

getRootStep

public OdiLoadPlanStepSerial getRootStep()
Returns:
the OdiLoadPlanStepSerial defined as root for this OdiLoadPlan.
See Also:
initializeRootStep()

getLoadPlanId

public java.lang.Number getLoadPlanId()
Returns:
the unique id of this OdiLoadPlan

getName

public java.lang.String getName()
Description copied from interface: IOdiEntity
Returns the name of this entity instance.
Specified by:
getName in interface IOdiEntity
Overrides:
getName in class oracle.odi.domain.support.AbstractOdiEntity
Returns:
the name of the OdiLoadPlan
See Also:
setName(String)

setName

public void setName(java.lang.String pName)
Parameters:
name - the name of the OdiLoadPlan. Its length must be lower or equal to NAME_MAX_LENGTH. Must not be null or empty.
Throws:
DomainRuntimeException - if the name is null, empty or longer than NAME_MAX_LENGTH
See Also:
getName(), NAME_MAX_LENGTH

getSessionKeywordsAsString

public java.lang.String getSessionKeywordsAsString()
Returns:
Comma separated list of keywords to propagate to the sessions.
See Also:
setSessionKeywordsAsString(String)

setSessionKeywordsAsString

public void setSessionKeywordsAsString(java.lang.String sessionKeywordsAsString)
Parameters:
sessionKeywordsAsString - Comma separated list of keywords to propagate to the sessions. Its length must be lower or equal to SESSION_KEYWORDS_MAX_LENGTH
Throws:
DomainRuntimeException - if the keywords are longer than the SESSION_KEYWORDS_MAX_LENGTH
See Also:
getSessionKeywordsAsString(), SESSION_KEYWORDS_MAX_LENGTH

getSessionLogsDefaultBehaviorForScenarios

public OdiLoadPlan.SessionLogsBehavior getSessionLogsDefaultBehaviorForScenarios()
Indicates how logs will be maintained by default for the sessions of each of the scenarios started by the OdiLoadPlan.
Returns:
the default behavior for logs for scenarios
See Also:
setSessionLogsDefaultBehaviorForScenarios(SessionLogsBehavior), OdiLoadPlan.SessionLogsBehavior

setSessionLogsDefaultBehaviorForScenarios

public void setSessionLogsDefaultBehaviorForScenarios(OdiLoadPlan.SessionLogsBehavior sessionLogsDefaultBehaviorForScenarios)
Indicates how logs will be maintained by default for the sessions of each of the scenarios started by the OdiLoadPlan.
Must not be null.
Parameters:
sessionLogsDefaultBehaviorForScenarios - the default behavior for scenario logs
Throws:
DomainRuntimeException - if the behavior is null.
See Also:
getSessionLogsDefaultBehaviorForScenarios(), OdiLoadPlan.SessionLogsBehavior

getSessionLogsDefaultBehaviorForScenarioSteps

public OdiLoadPlan.SessionStepLogsBehavior getSessionLogsDefaultBehaviorForScenarioSteps()
Indicates how logs will be maintained by default for the session steps of each of the scenarios started by the Load Plan.
Returns:
the default behavior for the session steps
See Also:
#setSessionLogsDefaultBehaviorForScenarioSteps(SessionLogsBehavior), OdiLoadPlan.SessionLogsBehavior

setSessionLogsDefaultBehaviorForScenarioSteps

public void setSessionLogsDefaultBehaviorForScenarioSteps(OdiLoadPlan.SessionStepLogsBehavior sessionLogsDefaultBehaviorForScenarioSteps)
Indicates how logs will be maintained by default for the session steps of each of the scenarios started by the Load Plan.
Must not be null
Parameters:
sessionLogsDefaultBehaviorForScenarioSteps - the default behavior for the session steps
Throws:
DomainRuntimeException - if the behavior is null
See Also:
getSessionLogsDefaultBehaviorForScenarioSteps(), OdiLoadPlan.SessionLogsBehavior

getLogHistoryRetainedNbDays

public int getLogHistoryRetainedNbDays()
Returns:
Number of days for which log history will be kept for this OdiLoadPlan.
See Also:
setLogHistoryRetainedNbDays(int)

setLogHistoryRetainedNbDays

public void setLogHistoryRetainedNbDays(int logHistoryRetainedNbDays)
Parameters:
logHistoryRetainedNbDays - Number of days for which log history will be kept for this OdiLoadPlan. It must be positive.
Throws:
DomainRuntimeException - if the number of days is negative.
See Also:
getLogHistoryRetainedNbDays()

getTaskLogLevel

public int getTaskLogLevel()
Returns:
the task level logging (1..5).
Note: When OdiLoadPlanStepRunScenario are configured as RestartType = RUN_SCENARIO_FROM_STEP or RUN_SCENARIO_FROM_TASK, this property is ignored.
See Also:
setTaskLogLevel(int)

setTaskLogLevel

public void setTaskLogLevel(int taskLogLevel)
Parameters:
taskLogLevel - the task level logging (1..5).
Note: When OdiLoadPlanStepRunScenario are configured as RestartType = RUN_SCENARIO_FROM_STEP or RUN_SCENARIO_FROM_TASK, this property is ignored.
Throws:
DomainRuntimeException - if the level is not between 1 and 5.
See Also:
getTaskLogLevel()

getDescription

public java.lang.String getDescription()
Returns:
the description of the OdiLoadPlan
See Also:
setDescription(String)

setDescription

public void setDescription(java.lang.String pDescription)
Parameters:
description - the description of the OdiLoadPlan
See Also:
getDescription()

getExceptions

public java.util.Collection<OdiLoadPlanException> getExceptions()
Returns:
the unmodifiable list of OdiLoadPlanException defined for this OdiLoadPlan

getInstances

public java.util.List<OdiLoadPlanInstance> getInstances()
Returns:
the unmodifable List of OdiLoadPlanInstance for this OdiLoadPlan

getVariables

public java.util.List<OdiLoadPlanVariable> getVariables()
Returns:
the unmodifiable list of OdiLoadPlanVariables defined for this OdiLoadPlan

moveStepIntoStepContainer

public void moveStepIntoStepContainer(OdiLoadPlanStep pStepToMove,
                                      OdiLoadPlanStepContainer pTargetContainer)
Moves an OdiLoadPlanStep into a new step container and puts it at the end of the children list.
Parameters:
pStepToMove -
pTargetContainer -
Throws:
DomainRuntimeException - if the step and the target container are not in the same loadplan
DomainRuntimeException - if moving a root step (LoadPlan root, caseWhen/CaseElse root step)
DomainRuntimeException - if moving a step from inside an exception to the loadplan hierarchy
DomainRuntimeException - if moving a step from the loadplan hierarchy to inside an exception

getSecurityContainer

public IRepositoryEntity getSecurityContainer()
Description copied from interface: IRepositoryEntity
Define a generic way to retrieve container for entities.
Specified by:
getSecurityContainer in interface IRepositoryEntity
Returns:
container entity

Skip navigation links

Oracle® Data Integrator Java API Reference
11g Release 1 (11.1.1.6.0)

E17060-03


Copyright © 2011, Oracle and/or its affiliates. All rights reserved.