Class: Casper::Entity::BlockBody
- Inherits:
-
Object
- Object
- Casper::Entity::BlockBody
- Defined in:
- lib/entity/block_body.rb
Overview
BlockBody entity
Instance Method Summary collapse
-
#get_deploy_hashes ⇒ Array
Hex-encoded Deploy hashes.
-
#get_proposer ⇒ String
A hex-encoded cryptographic public key, including the algorithm tag prefix.
-
#get_transfer_hashes ⇒ Array
A vector of hex-encoded hashes identifying Transfers included in this block.
-
#initialize(body = {}) ⇒ BlockBody
constructor
A new instance of BlockBody.
Constructor Details
#initialize(body = {}) ⇒ BlockBody
Returns a new instance of BlockBody.
10 11 12 13 14 |
# File 'lib/entity/block_body.rb', line 10 def initialize(body = {}) @proposer = body[:proposer] @deploy_hashes = body[:deploy_hashes] @transfer_hashes = body[:transfer_hashes] end |
Instance Method Details
#get_deploy_hashes ⇒ Array
Returns hex-encoded Deploy hashes.
23 24 25 |
# File 'lib/entity/block_body.rb', line 23 def get_deploy_hashes @deploy_hashes end |
#get_proposer ⇒ String
Returns a hex-encoded cryptographic public key, including the algorithm tag prefix.
18 19 20 |
# File 'lib/entity/block_body.rb', line 18 def get_proposer @proposer end |
#get_transfer_hashes ⇒ Array
Returns a vector of hex-encoded hashes identifying Transfers included in this block.
29 30 31 |
# File 'lib/entity/block_body.rb', line 29 def get_transfer_hashes @transfer_hashes end |