Show / Hide Table of Contents

Class Condition

A Condition for use in a Choice state branch.

Inheritance
object
Condition
Namespace: Amazon.CDK.AWS.StepFunctions
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public abstract class Condition : DeputyBase
Syntax (vb)
Public MustInherit Class Condition Inherits DeputyBase
Remarks

ExampleMetadata: infused

Examples
var map = new Map(this, "Map State", new MapProps {
                MaxConcurrency = 1,
                ItemsPath = JsonPath.StringAt("$.inputForMap"),
                ItemSelector = new Dictionary<string, object> {
                    { "item", JsonPath.StringAt("$.Map.Item.Value") }
                },
                ResultPath = "$.mapOutput"
            });

            // The Map iterator can contain a IChainable, which can be an individual or multiple steps chained together.
            // Below example is with a Choice and Pass step
            var choice = new Choice(this, "Choice");
            var condition1 = Condition.StringEquals("$.item.status", "SUCCESS");
            var step1 = new Pass(this, "Step1");
            var step2 = new Pass(this, "Step2");
            var finish = new Pass(this, "Finish");

            var definition = choice.When(condition1, step1).Otherwise(step2).Afterwards().Next(finish);

            map.ItemProcessor(definition);

Synopsis

Constructors

Condition()

A Condition for use in a Choice state branch.

Methods

And(params Condition[])

Combine two or more conditions with a logical AND.

BooleanEquals(string, bool)

Matches if a boolean field has the given value.

BooleanEqualsJsonPath(string, string)

Matches if a boolean field equals to a value at a given mapping path.

IsBoolean(string)

Matches if variable is boolean.

IsNotBoolean(string)

Matches if variable is not boolean.

IsNotNull(string)

Matches if variable is not null.

IsNotNumeric(string)

Matches if variable is not numeric.

IsNotPresent(string)

Matches if variable is not present.

IsNotString(string)

Matches if variable is not a string.

IsNotTimestamp(string)

Matches if variable is not a timestamp.

IsNull(string)

Matches if variable is Null.

IsNumeric(string)

Matches if variable is numeric.

IsPresent(string)

Matches if variable is present.

IsString(string)

Matches if variable is a string.

IsTimestamp(string)

Matches if variable is a timestamp.

Jsonata(string)

JSONata expression condition.

Not(Condition)

Negate a condition.

NumberEquals(string, double)

Matches if a numeric field has the given value.

NumberEqualsJsonPath(string, string)

Matches if a numeric field has the value in a given mapping path.

NumberGreaterThan(string, double)

Matches if a numeric field is greater than the given value.

NumberGreaterThanEquals(string, double)

Matches if a numeric field is greater than or equal to the given value.

NumberGreaterThanEqualsJsonPath(string, string)

Matches if a numeric field is greater than or equal to the value at a given mapping path.

NumberGreaterThanJsonPath(string, string)

Matches if a numeric field is greater than the value at a given mapping path.

NumberLessThan(string, double)

Matches if a numeric field is less than the given value.

NumberLessThanEquals(string, double)

Matches if a numeric field is less than or equal to the given value.

NumberLessThanEqualsJsonPath(string, string)

Matches if a numeric field is less than or equal to the numeric value at given mapping path.

NumberLessThanJsonPath(string, string)

Matches if a numeric field is less than the value at the given mapping path.

Or(params Condition[])

Combine two or more conditions with a logical OR.

RenderCondition()

Render Amazon States Language JSON for the condition.

StringEquals(string, string)

Matches if a string field has the given value.

StringEqualsJsonPath(string, string)

Matches if a string field equals to a value at a given mapping path.

StringGreaterThan(string, string)

Matches if a string field sorts after a given value.

StringGreaterThanEquals(string, string)

Matches if a string field sorts after or equal to a given value.

StringGreaterThanEqualsJsonPath(string, string)

Matches if a string field sorts after or equal to value at a given mapping path.

StringGreaterThanJsonPath(string, string)

Matches if a string field sorts after a value at a given mapping path.

StringLessThan(string, string)

Matches if a string field sorts before a given value.

StringLessThanEquals(string, string)

Matches if a string field sorts equal to or before a given value.

StringLessThanEqualsJsonPath(string, string)

Matches if a string field sorts equal to or before a given mapping.

StringLessThanJsonPath(string, string)

Matches if a string field sorts before a given value at a particular mapping.

StringMatches(string, string)

Matches if a field matches a string pattern that can contain a wild card () e.g: log-.txt or LATEST. No other characters other than "" have any special meaning - * can be escaped: \.

TimestampEquals(string, string)

Matches if a timestamp field is the same time as the given timestamp.

TimestampEqualsJsonPath(string, string)

