Class: PkiExpress::CadesSignature
- Inherits:
-
Object
- Object
- PkiExpress::CadesSignature
- Defined in:
- lib/pki_express/cades_signature.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#encapsulated_content_type ⇒ Object
Returns the value of attribute encapsulated_content_type.
-
#has_encapsulated_content ⇒ Object
Returns the value of attribute has_encapsulated_content.
-
#signers ⇒ Object
Returns the value of attribute signers.
Instance Method Summary collapse
-
#initialize(model) ⇒ CadesSignature
constructor
A new instance of CadesSignature.
Constructor Details
#initialize(model) ⇒ CadesSignature
Returns a new instance of CadesSignature.
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/pki_express/cades_signature.rb', line 5 def initialize(model) @encapsulated_content_type = nil @has_encapsulated_content = nil @signers = [] unless model.nil? @encapsulated_content_type = model.fetch(:encapsulatedContentType) @has_encapsulated_content = model.fetch(:hasEncapsulatedContent) signers = model.fetch(:signers) if signers @signers = signers.map { |s| CadesSignerInfo.new(s) } end end end |
Instance Attribute Details
#encapsulated_content_type ⇒ Object
Returns the value of attribute encapsulated_content_type.
3 4 5 |
# File 'lib/pki_express/cades_signature.rb', line 3 def encapsulated_content_type @encapsulated_content_type end |
#has_encapsulated_content ⇒ Object
Returns the value of attribute has_encapsulated_content.
3 4 5 |
# File 'lib/pki_express/cades_signature.rb', line 3 def has_encapsulated_content @has_encapsulated_content end |
#signers ⇒ Object
Returns the value of attribute signers.
3 4 5 |
# File 'lib/pki_express/cades_signature.rb', line 3 def signers @signers end |