SwitchActivity Class
- java.
lang. Object - com.
azure. resourcemanager. datafactory. models. Activity - com.
azure. resourcemanager. datafactory. models. ControlActivity - com.
azure. resourcemanager. datafactory. models. SwitchActivity
- com.
- com.
- com.
public final class SwitchActivity
extends ControlActivity
This activity evaluates an expression and executes activities under the cases property that correspond to the expression evaluation expected in the equals property.
Constructor Summary
| Constructor | Description |
|---|---|
| SwitchActivity() |
Creates an instance of Switch |
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
List<Switch |
cases()
Get the cases property: List of cases that correspond to expected values of the 'on' property. |
| List<Activity> |
defaultActivities()
Get the default |
|
static
Switch |
fromJson(JsonReader jsonReader)
Reads an instance of Switch |
| Expression |
on()
Get the on property: An expression that would evaluate to a string or integer. |
|
Json |
toJson(JsonWriter jsonWriter) |
| String |
type()
Get the type property: Type of activity. |
| void |
validate()
Validates the instance. |
|
Switch |
withCases(List<SwitchCase> cases)
Set the cases property: List of cases that correspond to expected values of the 'on' property. |
|
Switch |
withDefaultActivities(List<Activity> defaultActivities)
Set the default |
|
Switch |
withDependsOn(List<ActivityDependency> dependsOn)
Set the depends |
|
Switch |
withDescription(String description)
Set the description property: Activity description. |
|
Switch |
withName(String name)
Set the name property: Activity name. |
|
Switch |
withOn(Expression on)
Set the on property: An expression that would evaluate to a string or integer. |
|
Switch |
withOnInactiveMarkAs(ActivityOnInactiveMarkAs onInactiveMarkAs)
Set the on |
|
Switch |
withState(ActivityState state)
Set the state property: Activity state. |
|
Switch |
withUserProperties(List<UserProperty> userProperties)
Set the user |
Methods inherited from Activity
Methods inherited from ControlActivity
Methods inherited from java.lang.Object
Constructor Details
SwitchActivity
public SwitchActivity()
Creates an instance of SwitchActivity class.
Method Details
cases
public List<SwitchCase> cases()
Get the cases property: List of cases that correspond to expected values of the 'on' property. This is an optional property and if not provided, the activity will execute activities provided in defaultActivities.
Returns:
defaultActivities
public List<Activity> defaultActivities()
Get the defaultActivities property: List of activities to execute if no case condition is satisfied. This is an optional property and if not provided, the activity will exit without any action.
Returns:
fromJson
public static SwitchActivity fromJson(JsonReader jsonReader)
Reads an instance of SwitchActivity from the JsonReader.
Parameters:
Returns:
Throws:
on
public Expression on()
Get the on property: An expression that would evaluate to a string or integer. This is used to determine the block of activities in cases that will be executed.
Returns:
toJson
public JsonWriter toJson(JsonWriter jsonWriter)
Overrides:
SwitchActivity.toJson(JsonWriter jsonWriter)Parameters:
Throws:
type
public String type()
Get the type property: Type of activity.
Overrides:
SwitchActivity.type()Returns:
validate
public void validate()
Validates the instance.
Overrides:
SwitchActivity.validate()withCases
public SwitchActivity withCases(List<SwitchCase> cases)
Set the cases property: List of cases that correspond to expected values of the 'on' property. This is an optional property and if not provided, the activity will execute activities provided in defaultActivities.
Parameters:
Returns:
withDefaultActivities
public SwitchActivity withDefaultActivities(List<Activity> defaultActivities)
Set the defaultActivities property: List of activities to execute if no case condition is satisfied. This is an optional property and if not provided, the activity will exit without any action.
Parameters:
Returns:
withDependsOn
public SwitchActivity withDependsOn(List<ActivityDependency> dependsOn)
Set the dependsOn property: Activity depends on condition.
Overrides:
SwitchActivity.withDependsOn(List<ActivityDependency> dependsOn)Parameters:
withDescription
public SwitchActivity withDescription(String description)
Set the description property: Activity description.
Overrides:
SwitchActivity.withDescription(String description)Parameters:
withName
public SwitchActivity withName(String name)
Set the name property: Activity name.
Overrides:
SwitchActivity.withName(String name)Parameters:
withOn
public SwitchActivity withOn(Expression on)
Set the on property: An expression that would evaluate to a string or integer. This is used to determine the block of activities in cases that will be executed.
Parameters:
Returns:
withOnInactiveMarkAs
public SwitchActivity withOnInactiveMarkAs(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:
SwitchActivity.withOnInactiveMarkAs(ActivityOnInactiveMarkAs onInactiveMarkAs)Parameters:
withState
public SwitchActivity withState(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:
SwitchActivity.withState(ActivityState state)Parameters:
withUserProperties
public SwitchActivity withUserProperties(List<UserProperty> userProperties)
Set the userProperties property: Activity user properties.
Overrides:
SwitchActivity.withUserProperties(List<UserProperty> userProperties)Parameters: