Class: AWSCDK::Codecommit::CfnRepository::RepositoryTriggerProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Codecommit::CfnRepository::RepositoryTriggerProperty
- Defined in:
- codecommit/cfn_repository.rb
Overview
Information about a trigger for a repository.
If you want to receive notifications about repository events, consider using notifications instead of triggers. For more information, see Configuring notifications for repository events .
Instance Attribute Summary collapse
-
#branches ⇒ Array<String>?
readonly
The branches to be included in the trigger configuration.
-
#custom_data ⇒ String?
readonly
Any custom data associated with the trigger to be included in the information sent to the target of the trigger.
-
#destination_arn ⇒ String
readonly
The ARN of the resource that is the target for a trigger (for example, the ARN of a topic in Amazon SNS).
-
#events ⇒ Array<String>
readonly
The repository events that cause the trigger to run actions in another service, such as sending a notification through Amazon SNS.
-
#name ⇒ String
readonly
The name of the trigger.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(destination_arn:, events:, name:, branches: nil, custom_data: nil) ⇒ RepositoryTriggerProperty
constructor
A new instance of RepositoryTriggerProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(destination_arn:, events:, name:, branches: nil, custom_data: nil) ⇒ RepositoryTriggerProperty
Returns a new instance of RepositoryTriggerProperty.
668 669 670 671 672 673 674 675 676 677 678 679 |
# File 'codecommit/cfn_repository.rb', line 668 def initialize(destination_arn:, events:, name:, branches: nil, custom_data: nil) @destination_arn = destination_arn Jsii::Type.check_type(@destination_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "destinationArn") @events = events Jsii::Type.check_type(@events, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "events") @name = name Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") @branches = branches Jsii::Type.check_type(@branches, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "branches") unless @branches.nil? @custom_data = custom_data Jsii::Type.check_type(@custom_data, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "customData") unless @custom_data.nil? end |
Instance Attribute Details
#branches ⇒ Array<String>? (readonly)
The branches to be included in the trigger configuration.
If you specify an empty array, the trigger applies to all branches.
Although no content is required in the array, you must include the array itself.
706 707 708 |
# File 'codecommit/cfn_repository.rb', line 706 def branches @branches end |
#custom_data ⇒ String? (readonly)
Any custom data associated with the trigger to be included in the information sent to the target of the trigger.
711 712 713 |
# File 'codecommit/cfn_repository.rb', line 711 def custom_data @custom_data end |
#destination_arn ⇒ String (readonly)
The ARN of the resource that is the target for a trigger (for example, the ARN of a topic in Amazon SNS).
685 686 687 |
# File 'codecommit/cfn_repository.rb', line 685 def destination_arn @destination_arn end |
#events ⇒ Array<String> (readonly)
The repository events that cause the trigger to run actions in another service, such as sending a notification through Amazon SNS.
The valid value "all" cannot be used with any other values.
692 693 694 |
# File 'codecommit/cfn_repository.rb', line 692 def events @events end |
#name ⇒ String (readonly)
The name of the trigger.
697 698 699 |
# File 'codecommit/cfn_repository.rb', line 697 def name @name end |
Class Method Details
.jsii_properties ⇒ Object
713 714 715 716 717 718 719 720 721 |
# File 'codecommit/cfn_repository.rb', line 713 def self.jsii_properties { :destination_arn => "destinationArn", :events => "events", :name => "name", :branches => "branches", :custom_data => "customData", } end |
Instance Method Details
#to_jsii ⇒ Object
723 724 725 726 727 728 729 730 731 732 733 |
# File 'codecommit/cfn_repository.rb', line 723 def to_jsii result = {} result.merge!({ "destinationArn" => @destination_arn, "events" => @events, "name" => @name, "branches" => @branches, "customData" => @custom_data, }) result.compact end |