Class: AWSCDK::Macie::CfnFindingsFilterProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
macie/cfn_findings_filter_props.rb

Overview

Properties for defining a CfnFindingsFilter.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(finding_criteria:, name:, action: nil, description: nil, position: nil, tags: nil) ⇒ CfnFindingsFilterProps

Returns a new instance of CfnFindingsFilterProps.

Parameters:

  • finding_criteria (AWSCDK::IResolvable, AWSCDK::Macie::CfnFindingsFilter::FindingCriteriaProperty)

    The criteria to use to filter findings.

  • name (String)

    A custom name for the findings filter. The name can contain 3-64 characters.

  • action (String, nil) (defaults to: nil)

    The action to perform on findings that match the filter criteria ( FindingCriteria ). Valid values are:.

  • description (String, nil) (defaults to: nil)

    A custom description of the findings filter. The description can contain 1-512 characters.

  • position (Numeric, nil) (defaults to: nil)

    The position of the findings filter in the list of saved filter rules on the Amazon Macie console.

  • tags (Array<AWSCDK::CfnTag>, nil) (defaults to: nil)

    An array of key-value pairs to apply to the findings filter.



15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'macie/cfn_findings_filter_props.rb', line 15

def initialize(finding_criteria:, name:, action: nil, description: nil, position: nil, tags: nil)
  @finding_criteria = finding_criteria.is_a?(Hash) ? ::AWSCDK::Macie::CfnFindingsFilter::FindingCriteriaProperty.new(**finding_criteria.transform_keys(&:to_sym)) : finding_criteria
  Jsii::Type.check_type(@finding_criteria, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19tYWNpZS5DZm5GaW5kaW5nc0ZpbHRlci5GaW5kaW5nQ3JpdGVyaWFQcm9wZXJ0eSJ9XX19")), "findingCriteria")
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @action = action
  Jsii::Type.check_type(@action, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "action") unless @action.nil?
  @description = description
  Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil?
  @position = position
  Jsii::Type.check_type(@position, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "position") unless @position.nil?
  @tags = tags.is_a?(Array) ? tags.map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : tags
  Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil?
end

Instance Attribute Details

#actionString? (readonly)

The action to perform on findings that match the filter criteria ( FindingCriteria ). Valid values are:.

  • ARCHIVE - Suppress (automatically archive) the findings.
  • NOOP - Don't perform any action on the findings.


49
50
51
# File 'macie/cfn_findings_filter_props.rb', line 49

def action
  @action
end

#descriptionString? (readonly)

A custom description of the findings filter. The description can contain 1-512 characters.

Avoid including sensitive data in the description. Users of the account might be able to see the description, depending on the actions that they're allowed to perform in Amazon Macie .



56
57
58
# File 'macie/cfn_findings_filter_props.rb', line 56

def description
  @description
end

#finding_criteriaAWSCDK::IResolvable, AWSCDK::Macie::CfnFindingsFilter::FindingCriteriaProperty (readonly)

The criteria to use to filter findings.



34
35
36
# File 'macie/cfn_findings_filter_props.rb', line 34

def finding_criteria
  @finding_criteria
end

#nameString (readonly)

A custom name for the findings filter. The name can contain 3-64 characters.

Avoid including sensitive data in the name. Users of the account might be able to see the name, depending on the actions that they're allowed to perform in Amazon Macie .



41
42
43
# File 'macie/cfn_findings_filter_props.rb', line 41

def name
  @name
end

#positionNumeric? (readonly)

The position of the findings filter in the list of saved filter rules on the Amazon Macie console.

This value also determines the order in which the filter is applied to findings, relative to other filters that are also applied to findings.



63
64
65
# File 'macie/cfn_findings_filter_props.rb', line 63

def position
  @position
end

#tagsArray<AWSCDK::CfnTag>? (readonly)

An array of key-value pairs to apply to the findings filter.

For more information, see Resource tag .



70
71
72
# File 'macie/cfn_findings_filter_props.rb', line 70

def tags
  @tags
end

Class Method Details

.jsii_propertiesObject



72
73
74
75
76
77
78
79
80
81
# File 'macie/cfn_findings_filter_props.rb', line 72

def self.jsii_properties
  {
    :finding_criteria => "findingCriteria",
    :name => "name",
    :action => "action",
    :description => "description",
    :position => "position",
    :tags => "tags",
  }
end

Instance Method Details

#to_jsiiObject



83
84
85
86
87
88
89
90
91
92
93
94
# File 'macie/cfn_findings_filter_props.rb', line 83

def to_jsii
  result = {}
  result.merge!({
    "findingCriteria" => @finding_criteria,
    "name" => @name,
    "action" => @action,
    "description" => @description,
    "position" => @position,
    "tags" => @tags,
  })
  result.compact
end