com.informatica.powercenter.sdk.mapfwk.core
Class Transformation

java.lang.Object
  extended by com.informatica.powercenter.sdk.mapfwk.core.Table
      extended by com.informatica.powercenter.sdk.mapfwk.core.Transformation
All Implemented Interfaces:
Transform
Direct Known Subclasses:
AggregateTransformation, CustomTransformation, DSQTransformation, ExpTransformation, FilterTransformation, GenericTransformation, InputTransformation, JoinerTransformation, LookupTransformation, MappletTransformation, NormalizerTransformation, OutputTransformation, RankTransformation, RouterTransformation, SequenceGenTransformation, SorterTransformation, SQLTransformation, StoredProcTransformation, TransactionControlTransformation, UnconnectedLookup, UnionTransformation, UpdateStrategyTransformation

public abstract class Transformation
extends Table
implements Transform

Base class for all transformations that implement Transform interface.


Field Summary
protected  java.lang.Integer m_templateID
          template id for custom transformations
protected  java.lang.String m_templateName
          template name for custom transformations
protected  java.util.Vector m_transformFieldAttr
          Transformation attributes
protected  java.util.Properties sessionTransformInst
          Session transform instance property
 
Fields inherited from class com.informatica.powercenter.sdk.mapfwk.core.Table
m_bReusable, m_readOnly
 
Constructor Summary
Transformation()
          Default constructor
Transformation(int transformType)
          Constructor with transformation type
Transformation(java.lang.String name, java.lang.String busName, java.lang.String desc, java.lang.String instName, int type)
          Initialize the object with name, business name, description and instance name
 
Method Summary
 void add(OutputField field)
          Add a output field for this transformation
 void addInitProp(InitProp initProp)
          This methos adds an initprop object to the initprop vector
static java.lang.String defaultDuplicateNameRemovalSchema(java.lang.String str, java.util.Properties nameMapping)
          Returns a new name which is unique.
protected  OutputSet genOutputSet(java.util.Vector inputSet)
          Generate the OutputSet for a given Vector of InputSet
 java.util.Vector getGroupSet()
          Get the vector of Group objects
 java.util.Vector getInitProps()
          This method returns the vector of initprop objects
 Mapping getMapping()
          Get the mapping object
 java.util.Vector getOutFields()
          Return the Vector of OutputField objects
 OutputSet getOutputSet()
          Get the OutputSet object
 TransformationProperties getProperties()
          Get the appropriate properties object
 java.util.Enumeration getSessionTransformInstanceKeySet()
          Returns an enumeration of all the propertyNames that have been set as the session transform instance property.
 java.lang.String getSessionTransformInstanceProperty(java.lang.String propertyName)
          Get the session transform instance property.
 java.lang.Integer getTemplateID()
          This method returns the template ID
 java.lang.String getTemplateName()
          This method returns the template Name
 TransformationContext getTransContext()
          Get the transformation context object
 java.util.Vector getTransformationFieldAttr()
          returns the TransformationFieldAttrDefinition
 int getTransformationType()
          Return the transformation type
 java.util.Vector getTransformGroup()
          Get the vector of TransformGroup objects
 void setGroupSet(GroupSet groupSet)
           
 void setGroupSet(java.util.Vector groupSet)
          Set the vector groupSet objects
 void setMapping(Mapping mapping)
          This method sets the mapping
 void setOutFields(java.util.Vector outFields)
          Set the Vector of OutputField objects
 void setOutputSet(OutputSet rowSet)
          Set the RowSet object
 void setReusable(boolean trueFalse)
          Set reusable
 void setSessionTransformInstanceProperty(java.lang.String propertyName, java.lang.String propertyValue)
          Set the session instance property.
 void setTemplateIDAndName(java.lang.Integer id, java.lang.String name)
          This method sets the template ID and template name
 void setTransContext(TransformationContext transContext)
          Set the transformation context
 void setTransformationFieldAttr(java.util.Vector transFieldAttr)
          sets the TransformationFieldAttrDefinition
 void setTransformationType(int txType)
          Set the transformation type
 void setTransformGroup(java.util.Vector transformGroup)
          Set the vector of TransformGroup objects
static java.lang.String standardizeString(java.lang.String str)
          Get the standardised string which is supported by PowerCenter
 
Methods inherited from class com.informatica.powercenter.sdk.mapfwk.core.Table
addField, addMetaExtension, getBusinessName, getDescription, getField, getFields, getInstanceName, getMetaExtensions, getName, getReferencedField, isReadOnly, isReusable, removeField, removeMetaExtension, setBusinessName, setDescription, setFields, setInstanceName, setMetaExtensions, setMetaExtensionValue, setName, setReadOnly
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.informatica.powercenter.sdk.mapfwk.core.Transform
apply
 

Field Detail

m_templateID

protected java.lang.Integer m_templateID
template id for custom transformations


m_templateName

protected java.lang.String m_templateName
template name for custom transformations


m_transformFieldAttr

protected java.util.Vector m_transformFieldAttr
Transformation attributes


sessionTransformInst

protected java.util.Properties sessionTransformInst
Session transform instance property

Constructor Detail

Transformation

public Transformation()
Default constructor


Transformation

public Transformation(int transformType)
Constructor with transformation type

Parameters:
transformType - Transformation Type

Transformation

public Transformation(java.lang.String name,
                      java.lang.String busName,
                      java.lang.String desc,
                      java.lang.String instName,
                      int type)
