Class: OpenPGP::Packet::EncryptedData

Inherits:
  • Object
show all
Defined in:
lib/openpgp/packet.rb

Overview

OpenPGP Symmetrically Encrypted Data packet (tag 9).

See Also:

Instance Attribute Summary (collapse)

Class Method Summary (collapse)

Instance Method Summary (collapse)

Methods inherited from

#body, for, parse, parse_new_format, parse_old_format, tag

Constructor Details

- (EncryptedData) initialize(options = {}, &block)

A new instance of EncryptedData



345
346
347
# File 'lib/openpgp/packet.rb', line 345

def initialize(options = {}, &block)
  super(options, &block)
end

Instance Attribute Details

- (Object) data

Returns the value of attribute data



339
340
341
# File 'lib/openpgp/packet.rb', line 339

def data
  @data
end

Class Method Details

+ (Object) parse_body(body, options = {})



341
342
343
# File 'lib/openpgp/packet.rb', line 341

def self.parse_body(body, options = {})
  self.new({:data => body.read}.merge(options))
end

Instance Method Details

- (Object) write_body(buffer)



349
350
351
# File 'lib/openpgp/packet.rb', line 349

def write_body(buffer)
  buffer.write(data)
end