Class: AWSCDK::Datasync::CfnTask::FilterRuleProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
datasync/cfn_task.rb

Overview

Specifies which files, folders, and objects to include or exclude when transferring files from source to destination.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(filter_type: nil, value: nil) ⇒ FilterRuleProperty

Returns a new instance of FilterRuleProperty.

Parameters:

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

    The type of filter rule to apply.

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

    A single filter string that consists of the patterns to include or exclude.



759
760
761
762
763
764
# File 'datasync/cfn_task.rb', line 759

def initialize(filter_type: nil, value: nil)
  @filter_type = filter_type
  Jsii::Type.check_type(@filter_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "filterType") unless @filter_type.nil?
  @value = value
  Jsii::Type.check_type(@value, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "value") unless @value.nil?
end

Instance Attribute Details

#filter_typeString? (readonly)

The type of filter rule to apply.

AWS DataSync only supports the SIMPLE_PATTERN rule type.



772
773
774
# File 'datasync/cfn_task.rb', line 772

def filter_type
  @filter_type
end

#valueString? (readonly)

A single filter string that consists of the patterns to include or exclude.

The patterns are delimited by "|" (that is, a pipe), for example: /folder1|/folder2



779
780
781
# File 'datasync/cfn_task.rb', line 779

def value
  @value
end

Class Method Details

.jsii_propertiesObject



781
782
783
784
785
786
# File 'datasync/cfn_task.rb', line 781

def self.jsii_properties
  {
    :filter_type => "filterType",
    :value => "value",
  }
end

Instance Method Details

#to_jsiiObject



788
789
790
791
792
793
794
795
# File 'datasync/cfn_task.rb', line 788

def to_jsii
  result = {}
  result.merge!({
    "filterType" => @filter_type,
    "value" => @value,
  })
  result.compact
end