Matches if a timestamp field is the same time as the timestamp at a given mapping path.

TimestampGreaterThan(string, string)

Matches if a timestamp field is after the given timestamp.

TimestampGreaterThanEquals(string, string)

Matches if a timestamp field is after or equal to the given timestamp.

TimestampGreaterThanEqualsJsonPath(string, string)

Matches if a timestamp field is after or equal to the timestamp at a given mapping path.

TimestampGreaterThanJsonPath(string, string)

Matches if a timestamp field is after the timestamp at a given mapping path.

TimestampLessThan(string, string)

Matches if a timestamp field is before the given timestamp.

TimestampLessThanEquals(string, string)

Matches if a timestamp field is before or equal to the given timestamp.

TimestampLessThanEqualsJsonPath(string, string)

Matches if a timestamp field is before or equal to the timestamp at a given mapping path.

TimestampLessThanJsonPath(string, string)

Matches if a timestamp field is before the timestamp at a given mapping path.

Constructors

Condition()

A Condition for use in a Choice state branch.

protected Condition()
Remarks

ExampleMetadata: infused

Examples
var map = new Map(this, "Map State", new MapProps {
                MaxConcurrency = 1,
                ItemsPath = JsonPath.StringAt("$.inputForMap"),
                ItemSelector = new Dictionary<string, object> {
                    { "item", JsonPath.StringAt("$.Map.Item.Value") }
                },
                ResultPath = "$.mapOutput"
            });

            // The Map iterator can contain a IChainable, which can be an individual or multiple steps chained together.
            // Below example is with a Choice and Pass step
            var choice = new Choice(this, "Choice");
            var condition1 = Condition.StringEquals("$.item.status", "SUCCESS");
            var step1 = new Pass(this, "Step1");
            var step2 = new Pass(this, "Step2");
            var finish = new Pass(this, "Finish");

            var definition = choice.When(condition1, step1).Otherwise(step2).Afterwards().Next(finish);

            map.ItemProcessor(definition);

Methods

And(params Condition[])

Combine two or more conditions with a logical AND.

public static Condition And(params Condition[] conditions)
Parameters
conditions Condition[]
Returns

Condition

Remarks

ExampleMetadata: infused

BooleanEquals(string, bool)

Matches if a boolean field has the given value.

public static Condition BooleanEquals(string variable, bool value)
Parameters
variable string
value bool
Returns

Condition

Remarks

ExampleMetadata: infused

BooleanEqualsJsonPath(string, string)

Matches if a boolean field equals to a value at a given mapping path.

public static Condition BooleanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

IsBoolean(string)

Matches if variable is boolean.