Initialize the object with name, business name, description and instance name

Parameters:
name - name of the table
busName - business name
desc - description
type - transformation type
instName - instance name
Method Detail

getSessionTransformInstanceProperty

public java.lang.String getSessionTransformInstanceProperty(java.lang.String propertyName)
Get the session transform instance property. No validation is done. It is left to the user to make sure only valid properties are set.

Parameters:
propertyName - Property name
Returns:
String The property value if set, else returns null.

setSessionTransformInstanceProperty

public void setSessionTransformInstanceProperty(java.lang.String propertyName,
                                                java.lang.String propertyValue)
Set the session instance property.

Parameters:
propertyName - The property name to be set
propertyValue - The value of the property

getSessionTransformInstanceKeySet

public java.util.Enumeration getSessionTransformInstanceKeySet()
Returns an enumeration of all the propertyNames that have been set as the session transform instance property.

Returns:
Enumeration

getTransformationType

public int getTransformationType()
Return the transformation type

Specified by:
getTransformationType in interface Transform
Returns:
Returns the transformation type.

setTransformationType

public void setTransformationType(int txType)
Set the transformation type

Parameters:
txType - The transformation type to set.
See Also:
TransformationConstants

getOutputSet

public OutputSet getOutputSet()
Get the OutputSet object

Specified by:
getOutputSet in interface Transform
Returns:
Returns OutputSet.

setOutputSet

public void setOutputSet(OutputSet rowSet)
Set the RowSet object

Parameters:
rowSet - The RowSet to set.

getTransContext

public TransformationContext getTransContext()
Get the transformation context object

Returns:
Returns the Transformation Context.

setReusable

public void setReusable(boolean trueFalse)
Set reusable

Overrides:
setReusable in class Table
Parameters:
trueFalse - - flag to set reusability

getMapping

public Mapping getMapping()
Get the mapping object

Returns:
Returns the mapping object

setMapping

public void setMapping(Mapping mapping)
This method sets the mapping

Parameters:
mapping -

setTransContext

public void setTransContext(TransformationContext transContext)
Set the transformation context

Parameters:
transContext - The Transformation Context to set.

add

public void add(OutputField field)
Add a output field for this transformation

Specified by:
add in interface Transform
Parameters:
field - OutputField object

getOutFields

public java.util.Vector getOutFields()
Return the Vector of OutputField objects

Returns:
Returns the collection

setOutFields

public void setOutFields(java.util.Vector outFields)
Set the Vector of OutputField objects

Parameters:
outFields - The collection to set.

getGroupSet

public java.util.Vector getGroupSet()
Get the vector of Group objects

Returns:
the collection of GroupSet objects

setGroupSet

public void setGroupSet(java.util.Vector groupSet)
Set the vector groupSet objects

Parameters:
groupSet - Collection of GroupSet objects

setGroupSet

public void setGroupSet(GroupSet groupSet)

getProperties

public TransformationProperties getProperties()
Get the appropriate properties object

Specified by:
getProperties in interface Transform
Returns:
the TransformationProperties object

getTransformGroup

public java.util.Vector getTransformGroup()
Get the vector of TransformGroup objects

Returns:
Returns the vector of TransformGroup objects

setTransformGroup

public void setTransformGroup(java.util.Vector transformGroup)
Set the vector of TransformGroup objects

Parameters:
transformGroup - vector of TransformGroup objects

genOutputSet

protected OutputSet genOutputSet(java.util.Vector inputSet)
Generate the OutputSet for a given Vector of InputSet

Returns:
OutputSet object

addInitProp

public void addInitProp(InitProp initProp)
This methos adds an initprop object to the initprop vector

Parameters:
initProp -

getInitProps

public java.util.Vector getInitProps()
This method returns the vector of initprop objects

Returns:
vector of initprops

setTemplateIDAndName

public void setTemplateIDAndName(java.lang.Integer id,
                                 java.lang.String name)
This method sets the template ID and template name

Parameters:
id - TEmplate id of the custom transformation
name - template name of the transformation

getTemplateID

public java.lang.Integer getTemplateID()
This method returns the template ID

Returns:
template ID

getTemplateName

public java.lang.String getTemplateName()
This method returns the template Name

Returns:
template Name

getTransformationFieldAttr

public java.util.Vector getTransformationFieldAttr()
returns the TransformationFieldAttrDefinition

Returns:
returns the TransformationFieldAttrDefinition

setTransformationFieldAttr

public void setTransformationFieldAttr(java.util.Vector transFieldAttr)
sets the TransformationFieldAttrDefinition

Parameters:
transFieldAttr - sets the TransformationFieldAttrDefinition

standardizeString

public static java.lang.String standardizeString(java.lang.String str)
Get the standardised string which is supported by PowerCenter

Parameters:
str - String to be standardized
Returns:
String standardized String that will be supported in PowerCenter transformations

defaultDuplicateNameRemovalSchema

public static java.lang.String defaultDuplicateNameRemovalSchema(java.lang.String str,
                                                                 java.util.Properties nameMapping)
Returns a new name which is unique. Uses nameMapping as a reference for the names generated till that point.

Parameters:
str - String to be renamed in case of duplicate
nameMapping - For handling cases of generating unique names for multiple fields. This should contain a mapping between all the strings and standardized strings generated so far. If the standardized string vaue is present in the nameMapping a numeral is attached to the end of "_". For standardizing a single string, pass null.
Returns:
String renamed String which is unique.