Class CfnComponent.ComponentConditionPropertyProperty
The ComponentConditionProperty
property specifies a conditional expression for setting a component property.
Inheritance
Namespace: Amazon.CDK.AWS.AmplifyUIBuilder
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ComponentConditionPropertyProperty : Object, CfnComponent.IComponentConditionPropertyProperty
Syntax (vb)
Public Class ComponentConditionPropertyProperty
Inherits Object
Implements CfnComponent.IComponentConditionPropertyProperty
Remarks
Use ComponentConditionProperty
to set a property to different values conditionally, based on the value of another property.
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.AmplifyUIBuilder;
ComponentConditionPropertyProperty componentConditionPropertyProperty_;
ComponentPropertyProperty componentPropertyProperty_;
var componentConditionPropertyProperty = new ComponentConditionPropertyProperty {
Else = new ComponentPropertyProperty {
BindingProperties = new ComponentPropertyBindingPropertiesProperty {
Property = "property",
// the properties below are optional
Field = "field"
},
Bindings = new Dictionary<string, object> {
{ "bindingsKey", new FormBindingElementProperty {
Element = "element",
Property = "property"
} }
},
CollectionBindingProperties = new ComponentPropertyBindingPropertiesProperty {
Property = "property",
// the properties below are optional
Field = "field"
},
ComponentName = "componentName",
Concat = new [] { componentPropertyProperty_ },
Condition = componentConditionPropertyProperty_,
Configured = false,
DefaultValue = "defaultValue",
Event = "event",
ImportedValue = "importedValue",
Model = "model",
Property = "property",
Type = "type",
UserAttribute = "userAttribute",
Value = "value"
},
Field = "field",
Operand = "operand",
OperandType = "operandType",
Operator = "operator",
Property = "property",
Then = new ComponentPropertyProperty {
BindingProperties = new ComponentPropertyBindingPropertiesProperty {
Property = "property",
// the properties below are optional
Field = "field"
},
Bindings = new Dictionary<string, object> {
{ "bindingsKey", new FormBindingElementProperty {
Element = "element",
Property = "property"
} }
},
CollectionBindingProperties = new ComponentPropertyBindingPropertiesProperty {
Property = "property",
// the properties below are optional
Field = "field"
},
ComponentName = "componentName",
Concat = new [] { componentPropertyProperty_ },
Condition = componentConditionPropertyProperty_,
Configured = false,
DefaultValue = "defaultValue",
Event = "event",
ImportedValue = "importedValue",
Model = "model",
Property = "property",
Type = "type",
UserAttribute = "userAttribute",
Value = "value"
}
};
Synopsis
Constructors
ComponentConditionPropertyProperty() |
Properties
Else | The value to assign to the property if the condition is not met. |
Field | The name of a field. |
Operand | The value of the property to evaluate. |
OperandType | The type of the property to evaluate. |
Operator | The operator to use to perform the evaluation, such as |
Property | The name of the conditional property. |
Then | The value to assign to the property if the condition is met. |
Constructors
ComponentConditionPropertyProperty()
public ComponentConditionPropertyProperty()
Properties
Else
The value to assign to the property if the condition is not met.
public object Else { get; set; }
Property Value
System.Object
Remarks
Field
The name of a field.
public string Field { get; set; }
Property Value
System.String
Remarks
Specify this when the property is a data model.
Operand
The value of the property to evaluate.
public string Operand { get; set; }
Property Value
System.String
Remarks
OperandType
The type of the property to evaluate.
public string OperandType { get; set; }
Property Value
System.String
Remarks
Operator
The operator to use to perform the evaluation, such as eq
to represent equals.
public string Operator { get; set; }
Property Value
System.String
Remarks
Property
The name of the conditional property.
public string Property { get; set; }
Property Value
System.String
Remarks
Then
The value to assign to the property if the condition is met.
public object Then { get; set; }
Property Value
System.Object