@Generated(value="jsii-pacmak/1.74.0 (build 6d08790)", date="2023-03-22T19:35:35.630Z") public class CfnRule extends CfnResource implements IInspectable
Creates a rule for the specified Amazon Connect instance.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.connect.*; Object assignContactCategoryActions; CfnRule cfnRule = CfnRule.Builder.create(this, "MyCfnRule") .actions(ActionsProperty.builder() .assignContactCategoryActions(List.of(assignContactCategoryActions)) .eventBridgeActions(List.of(EventBridgeActionProperty.builder() .name("name") .build())) .sendNotificationActions(List.of(SendNotificationActionProperty.builder() .content("content") .contentType("contentType") .deliveryMethod("deliveryMethod") .recipient(NotificationRecipientTypeProperty.builder() .userArns(List.of("userArns")) .userTags(Map.of( "userTagsKey", "userTags")) .build()) // the properties below are optional .subject("subject") .build())) .taskActions(List.of(TaskActionProperty.builder() .contactFlowArn("contactFlowArn") .name("name") // the properties below are optional .description("description") .references(Map.of( "referencesKey", ReferenceProperty.builder() .type("type") .value("value") .build())) .build())) .build()) .function("function") .instanceArn("instanceArn") .name("name") .publishStatus("publishStatus") .triggerEventSource(RuleTriggerEventSourceProperty.builder() .eventSourceName("eventSourceName") // the properties below are optional .integrationAssociationArn("integrationAssociationArn") .build()) // the properties below are optional .tags(List.of(CfnTag.builder() .key("key") .value("value") .build())) .build();
Modifier and Type | Class and Description |
---|---|
static interface |
CfnRule.ActionsProperty
A list of actions to be run when the rule is triggered.
|
static class |
CfnRule.Builder
A fluent builder for
CfnRule . |
static interface |
CfnRule.EventBridgeActionProperty
The EventBridge action definition.
|
static interface |
CfnRule.NotificationRecipientTypeProperty
The type of notification recipient.
|
static interface |
CfnRule.ReferenceProperty
Information about the reference when the `referenceType` is `URL` .
|
static interface |
CfnRule.RuleTriggerEventSourceProperty
The name of the event source.
|
static interface |
CfnRule.SendNotificationActionProperty
Information about the send notification action.
|
static interface |
CfnRule.TaskActionProperty
Information about the task action.
|
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
IConstruct.Jsii$Default
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
Modifier | Constructor and Description |
---|---|
|
CfnRule(Construct scope,
java.lang.String id,
CfnRuleProps props)
Create a new `AWS::Connect::Rule`.
|
protected |
CfnRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnRule(software.amazon.jsii.JsiiObjectRef objRef) |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getActions()
A list of actions to be run when the rule is triggered.
|
java.lang.String |
getAttrRuleArn()
The Amazon Resource Name (ARN) of the rule.
|
protected java.util.Map<java.lang.String,java.lang.Object> |
getCfnProperties() |
java.lang.String |
getFunction()
The conditions of the rule.
|
java.lang.String |
getInstanceArn()
The Amazon Resource Name (ARN) of the instance.
|
java.lang.String |
getName()
The name of the rule.
|
java.lang.String |
getPublishStatus()
The publish status of the rule.
|
TagManager |
getTags()
The tags used to organize, track, or control access for this resource.
|
java.lang.Object |
getTriggerEventSource()
The event source to trigger the rule.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected java.util.Map<java.lang.String,java.lang.Object> |
renderProperties(java.util.Map<java.lang.String,java.lang.Object> props) |
void |
setActions(CfnRule.ActionsProperty value)
A list of actions to be run when the rule is triggered.
|
void |
setActions(IResolvable value)
A list of actions to be run when the rule is triggered.
|
void |
setFunction(java.lang.String value)
The conditions of the rule.
|
void |
setInstanceArn(java.lang.String value)
The Amazon Resource Name (ARN) of the instance.
|
void |
setName(java.lang.String value)
The name of the rule.
|
void |
setPublishStatus(java.lang.String value)
The publish status of the rule.
|
void |
setTriggerEventSource(CfnRule.RuleTriggerEventSourceProperty value)
The event source to trigger the rule.
|
void |
setTriggerEventSource(IResolvable value)
The event source to trigger the rule.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validateProperties
getRef
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
public static final java.lang.String CFN_RESOURCE_TYPE_NAME
protected CfnRule(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnRule(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
public CfnRule(Construct scope, java.lang.String id, CfnRuleProps props)
scope
- - scope in which this resource is defined. This parameter is required.id
- - scoped id of the resource. This parameter is required.props
- - resource properties. This parameter is required.public void inspect(TreeInspector inspector)
inspect
in interface IInspectable
inspector
- - tree inspector to collect and process attributes. This parameter is required.protected java.util.Map<java.lang.String,java.lang.Object> renderProperties(java.util.Map<java.lang.String,java.lang.Object> props)
renderProperties
in class CfnResource
props
- This parameter is required.public java.lang.String getAttrRuleArn()
protected java.util.Map<java.lang.String,java.lang.Object> getCfnProperties()
getCfnProperties
in class CfnResource
public TagManager getTags()
For example, { "tags": {"key1":"value1", "key2":"value2"} }.
public java.lang.Object getActions()
public void setActions(IResolvable value)
public void setActions(CfnRule.ActionsProperty value)
public java.lang.String getFunction()
public void setFunction(java.lang.String value)
public java.lang.String getInstanceArn()
public void setInstanceArn(java.lang.String value)
public java.lang.String getName()
public void setName(java.lang.String value)
public java.lang.String getPublishStatus()
Allowed values : DRAFT
| PUBLISHED
public void setPublishStatus(java.lang.String value)
Allowed values : DRAFT
| PUBLISHED
public java.lang.Object getTriggerEventSource()
public void setTriggerEventSource(IResolvable value)
public void setTriggerEventSource(CfnRule.RuleTriggerEventSourceProperty value)