public static Condition IsBoolean(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNotBoolean(string)

Matches if variable is not boolean.

public static Condition IsNotBoolean(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNotNull(string)

Matches if variable is not null.

public static Condition IsNotNull(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNotNumeric(string)

Matches if variable is not numeric.

public static Condition IsNotNumeric(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNotPresent(string)

Matches if variable is not present.

public static Condition IsNotPresent(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNotString(string)

Matches if variable is not a string.

public static Condition IsNotString(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNotTimestamp(string)

Matches if variable is not a timestamp.

public static Condition IsNotTimestamp(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNull(string)

Matches if variable is Null.

public static Condition IsNull(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsNumeric(string)

Matches if variable is numeric.

public static Condition IsNumeric(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsPresent(string)

Matches if variable is present.

public static Condition IsPresent(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsString(string)

Matches if variable is a string.

public static Condition IsString(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

IsTimestamp(string)

Matches if variable is a timestamp.

public static Condition IsTimestamp(string variable)
Parameters
variable string
Returns

Condition

Remarks

ExampleMetadata: infused

Jsonata(string)

JSONata expression condition.

public static Condition Jsonata(string condition)
Parameters
condition string
Returns

Condition

Remarks

ExampleMetadata: infused

Not(Condition)

Negate a condition.

public static Condition Not(Condition condition)
Parameters
condition Condition
Returns

Condition

Remarks

ExampleMetadata: infused

NumberEquals(string, double)

Matches if a numeric field has the given value.

public static Condition NumberEquals(string variable, double value)
Parameters
variable string
value double
Returns

Condition

Remarks

ExampleMetadata: infused

NumberEqualsJsonPath(string, string)

Matches if a numeric field has the value in a given mapping path.

public static Condition NumberEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

NumberGreaterThan(string, double)

Matches if a numeric field is greater than the given value.

public static Condition NumberGreaterThan(string variable, double value)
Parameters
variable string
value double
Returns

Condition

Remarks

ExampleMetadata: infused

NumberGreaterThanEquals(string, double)

Matches if a numeric field is greater than or equal to the given value.

public static Condition NumberGreaterThanEquals(string variable, double value)
Parameters
variable string
value double
Returns

Condition

Remarks

ExampleMetadata: infused

NumberGreaterThanEqualsJsonPath(string, string)

Matches if a numeric field is greater than or equal to the value at a given mapping path.

public static Condition NumberGreaterThanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

NumberGreaterThanJsonPath(string, string)

Matches if a numeric field is greater than the value at a given mapping path.

public static Condition NumberGreaterThanJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

NumberLessThan(string, double)

Matches if a numeric field is less than the given value.

public static Condition NumberLessThan(string variable, double value)
Parameters
variable string
value double
Returns

Condition

Remarks

ExampleMetadata: infused

NumberLessThanEquals(string, double)

Matches if a numeric field is less than or equal to the given value.

public static Condition NumberLessThanEquals(string variable, double value)
Parameters
variable string
value double
Returns

Condition

Remarks

ExampleMetadata: infused

NumberLessThanEqualsJsonPath(string, string)

Matches if a numeric field is less than or equal to the numeric value at given mapping path.

public static Condition NumberLessThanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

NumberLessThanJsonPath(string, string)

Matches if a numeric field is less than the value at the given mapping path.

public static Condition NumberLessThanJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

Or(params Condition[])

Combine two or more conditions with a logical OR.

public static Condition Or(params Condition[] conditions)
Parameters
conditions Condition[]
Returns

Condition

Remarks

ExampleMetadata: infused

RenderCondition()

Render Amazon States Language JSON for the condition.

public abstract object RenderCondition()
Returns

object

Remarks

ExampleMetadata: infused

StringEquals(string, string)

Matches if a string field has the given value.

public static Condition StringEquals(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringEqualsJsonPath(string, string)

Matches if a string field equals to a value at a given mapping path.

public static Condition StringEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringGreaterThan(string, string)

Matches if a string field sorts after a given value.

public static Condition StringGreaterThan(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringGreaterThanEquals(string, string)

Matches if a string field sorts after or equal to a given value.

public static Condition StringGreaterThanEquals(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringGreaterThanEqualsJsonPath(string, string)

Matches if a string field sorts after or equal to value at a given mapping path.

public static Condition StringGreaterThanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringGreaterThanJsonPath(string, string)

Matches if a string field sorts after a value at a given mapping path.

public static Condition StringGreaterThanJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringLessThan(string, string)

Matches if a string field sorts before a given value.

public static Condition StringLessThan(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringLessThanEquals(string, string)

Matches if a string field sorts equal to or before a given value.

public static Condition StringLessThanEquals(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringLessThanEqualsJsonPath(string, string)

Matches if a string field sorts equal to or before a given mapping.

public static Condition StringLessThanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringLessThanJsonPath(string, string)

Matches if a string field sorts before a given value at a particular mapping.

public static Condition StringLessThanJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

StringMatches(string, string)

Matches if a field matches a string pattern that can contain a wild card () e.g: log-.txt or LATEST. No other characters other than "" have any special meaning - * can be escaped: \.

public static Condition StringMatches(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampEquals(string, string)

Matches if a timestamp field is the same time as the given timestamp.

public static Condition TimestampEquals(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampEqualsJsonPath(string, string)

Matches if a timestamp field is the same time as the timestamp at a given mapping path.

public static Condition TimestampEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampGreaterThan(string, string)

Matches if a timestamp field is after the given timestamp.

public static Condition TimestampGreaterThan(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampGreaterThanEquals(string, string)

Matches if a timestamp field is after or equal to the given timestamp.

public static Condition TimestampGreaterThanEquals(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampGreaterThanEqualsJsonPath(string, string)

Matches if a timestamp field is after or equal to the timestamp at a given mapping path.

public static Condition TimestampGreaterThanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampGreaterThanJsonPath(string, string)

Matches if a timestamp field is after the timestamp at a given mapping path.

public static Condition TimestampGreaterThanJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampLessThan(string, string)

Matches if a timestamp field is before the given timestamp.

public static Condition TimestampLessThan(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampLessThanEquals(string, string)

Matches if a timestamp field is before or equal to the given timestamp.

public static Condition TimestampLessThanEquals(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampLessThanEqualsJsonPath(string, string)

Matches if a timestamp field is before or equal to the timestamp at a given mapping path.

public static Condition TimestampLessThanEqualsJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

TimestampLessThanJsonPath(string, string)

Matches if a timestamp field is before the timestamp at a given mapping path.

public static Condition TimestampLessThanJsonPath(string variable, string value)
Parameters
variable string
value string
Returns

Condition

Remarks

ExampleMetadata: infused

Back to top Generated by DocFX