Class: Confium::Transparency::OTS::Receipt

Inherits:
Object
  • Object
show all
Defined in:
lib/confium/transparency/ots.rb

Overview

An OTS receipt proving that a hash was anchored in Bitcoin at a specific block height.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(bytes:, block_height: nil) ⇒ Receipt

Returns a new instance of Receipt.



28
29
30
31
# File 'lib/confium/transparency/ots.rb', line 28

def initialize(bytes:, block_height: nil)
  @bytes = bytes
  @block_height = block_height
end

Instance Attribute Details

#block_heightObject (readonly)

Returns the value of attribute block_height.



26
27
28
# File 'lib/confium/transparency/ots.rb', line 26

def block_height
  @block_height
end

#bytesObject (readonly)

Returns the value of attribute bytes.



26
27
28
# File 'lib/confium/transparency/ots.rb', line 26

def bytes
  @bytes
end

Instance Method Details

#to_bytesObject



33
34
35
# File 'lib/confium/transparency/ots.rb', line 33

def to_bytes
  @bytes
end