Class: Aws::Lex::Conversation::Type::SessionAttributes
- Inherits:
-
Hash
- Object
- Hash
- Aws::Lex::Conversation::Type::SessionAttributes
- Includes:
- Base
- Defined in:
- lib/aws/lex/conversation/type/session_attributes.rb
Instance Method Summary collapse
Methods included from Base
Instance Method Details
#checkpoints ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/aws/lex/conversation/type/session_attributes.rb', line 12 def checkpoints @checkpoints ||= JSON.parse( Base64.urlsafe_decode64(fetch(:checkpoints) { Base64.urlsafe_encode64([].to_json, padding: false) }) ).map do |checkpoint| Checkpoint.shrink_wrap(checkpoint) end end |
#to_lex ⇒ Object
20 21 22 23 24 |
# File 'lib/aws/lex/conversation/type/session_attributes.rb', line 20 def to_lex merge( checkpoints: Base64.urlsafe_encode64(checkpoints.map(&:to_lex).to_json, padding: false) ).to_h end |