ScriptActivity Class

public class ScriptActivity
extends ExecutionActivity

Script activity type.

Constructor Summary

Constructor Description
ScriptActivity()

Creates an instance of ScriptActivity class.

Method Summary

Modifier and Type Method and Description
static ScriptActivity fromJson(JsonReader jsonReader)

Reads an instance of ScriptActivity from the JsonReader.

ScriptActivityTypePropertiesLogSettings getLogSettings()

Get the logSettings property: Log settings of script activity.

Object getReturnMultistatementResult()

Get the returnMultistatementResult property: Enable to retrieve result sets from multiple SQL statements and the number of rows affected by the DML statement.

Object getScriptBlockExecutionTimeout()

Get the scriptBlockExecutionTimeout property: ScriptBlock execution timeout.

List<ScriptActivityScriptBlock> getScripts()

Get the scripts property: Array of script blocks.

String getType()

Get the type property: Type of activity.

ScriptActivity setDependsOn(List<ActivityDependency> dependsOn)

Set the dependsOn property: Activity depends on condition.

ScriptActivity setDescription(String description)

Set the description property: Activity description.

ScriptActivity setLinkedServiceName(LinkedServiceReference linkedServiceName)

Set the linkedServiceName property: Linked service reference.

ScriptActivity setLogSettings(ScriptActivityTypePropertiesLogSettings logSettings)

Set the logSettings property: Log settings of script activity.

ScriptActivity setName(String name)

Set the name property: Activity name.

ScriptActivity setOnInactiveMarkAs(ActivityOnInactiveMarkAs onInactiveMarkAs)

Set the onInactiveMarkAs property: Status result of the activity when the state is set to Inactive.

ScriptActivity setPolicy(ActivityPolicy policy)

Set the policy property: Activity policy.

ScriptActivity setReturnMultistatementResult(Object returnMultistatementResult)

Set the returnMultistatementResult property: Enable to retrieve result sets from multiple SQL statements and the number of rows affected by the DML statement.

ScriptActivity setScriptBlockExecutionTimeout(Object scriptBlockExecutionTimeout)

Set the scriptBlockExecutionTimeout property: ScriptBlock execution timeout.

ScriptActivity setScripts(List<ScriptActivityScriptBlock> scripts)

Set the scripts property: Array of script blocks.

ScriptActivity setState(ActivityState state)

Set the state property: Activity state.

ScriptActivity setUserProperties(List<UserProperty> userProperties)

Set the userProperties property: Activity user properties.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from Activity

Methods inherited from ExecutionActivity

Methods inherited from java.lang.Object

Constructor Details

ScriptActivity

public ScriptActivity()

Creates an instance of ScriptActivity class.

Method Details

fromJson

public static ScriptActivity fromJson(JsonReader jsonReader)

Reads an instance of ScriptActivity from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of ScriptActivity if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

getLogSettings

public ScriptActivityTypePropertiesLogSettings getLogSettings()

Get the logSettings property: Log settings of script activity.

Returns:

the logSettings value.

getReturnMultistatementResult

public Object getReturnMultistatementResult()

Get the returnMultistatementResult property: Enable to retrieve result sets from multiple SQL statements and the number of rows affected by the DML statement. Supported connector: SnowflakeV2. Type: boolean (or Expression with resultType boolean).

Returns:

the returnMultistatementResult value.

getScriptBlockExecutionTimeout

public Object getScriptBlockExecutionTimeout()

Get the scriptBlockExecutionTimeout property: ScriptBlock execution timeout. Type: string (or Expression with resultType string), pattern: ((\d+)\.)?(\d\d):(60|([0-5][0-9])):(60|([0-5][0-9])).

Returns:

the scriptBlockExecutionTimeout value.

getScripts

public List<ScriptActivityScriptBlock> getScripts()

Get the scripts property: Array of script blocks. Type: array.

Returns:

the scripts value.

getType

public String getType()

Get the type property: Type of activity.

Overrides:

ScriptActivity.getType()

Returns:

the type value.

setDependsOn

public ScriptActivity setDependsOn(List<ActivityDependency> dependsOn)

Set the dependsOn property: Activity depends on condition.

Overrides:

ScriptActivity.setDependsOn(List<ActivityDependency> dependsOn)

Parameters:

dependsOn

setDescription

public ScriptActivity setDescription(String description)

Set the description property: Activity description.

Overrides:

ScriptActivity.setDescription(String description)

Parameters:

description

setLinkedServiceName

public ScriptActivity setLinkedServiceName(LinkedServiceReference linkedServiceName)

Set the linkedServiceName property: Linked service reference.

Overrides:

ScriptActivity.setLinkedServiceName(LinkedServiceReference linkedServiceName)

Parameters:

linkedServiceName

setLogSettings

public ScriptActivity setLogSettings(ScriptActivityTypePropertiesLogSettings logSettings)

Set the logSettings property: Log settings of script activity.

Parameters:

logSettings - the logSettings value to set.

Returns:

the ScriptActivity object itself.

setName

public ScriptActivity setName(String name)

Set the name property: Activity name.

Overrides:

ScriptActivity.setName(String name)

Parameters:

name

setOnInactiveMarkAs

public ScriptActivity setOnInactiveMarkAs(ActivityOnInactiveMarkAs onInactiveMarkAs)

Set the onInactiveMarkAs property: Status result of the activity when the state is set to Inactive. This is an optional property and if not provided when the activity is inactive, the status will be Succeeded by default.

Overrides:

ScriptActivity.setOnInactiveMarkAs(ActivityOnInactiveMarkAs onInactiveMarkAs)

Parameters:

onInactiveMarkAs

setPolicy

public ScriptActivity setPolicy(ActivityPolicy policy)

Set the policy property: Activity policy.

Overrides:

ScriptActivity.setPolicy(ActivityPolicy policy)

Parameters:

policy

setReturnMultistatementResult

public ScriptActivity setReturnMultistatementResult(Object returnMultistatementResult)

Set the returnMultistatementResult property: Enable to retrieve result sets from multiple SQL statements and the number of rows affected by the DML statement. Supported connector: SnowflakeV2. Type: boolean (or Expression with resultType boolean).

Parameters:

returnMultistatementResult - the returnMultistatementResult value to set.

Returns:

the ScriptActivity object itself.

setScriptBlockExecutionTimeout

public ScriptActivity setScriptBlockExecutionTimeout(Object scriptBlockExecutionTimeout)

Set the scriptBlockExecutionTimeout property: ScriptBlock execution timeout. Type: string (or Expression with resultType string), pattern: ((\d+)\.)?(\d\d):(60|([0-5][0-9])):(60|([0-5][0-9])).

Parameters:

scriptBlockExecutionTimeout - the scriptBlockExecutionTimeout value to set.

Returns:

the ScriptActivity object itself.

setScripts

public ScriptActivity setScripts(List<ScriptActivityScriptBlock> scripts)

Set the scripts property: Array of script blocks. Type: array.

Parameters:

scripts - the scripts value to set.

Returns:

the ScriptActivity object itself.

setState

public ScriptActivity setState(ActivityState state)

Set the state property: Activity state. This is an optional property and if not provided, the state will be Active by default.

Overrides:

ScriptActivity.setState(ActivityState state)

Parameters:

state

setUserProperties

public ScriptActivity setUserProperties(List<UserProperty> userProperties)

Set the userProperties property: Activity user properties.

Overrides:

ScriptActivity.setUserProperties(List<UserProperty> userProperties)

Parameters:

userProperties

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

ScriptActivity.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to