Class: Casper::Entity::ContractVersion

Inherits:
Object
  • Object
show all
Defined in:
lib/entity/contract_version.rb

Overview

The version of the contract.

Instance Method Summary collapse

Constructor Details

#initialize(protocol_version_major, contract_version, contract_hash) ⇒ ContractVersion

Returns a new instance of ContractVersion.

Parameters:

  • protocol_version_major (Integer)
  • contract_version (Integer)
  • contract_hash (String)


10
11
12
13
14
# File 'lib/entity/contract_version.rb', line 10

def initialize(protocol_version_major, contract_version, contract_hash)
  @protocol_version_major = protocol_version_major
  @contract_version = contract_version
  @contract_hash = contract_hash
end

Instance Method Details

#get_contract_hashString

Returns contract_hash.

Returns:

  • (String)

    contract_hash



27
28
29
# File 'lib/entity/contract_version.rb', line 27

def get_contract_hash
  @contract_hash
end

#get_contract_versionInteger

Returns contract_version.

Returns:

  • (Integer)

    contract_version



22
23
24
# File 'lib/entity/contract_version.rb', line 22

def get_contract_version
  @contract_version
end

#get_protocol_version_majorInteger

Returns protocol_version_major.

Returns:

  • (Integer)

    protocol_version_major



17
18
19
# File 'lib/entity/contract_version.rb', line 17

def get_protocol_version_major
  @protocol_version_major
end