Class: AWSCDK::Logs::CfnDeliverySourceProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
logs/cfn_delivery_source_props.rb

Overview

Properties for defining a CfnDeliverySource.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, delivery_source_configuration: nil, log_type: nil, resource_arn: nil, tags: nil) ⇒ CfnDeliverySourceProps

Returns a new instance of CfnDeliverySourceProps.

Parameters:

  • name (String)

    The unique name of the delivery source.

  • delivery_source_configuration (AWSCDK::IResolvable, Hash{String => String}, nil) (defaults to: nil)

    A map of key-value pairs to configure the delivery source.

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

    The type of log that the source is sending.

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

    The ARN of the AWS resource that is generating and sending logs.

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

    An array of key-value pairs to apply to the delivery source.



14
15
16
17
18
19
20
21
22
23
24
25
# File 'logs/cfn_delivery_source_props.rb', line 14

def initialize(name:, delivery_source_configuration: nil, log_type: nil, resource_arn: nil, tags: nil)
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @delivery_source_configuration = delivery_source_configuration
  Jsii::Type.check_type(@delivery_source_configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsicHJpbWl0aXZlIjoic3RyaW5nIn0sImtpbmQiOiJtYXAifX1dfX0=")), "deliverySourceConfiguration") unless @delivery_source_configuration.nil?
  @log_type = log_type
  Jsii::Type.check_type(@log_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "logType") unless @log_type.nil?
  @resource_arn = resource_arn
  Jsii::Type.check_type(@resource_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "resourceArn") unless @resource_arn.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

#delivery_source_configurationAWSCDK::IResolvable, ... (readonly)

A map of key-value pairs to configure the delivery source.

Both keys and values must be between 1 and 255 characters in length.



38
39
40
# File 'logs/cfn_delivery_source_props.rb', line 38

def delivery_source_configuration
  @delivery_source_configuration
end

#log_typeString? (readonly)

The type of log that the source is sending.

For valid values for this parameter, see the documentation for the source service.



45
46
47
# File 'logs/cfn_delivery_source_props.rb', line 45

def log_type
  @log_type
end

#nameString (readonly)

The unique name of the delivery source.



31
32
33
# File 'logs/cfn_delivery_source_props.rb', line 31

def name
  @name
end

#resource_arnString? (readonly)

The ARN of the AWS resource that is generating and sending logs.

For example, arn:aws:workmail:us-east-1:123456789012:organization/m-1234EXAMPLEabcd1234abcd1234abcd1234



52
53
54
# File 'logs/cfn_delivery_source_props.rb', line 52

def resource_arn
  @resource_arn
end

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

An array of key-value pairs to apply to the delivery source.

For more information, see Tag .



59
60
61
# File 'logs/cfn_delivery_source_props.rb', line 59

def tags
  @tags
end

Class Method Details

.jsii_propertiesObject



61
62
63
64
65
66
67
68
69
# File 'logs/cfn_delivery_source_props.rb', line 61

def self.jsii_properties
  {
    :name => "name",
    :delivery_source_configuration => "deliverySourceConfiguration",
    :log_type => "logType",
    :resource_arn => "resourceArn",
    :tags => "tags",
  }
end

Instance Method Details

#to_jsiiObject



71
72
73
74
75
76
77
78
79
80
81
# File 'logs/cfn_delivery_source_props.rb', line 71

def to_jsii
  result = {}
  result.merge!({
    "name" => @name,
    "deliverySourceConfiguration" => @delivery_source_configuration,
    "logType" => @log_type,
    "resourceArn" => @resource_arn,
    "tags" => @tags,
  })
  result.compact
end