hfc.fabric_network.contract
¶
Module Contents¶
Classes¶
|
Represents a smart contract (chaincode) instance in a network. |
-
hfc.fabric_network.contract.
consoleHandler
¶
-
hfc.fabric_network.contract.
_logger
¶
-
class
hfc.fabric_network.contract.
Contract
(network, cc_name, gateway)¶ Bases:
object
Represents a smart contract (chaincode) instance in a network. Applications should get a Contract instance using the networks’s get_contract method. :return: an instance of Contract
-
get_network
(self)¶
-
get_cc_name
(self)¶
-
get_options
(self)¶
-
async
submit_transaction
(self, name, args, requestor)¶ Submit a transaction to the ledger. The transaction function will be evaluated on the list of peers discovered and then submitted to the ordering service for committing to the ledger.
-
async
evaluate_transaction
(self, name, args, requestor)¶ Evaluate a transaction function and return its results. The transaction function will be evaluated on the endorsing peers but the responses will not be sent to the ordering service and hence will not be committed to the ledger. This is used for querying the world state.
-