Class: StarkInfra::Certificate

Inherits:
StarkCore::Utils::SubResource
  • Object
show all
Defined in:
lib/pixdomain/certificate.rb

Overview

# PixDomain::Certificate object

The Certificate object displays the certificate information from a specific domain.

## Attributes (return-only):

  • content [string]: certificate of the Pix participant in PEM format.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(content: nil) ⇒ Certificate



15
16
17
# File 'lib/pixdomain/certificate.rb', line 15

def initialize(content: nil)
  @content = content
end

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content.



14
15
16
# File 'lib/pixdomain/certificate.rb', line 14

def content
  @content
end

Class Method Details

.resourceObject



19
20
21
22
23
24
25
26
27
28
# File 'lib/pixdomain/certificate.rb', line 19

def self.resource
  {
    resource_name: 'Certificate',
    resource_maker: proc { |json|
      Certificate.new(
        content: json['content']
      )
    }
  }
end