Skip navigation links

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

E17060-03


oracle.odi.domain.project
Class OdiPackage

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.project.OdiPackage

All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, IFlexFieldUser, IExportable, IOdiEntity, IRepositoryEntity, IWorkDevelopmentOdiEntity, IOdiScenarioSource, IOdiShortcutable<OdiPackage>, ISmartExportable

public class OdiPackage
extends oracle.odi.domain.support.AbstractOdiEntity
implements IOdiShortcutable<OdiPackage>, IOdiScenarioSource, IWorkDevelopmentOdiEntity, IExportable, IFlexFieldUser, ISmartExportable

Represents an ODI package.

An OdiPackage is a sequence of actions (Steps) to be build/generated into an OdiScenario for instance.

If a package is constructed with a reference object, the package will represented a shortcut to the reference object. When a package is used as a shortcut, most properties are accessed through the base object. The IOdiShortcutable interface implemented by OdiPackage provides access and control over the shortcut aspects of this object.

Since:
11.1.1.3.0
See Also:
Step, Serialized Form

Field Summary
static int NAME_MAX_LENGTH
          Maximum name length allowed.

 

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

 

Constructor Summary
OdiPackage(OdiFolder pFolder, java.lang.String pName)
          Constructor that sets the parentFolder and the name of the package.
OdiPackage(OdiFolder pFolder, java.lang.String pName, OdiPackage pReferencePackage)
          Constructor that sets the parentFolder, the name of the package, and the reference package.

 

Method Summary
 java.lang.String getDescription()
          Retrieves this OdiPackage instance description.
 Step getFirstStep()
          Returns the first step that has to be executed for this package.
 java.util.Collection<IFlexFieldValue> getFlexFieldsValues()
          Obtains flex fields values related to this IFlexFieldUser.
 java.io.Serializable getInternalId()
          Returns the internal identifier of this OdiPackage instance.
 java.lang.String getName()
          Retrieves this OdiPackage instance name.
 java.lang.Number getPackageId()
          Returns this OdiPackage instance's internal identifier.
 OdiFolder getParentFolder()
          Retrieves the parent OdiFolder of this OdiPackage instance.
 OdiPackage getRealObject()
          Return the real object associated with this object.
 IReleaseTag getReleaseTag()
          Return the release tag for this object.
 IRepositoryEntity getSecurityContainer()
          Define a generic way to retrieve container for entities.
 OdiPackage getShortcutBaseObject()
          Return the base object of this shortcutable.
 OdiPackage getShortcutOrigObject()
          If this is a shortcut, return the original base object
 OdiPackage getShortcutReferenceObject()
          If this is a shortcut, return the reference object.
 java.util.Collection<Step> getSteps()
          Obtains an unmodifiable collection of the steps of this package.
 void initFlexFields(IOdiFlexFieldFinder pOdiFlexFieldFinder)
          Initialize flex fields related to this IFlexFieldUser.
 boolean isInstanceLevelSecurityNeeded()
          Internal: this method is for internal purpose and must not be considered as part of the public API.
 boolean isShortcut()
          Returns true if this object is a shortcut.
 void removeStep(Step pStep)
          Remove the given step from this OdiPackage instance.
 void setDescription(java.lang.String pDescription)
          Set this OdiPackage instance description.
 void setFirstStep(Step pFirstStep)
          Defines the first step that will be executed within this package.
 void setName(java.lang.String pName)
          Sets the name of the package.
 boolean setShortcutBaseObject(OdiPackage pBaseObject)
          Internal Use Only.
 boolean setShortcutReferenceObject(OdiPackage pReferenceObject)
          Internal Use Only.

 

Methods inherited from class oracle.odi.domain.support.AbstractOdiEntity
equals, getFirstDate, getFirstUser, getInternalVersion, getLastDate, getLastUser, hashCode, 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

 

Field Detail

NAME_MAX_LENGTH

