Class: AWSCDK::Kinesis::StreamAttributes
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Kinesis::StreamAttributes
- Defined in:
- kinesis/stream_attributes.rb
Overview
A reference to a stream.
The easiest way to instantiate is to call
stream.export(). Then, the consumer can use Stream.import(this, ref) and
get a Stream.
Instance Attribute Summary collapse
-
#encryption_key ⇒ AWSCDK::KMS::IKey?
readonly
The KMS key securing the contents of the stream if encryption is enabled.
-
#stream_arn ⇒ String
readonly
The ARN of the stream.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(stream_arn:, encryption_key: nil) ⇒ StreamAttributes
constructor
A new instance of StreamAttributes.
- #to_jsii ⇒ Object
Constructor Details
#initialize(stream_arn:, encryption_key: nil) ⇒ StreamAttributes
Returns a new instance of StreamAttributes.
13 14 15 16 17 18 |
# File 'kinesis/stream_attributes.rb', line 13 def initialize(stream_arn:, encryption_key: nil) @stream_arn = stream_arn Jsii::Type.check_type(@stream_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "streamArn") @encryption_key = encryption_key Jsii::Type.check_type(@encryption_key, JSON.parse(Base64.strict_decode64("eyJmcW4iOiJhd3MtY2RrLWxpYi5hd3Nfa21zLklLZXkifQ==")), "encryptionKey") unless @encryption_key.nil? end |
Instance Attribute Details
#encryption_key ⇒ AWSCDK::KMS::IKey? (readonly)
Note:
Default: - No encryption
The KMS key securing the contents of the stream if encryption is enabled.
28 29 30 |
# File 'kinesis/stream_attributes.rb', line 28 def encryption_key @encryption_key end |
#stream_arn ⇒ String (readonly)
The ARN of the stream.
23 24 25 |
# File 'kinesis/stream_attributes.rb', line 23 def stream_arn @stream_arn end |
Class Method Details
.jsii_properties ⇒ Object
30 31 32 33 34 35 |
# File 'kinesis/stream_attributes.rb', line 30 def self.jsii_properties { :stream_arn => "streamArn", :encryption_key => "encryptionKey", } end |
Instance Method Details
#to_jsii ⇒ Object
37 38 39 40 41 42 43 44 |
# File 'kinesis/stream_attributes.rb', line 37 def to_jsii result = {} result.merge!({ "streamArn" => @stream_arn, "encryptionKey" => @encryption_key, }) result.compact end |