Class: Mpp::Methods::Tempo::Schemas::ProofCredentialPayload
- Inherits:
-
Data
- Object
- Data
- Mpp::Methods::Tempo::Schemas::ProofCredentialPayload
- Defined in:
- lib/mpp/methods/tempo/schemas.rb
Instance Attribute Summary collapse
-
#signature ⇒ Object
readonly
Returns the value of attribute signature.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(type:, signature:) ⇒ ProofCredentialPayload
constructor
A new instance of ProofCredentialPayload.
Constructor Details
#initialize(type:, signature:) ⇒ ProofCredentialPayload
Returns a new instance of ProofCredentialPayload.
69 70 71 72 73 74 |
# File 'lib/mpp/methods/tempo/schemas.rb', line 69 def initialize(type:, signature:) raise ArgumentError, "type must be 'proof'" unless type == "proof" raise ArgumentError, "signature must be a hex string" unless signature.match?(HEX_PATTERN) super end |
Instance Attribute Details
#signature ⇒ Object (readonly)
Returns the value of attribute signature
68 69 70 |
# File 'lib/mpp/methods/tempo/schemas.rb', line 68 def signature @signature end |
#type ⇒ Object (readonly)
Returns the value of attribute type
68 69 70 |
# File 'lib/mpp/methods/tempo/schemas.rb', line 68 def type @type end |