public static final int NAME_MAX_LENGTH
Maximum name length allowed.
See Also:
Constant Field Values

Constructor Detail

OdiPackage

public OdiPackage(OdiFolder pFolder,
                  java.lang.String pName,
                  OdiPackage pReferencePackage)
Constructor that sets the parentFolder, the name of the package, and the reference package. If pReferencePackage is not null, this object will is a package shortcut.
Parameters:
pFolder - enclosing folder
pName - package name
pReferencePackage - The reference datastore for this datastore shortcut.
Throws:
DomainRuntimeException - if folder is null. if the name is null, empty or longer than NAME_MAX_LENGTH.

OdiPackage

public OdiPackage(OdiFolder pFolder,
                  java.lang.String pName)
Constructor that sets the parentFolder and the name of the package.
Parameters:
pFolder - enclosing folder
pName - package name
Throws:
DomainRuntimeException - if folder is null. if the name is null, empty or longer than NAME_MAX_LENGTH.

Method Detail

getInternalId

public java.io.Serializable getInternalId()
Returns the internal identifier of this OdiPackage instance.
Specified by:
getInternalId in interface IRepositoryEntity
Returns:
the persistence identity of this instance
See Also:
getPackageId()

isInstanceLevelSecurityNeeded

public boolean isInstanceLevelSecurityNeeded()
Description copied from interface: IOdiEntity
Internal: this method is for internal purpose and must not be considered as part of the public API.

Defines a method to capture the info on which object needs instance level privilege.

Specified by:
isInstanceLevelSecurityNeeded in interface IOdiEntity
Overrides:
isInstanceLevelSecurityNeeded in class oracle.odi.domain.support.AbstractOdiEntity
Returns:
true if instance level security needed, false otherwise

setFirstStep

public void setFirstStep(Step pFirstStep)
Defines the first step that will be executed within this package.

Reset the previous first step, if any.

Parameters:
pFirstStep - the first step
Throws:
java.lang.IllegalStateException - if this is a shortcut. Use getRealObject to access.
See Also:
getFirstStep()

getFirstStep

public Step getFirstStep()
Returns the first step that has to be executed for this package.
Returns:
a Step object representing the first step value
Throws:
java.lang.IllegalStateException - if this is a shortcut. Use getRealObject to access.
See Also:
setFirstStep(oracle.odi.domain.project.Step)

removeStep

public void removeStep(Step pStep)
Remove the given step from this OdiPackage instance.

If the given step is the first one within this package, then that method will defines the first steps found into the steps' list of this package as first step to be executed.

All the Steps referencing the removed Step as NextStepOnFailure or NextStepOnSuccess will have these properties reset to null.

Steps are automatically added to the OdiPackage instance when using the constructor

Parameters:
pStep - the step to remove
Throws:
DomainRuntimeException - if the given step is not associated with this instance of OdiPackage or if the given step is null
java.lang.IllegalStateException - if this is a shortcut. Use getRealObject to access.

getDescription

public java.lang.String getDescription()
Retrieves this OdiPackage instance description.
Returns:
a String representing the description value
See Also:
setDescription(java.lang.String)

setDescription

public void setDescription(java.lang.String pDescription)
Set this OdiPackage instance description.
Parameters:
pDescription - the package description
See Also:
getDescription()

getName

public java.lang.String getName()
Retrieves this OdiPackage instance name.
Specified by:
getName in interface IOdiEntity
Overrides:
getName in class oracle.odi.domain.support.AbstractOdiEntity
Returns:
the name
See Also:
setName(java.lang.String)

setName

public void setName(java.lang.String pName)
Sets the name of the package. It can't be null or empty and must be not be longer than NAME_MAX_LENGTH.
Parameters:
pName - package name
Throws:
DomainRuntimeException - if the name is null, empty or longer than NAME_MAX_LENGTH
See Also:
getName()

getSteps

