|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.taleo.integration.client.step.BaseStep
com.taleo.integration.client.step.BaseCustomStep
com.taleo.integration.client.customstep.BaseCustomStep
com.taleo.integration.client.customstep.db.SelectPreStep
public class SelectPreStep
This step executes a Select query on a database and sets the result as input to the TCC import process.
This step takes all parameters from its base class
BaseCustomStep
and the
following additional parameters:
queryFile
if the query is very short. If both
are present, this one has priority.This class is dependent on:
Here is an example of how to define this custom step in the TCC configuration file.
Field Summary |
---|
Fields inherited from class com.taleo.integration.client.customstep.BaseCustomStep |
---|
parameterNames |
Fields inherited from class com.taleo.integration.client.step.BaseCustomStep |
---|
parameters |
Fields inherited from class com.taleo.integration.client.step.BaseStep |
---|
commType, ERROR_NULL_GLOBAL_CONFIG, ERROR_NULL_PIPELINE, ERROR_NULL_STEP_CONFIG, productCode, tempFolder, type, version |
Constructor Summary | |
---|---|
SelectPreStep()
Constructor without arguments. |
Method Summary | |
---|---|
void |
execute(java.io.File outFile)
Execute the step and write result in the given file. |
void |
execute(com.taleo.ws.integration.client.Pipeline pipeline)
|
char |
getCsvDelimiter()
Get the CSV delimiter. |
char |
getCsvQuoteCharacter()
Get the CSV quote character. |
java.lang.String |
getDescription()
|
java.lang.String |
getDriverClassName()
Get the driver class name. |
java.lang.String |
getIdentifier()
|
java.lang.String |
getName()
|
java.lang.String |
getPassword()
Get the database password. |
java.lang.String |
getQuery()
Get the SQL query. |
java.lang.String |
getQueryFile()
Get the SQL query file. |
java.lang.String |
getSqlParameter(java.lang.String name)
Get the SQL parameter by its name. |
java.lang.String |
getUrl()
Get the database URL. |
java.lang.String |
getUsername()
Get the database user name. |
void |
init(com.taleo.ws.integration.client.GlobalConfig config)
|
boolean |
isCsvHeaderPresent()
Indicate if the CSV header is to be present. |
protected java.lang.String |
prepareQuery(java.lang.String query,
java.util.Properties parameters)
Prepare the query by stripping any ";" ending character and resolving named parameters. |
void |
setCsvDelimiter(char csvDelimiter)
Set the CSV delimiter. |
void |
setCsvHeaderPresent(boolean csvHeaderPresent)
Set if the CSV header is to be present. |
void |
setCsvQuoteCharacter(char csvQuoteCharacter)
Set the CSV quote character. |
void |
setDriverClassName(java.lang.String driverClassName)
Set the driver class name. |
void |
setPassword(java.lang.String password)
Set the database password. |
void |
setQuery(java.lang.String query)
Set the SQL query. |
void |
setQueryFile(java.lang.String queryFile)
Set the SQL query file. |
void |
setSqlParameter(java.lang.String name,
java.lang.String value)
Set the SQL parameter by its name. |
void |
setUrl(java.lang.String url)
Set the database URL. |
void |
setUsername(java.lang.String username)
Set the database user name. |
protected void |
validateParameterNames()
Validate the parameters names. |
Methods inherited from class com.taleo.integration.client.customstep.BaseCustomStep |
---|
createTempFile, createTempFile, getEncoding, getTempFolder, isActive, registerParameterName, setActive, setEncoding |
Methods inherited from class com.taleo.integration.client.step.BaseCustomStep |
---|
getSupportedPipeline, getType, init |
Methods inherited from class com.taleo.integration.client.step.BaseStep |
---|
getAllProcessSupportPipeline, getCurrentFile, getCurrentFile, getCurrentMessage, getPostProcessSupportPipeline, getPreProcessSupportPipeline, isOriginalFile, validateLastStepType, validateMessageType, validatePipeline |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.taleo.integration.client.step.Step |
---|
validatePipeline |
Constructor Detail |
---|
public SelectPreStep()
Method Detail |
---|
protected void validateParameterNames()
Override the default method to allow for extra parameters to be passed to the SQL query.
validateParameterNames
in class BaseCustomStep
public java.lang.String getIdentifier()
getIdentifier
in interface com.taleo.integration.client.step.CustomStep
getIdentifier
in interface com.taleo.integration.client.step.Step
getIdentifier
in class com.taleo.integration.client.step.BaseCustomStep
public java.lang.String getDescription()
getDescription
in interface com.taleo.integration.client.step.CustomStep
getDescription
in interface com.taleo.integration.client.step.Step
getDescription
in class com.taleo.integration.client.step.BaseCustomStep
public java.lang.String getName()
getName
in interface com.taleo.integration.client.step.CustomStep
getName
in interface com.taleo.integration.client.step.Step
getName
in class com.taleo.integration.client.step.BaseCustomStep
public java.lang.String getQuery()
public void setQuery(java.lang.String query)
query
- public java.lang.String getQueryFile()
public void setQueryFile(java.lang.String queryFile)
queryFile
- public java.lang.String getDriverClassName()
public void setDriverClassName(java.lang.String driverClassName)
driverClassName
- public java.lang.String getUrl()
public void setUrl(java.lang.String url)
url
- public java.lang.String getUsername()
public void setUsername(java.lang.String username)
username
- public java.lang.String getPassword()
public void setPassword(java.lang.String password)
password
- public char getCsvDelimiter()
public void setCsvDelimiter(char csvDelimiter)
csvDelimiter
- public boolean isCsvHeaderPresent()
public void setCsvHeaderPresent(boolean csvHeaderPresent)
csvHeaderPresent
- public char getCsvQuoteCharacter()
public void setCsvQuoteCharacter(char csvQuoteCharacter)
csvQuoteCharacter
- public java.lang.String getSqlParameter(java.lang.String name)
name
-
public void setSqlParameter(java.lang.String name, java.lang.String value)
name
- value
- public void init(com.taleo.ws.integration.client.GlobalConfig config)
init
in class BaseCustomStep
public void execute(com.taleo.ws.integration.client.Pipeline pipeline) throws com.taleo.integration.client.step.StepException
com.taleo.integration.client.step.StepException
public void execute(java.io.File outFile) throws java.lang.Exception
java.lang.Exception
protected java.lang.String prepareQuery(java.lang.String query, java.util.Properties parameters)
query
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |