Module: Fabric::Accessors::Contract

Includes:
Gateway, Network
Included in:
ChaincodeEventsRequest, Proposal, ProposedTransaction
Defined in:
lib/fabric/accessors/contract.rb

Overview

Add accessor methods to the given class.

Usage: make sure the class has a contract accessor method and then include Fabric::Accessors::Contract

Instance Attribute Summary collapse

Attributes included from Gateway

#client, #signer

Attributes included from Network

#gateway, #network_name

Instance Attribute Details

#chaincode_nameString (readonly)

Returns the chaincode name

Returns:

  • (String)

    chaincode name



46
47
48
# File 'lib/fabric/accessors/contract.rb', line 46

def chaincode_name
  contract.chaincode_name
end

#contract_nameString (readonly)

Returns the contract name

Returns:

  • (String)

    contract name



36
37
38
# File 'lib/fabric/accessors/contract.rb', line 36

def contract_name
  contract.contract_name
end

#networkFabric::Network (readonly)

Returns the network instance

Returns:



26
27
28
# File 'lib/fabric/accessors/contract.rb', line 26

def network
  contract.network
end