public java.util.Collection<Step> getSteps()
Obtains an unmodifiable collection of the steps of this package.
Returns:
a Collection object representing the steps value
Throws:
java.lang.IllegalStateException - if this is a shortcut. Use getRealObject to access.

getPackageId

public java.lang.Number getPackageId()
Returns this OdiPackage instance's internal identifier.
Returns:
a Number object representing the package id value

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

getParentFolder

public OdiFolder getParentFolder()
Retrieves the parent OdiFolder of this OdiPackage instance.
Returns:
an OdiFolder object representing the parent folder value

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
Since:
11.1.1.5.0

initFlexFields

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

getShortcutBaseObject

public OdiPackage getShortcutBaseObject()
Description copied from interface: IOdiShortcutable
Return the base object of this shortcutable.

This will return null if the object never has been a shortcut. If this object is a materialized shortcut, the base object will be the base object at the time that this was shortcuted.

Specified by:
getShortcutBaseObject in interface IOdiShortcutable<OdiPackage>
Returns:
T base object of this shortcut.

setShortcutBaseObject

public boolean setShortcutBaseObject(OdiPackage pBaseObject)
Description copied from interface: IOdiShortcutable
Internal Use Only. Set the base object of this shortcutable.

If the base object is changed, we should correct all consumers of this object.
This method may be called from a precedent shortcut object in the shortcut chain and the precedent shortcut obejct is removed or materialized.

Specified by:
setShortcutBaseObject in interface IOdiShortcutable<OdiPackage>
Parameters:
pBaseObject - new base object.
Returns:
true if this object was actually modified, else return false.

getShortcutReferenceObject

public OdiPackage getShortcutReferenceObject()
Description copied from interface: IOdiShortcutable
If this is a shortcut, return the reference object.

The reference object may also be a shortcut.

Specified by:
getShortcutReferenceObject in interface IOdiShortcutable<OdiPackage>
Returns:
T reference object of this shortcut.

setShortcutReferenceObject

public boolean setShortcutReferenceObject(OdiPackage pReferenceObject)
Description copied from interface: IOdiShortcutable
Internal Use Only. Set reference of this shortcut.

If pShortcutable is null, set pReference to null. This is no longer a shortcut.
If pShortcutable is not null, set the reference object to pShortcutable, set the base object to pShortcutable.getBaseObject.
This method may be called from a precedent shortcut object in the shortcut chain and the precedent shortcut obejct is removed or materialized.

Specified by:
setShortcutReferenceObject in interface IOdiShortcutable<OdiPackage>
Parameters:
pReferenceObject - new shortcutable object. Can be be null
Returns:
true if this object was actually modified. Else return false;

getShortcutOrigObject

public OdiPackage getShortcutOrigObject()
Description copied from interface: IOdiShortcutable
If this is a shortcut, return the original base object

The reference object may also be a shortcut.

Specified by:
getShortcutOrigObject in interface IOdiShortcutable<OdiPackage>
Returns:
T reference object of this shortcut.

isShortcut

public boolean isShortcut()
Description copied from interface: IOdiShortcutable
Returns true if this object is a shortcut.
Specified by:
isShortcut in interface IOdiShortcutable<OdiPackage>
Returns:
true if this object is a shortcut. Else return false.

getReleaseTag

public IReleaseTag getReleaseTag()
Description copied from interface: IOdiShortcutable
Return the release tag for this object.

release tag is actually maintained on the container object. This provides consistent access to the tag.

Specified by:
getReleaseTag in interface IOdiShortcutable<OdiPackage>
Returns:
Release tag of container object.

getRealObject

public OdiPackage getRealObject()
Description copied from interface: IOdiShortcutable
Return the real object associated with this object.

This is a convenience function to obtain the real object of a shortcutable object. If this object is a shortcut, return the base obejct. If this object is not a shortcut, return this object.

Specified by:
getRealObject in interface IOdiShortcutable<OdiPackage>
Returns:
Real object. The real object could be either this object or the base object.

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.