Module: Origami::Encryption::EncryptedObject

Included in:
EncryptedStream, EncryptedString
Defined in:
lib/origami/encryption.rb

Overview

Module for encrypted PDF objects.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#algorithm=(value) ⇒ Object (writeonly)

Sets the attribute algorithm

Parameters:

  • value

    the value to set the attribute algorithm to.



422
423
424
# File 'lib/origami/encryption.rb', line 422

def algorithm=(value)
  @algorithm = value
end

#decryptedObject

Returns the value of attribute decrypted.



424
425
426
# File 'lib/origami/encryption.rb', line 424

def decrypted
  @decrypted
end

#encryption_handler=(value) ⇒ Object (writeonly)

Sets the attribute encryption_handler

Parameters:

  • value

    the value to set the attribute encryption_handler to.



423
424
425
# File 'lib/origami/encryption.rb', line 423

def encryption_handler=(value)
  @encryption_handler = value
end

#encryption_key=(value) ⇒ Object (writeonly)

:nodoc



421
422
423
# File 'lib/origami/encryption.rb', line 421

def encryption_key=(value)
  @encryption_key = value
end

Class Method Details

.extended(obj) ⇒ Object



426
427
428
# File 'lib/origami/encryption.rb', line 426

def self.extended(obj)
  obj.decrypted = false
end

Instance Method Details

#post_buildObject



430
431
432
433
434
# File 'lib/origami/encryption.rb', line 430

def post_build
  encrypt!

  super
end