Class: AWSCDK::IoT::CfnTopicRule::RepublishActionHeadersProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
io_t/cfn_topic_rule.rb

Overview

Specifies MQTT Version 5.0 headers information. For more information, see MQTT in the IoT Core Developer Guide.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(content_type: nil, correlation_data: nil, message_expiry: nil, payload_format_indicator: nil, response_topic: nil, user_properties: nil) ⇒ RepublishActionHeadersProperty

Returns a new instance of RepublishActionHeadersProperty.

Parameters:

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

    A UTF-8 encoded string that describes the content of the publishing message.

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

    The base64-encoded binary data used by the sender of the request message to identify which request the response message is for.

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

    A user-defined integer value that represents the message expiry interval at the broker.

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

    An Enum string value that indicates whether the payload is formatted as UTF-8.

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

    A UTF-8 encoded string that's used as the topic name for a response message.

  • user_properties (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::IoT::CfnTopicRule::UserPropertyProperty>, nil) (defaults to: nil)

    An array of key-value pairs that you define in the MQTT5 header.



2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
# File 'io_t/cfn_topic_rule.rb', line 2397

def initialize(content_type: nil, correlation_data: nil, message_expiry: nil, payload_format_indicator: nil, response_topic: nil, user_properties: nil)
  @content_type = content_type
  Jsii::Type.check_type(@content_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "contentType") unless @content_type.nil?
  @correlation_data = correlation_data
  Jsii::Type.check_type(@correlation_data, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "correlationData") unless @correlation_data.nil?
  @message_expiry = message_expiry
  Jsii::Type.check_type(@message_expiry, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "messageExpiry") unless @message_expiry.nil?
  @payload_format_indicator = payload_format_indicator
  Jsii::Type.check_type(@payload_format_indicator, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "payloadFormatIndicator") unless @payload_format_indicator.nil?
  @response_topic = response_topic
  Jsii::Type.check_type(@response_topic, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "responseTopic") unless @response_topic.nil?
  @user_properties = user_properties
  Jsii::Type.check_type(@user_properties, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfaW90LkNmblRvcGljUnVsZS5Vc2VyUHJvcGVydHlQcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "userProperties") unless @user_properties.nil?
end

Instance Attribute Details

#content_typeString? (readonly)

A UTF-8 encoded string that describes the content of the publishing message.

For more information, see Content Type in the MQTT Version 5.0 specification.

Supports substitution templates .



2420
2421
2422
# File 'io_t/cfn_topic_rule.rb', line 2420

def content_type
  @content_type
end

#correlation_dataString? (readonly)

The base64-encoded binary data used by the sender of the request message to identify which request the response message is for.

For more information, see Correlation Data in the MQTT Version 5.0 specification.

Supports substitution templates .

This binary data must be base64-encoded.



2431
2432
2433
# File 'io_t/cfn_topic_rule.rb', line 2431

def correlation_data
  @correlation_data
end

#message_expiryString? (readonly)

A user-defined integer value that represents the message expiry interval at the broker.

If the messages haven't been sent to the subscribers within that interval, the message expires and is removed. The value of message_expiry represents the number of seconds before it expires. For more information about the limits of message_expiry , see Message broker and protocol limits and quotas in the IoT Core Reference Guide.

Supports substitution templates .



2440
2441
2442
# File 'io_t/cfn_topic_rule.rb', line 2440

def message_expiry
  @message_expiry
end

#payload_format_indicatorString? (readonly)

An Enum string value that indicates whether the payload is formatted as UTF-8.

Valid values are UNSPECIFIED_BYTES and UTF8_DATA .

For more information, see Payload Format Indicator from the MQTT Version 5.0 specification.

Supports substitution templates .



2451
2452
2453
# File 'io_t/cfn_topic_rule.rb', line 2451

def payload_format_indicator
  @payload_format_indicator
end

#response_topicString? (readonly)

A UTF-8 encoded string that's used as the topic name for a response message.

The response topic is used to describe the topic to which the receiver should publish as part of the request-response flow. The topic must not contain wildcard characters.

For more information, see Response Topic in the MQTT Version 5.0 specification.

Supports substitution templates .



2462
2463
2464
# File 'io_t/cfn_topic_rule.rb', line 2462

def response_topic
  @response_topic
end

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

An array of key-value pairs that you define in the MQTT5 header.



2467
2468
2469
# File 'io_t/cfn_topic_rule.rb', line 2467

def user_properties
  @user_properties
end

Class Method Details

.jsii_propertiesObject



2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
# File 'io_t/cfn_topic_rule.rb', line 2469

def self.jsii_properties
  {
    :content_type => "contentType",
    :correlation_data => "correlationData",
    :message_expiry => "messageExpiry",
    :payload_format_indicator => "payloadFormatIndicator",
    :response_topic => "responseTopic",
    :user_properties => "userProperties",
  }
end

Instance Method Details

#to_jsiiObject



2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
# File 'io_t/cfn_topic_rule.rb', line 2480

def to_jsii
  result = {}
  result.merge!({
    "contentType" => @content_type,
    "correlationData" => @correlation_data,
    "messageExpiry" => @message_expiry,
    "payloadFormatIndicator" => @payload_format_indicator,
    "responseTopic" => @response_topic,
    "userProperties" => @user_properties,
  })
  result.compact
end