class Aws::S3::Encryption::IODecrypter
@api private
Attributes
io[R]
@return [#write]
Public Class Methods
new(cipher, io)
click to toggle source
@param [OpenSSL::Cipher] cipher @param [IO#write] io An IO-like object that responds to `#write`.
# File lib/aws-sdk-resources/services/s3/encryption/io_decrypter.rb, line 9 def initialize(cipher, io) @cipher = cipher.clone @io = io end
Public Instance Methods
finalize()
click to toggle source
# File lib/aws-sdk-resources/services/s3/encryption/io_decrypter.rb, line 22 def finalize @io.write(@cipher.final) end
write(chunk)
click to toggle source
# File lib/aws-sdk-resources/services/s3/encryption/io_decrypter.rb, line 17 def write(chunk) # decrypt and write @io.write(@cipher.update(chunk)) end