# README
# contract
The content of this folder is automatically generated from the smoothing pool smart contract. The are two components that can be generated as follows. Note that if the smart contract changes, this would need to be updated:
abi.abi
contract.go
Generating abi.go
This contains the smart contract abi. If the contract is verified in etherscan, it can be copied from there. Example see "Contract ABI" section. Make sure you get the abi of the contract itself and not the proxy.
Generating contract.go
With the abi, now we can generate the contract.go
file using abigen. This allows to easily interact with the contract using golang. First you need to install abigen.
git clone https://github.com/ethereum/go-ethereum.git
cd go-ethereum
go build ./cmd/abigen
And now from the root of this repo, generate the contract.
./abigen --abi=../mev-sp-oracle/contract/abi.abi --pkg=contract --out=../mev-sp-oracle/contract/contract.go
# Functions
NewContract creates a new instance of Contract, bound to a specific deployed contract.
NewContractCaller creates a new read-only instance of Contract, bound to a specific deployed contract.
NewContractFilterer creates a new log filterer instance of Contract, bound to a specific deployed contract.
NewContractTransactor creates a new write-only instance of Contract, bound to a specific deployed contract.
# Variables
ContractABI is the input ABI used to generate the binding from.
ContractMetaData contains all meta data concerning the Contract contract.
# Structs
Contract is an auto generated Go binding around an Ethereum contract.
ContractAcceptGovernance represents a AcceptGovernance event raised by the Contract contract.
ContractAcceptGovernanceIterator is returned from FilterAcceptGovernance and is used to iterate over the raw logs and unpacked data for AcceptGovernance events raised by the Contract contract.
ContractAddOracleMember represents a AddOracleMember event raised by the Contract contract.
ContractAddOracleMemberIterator is returned from FilterAddOracleMember and is used to iterate over the raw logs and unpacked data for AddOracleMember events raised by the Contract contract.
ContractCaller is an auto generated read-only Go binding around an Ethereum contract.
ContractCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
ContractCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.
ContractClaimRewards represents a ClaimRewards event raised by the Contract contract.
ContractClaimRewardsIterator is returned from FilterClaimRewards and is used to iterate over the raw logs and unpacked data for ClaimRewards events raised by the Contract contract.
ContractEtherReceived represents a EtherReceived event raised by the Contract contract.
ContractEtherReceivedIterator is returned from FilterEtherReceived and is used to iterate over the raw logs and unpacked data for EtherReceived events raised by the Contract contract.
ContractFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
ContractInitialized represents a Initialized event raised by the Contract contract.
ContractInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the Contract contract.
ContractInitSmoothingPool represents a InitSmoothingPool event raised by the Contract contract.
ContractInitSmoothingPoolIterator is returned from FilterInitSmoothingPool and is used to iterate over the raw logs and unpacked data for InitSmoothingPool events raised by the Contract contract.
ContractOwnershipTransferred represents a OwnershipTransferred event raised by the Contract contract.
ContractOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the Contract contract.
ContractRaw is an auto generated low-level Go binding around an Ethereum contract.
ContractRemoveOracleMember represents a RemoveOracleMember event raised by the Contract contract.
ContractRemoveOracleMemberIterator is returned from FilterRemoveOracleMember and is used to iterate over the raw logs and unpacked data for RemoveOracleMember events raised by the Contract contract.
ContractReportConsolidated represents a ReportConsolidated event raised by the Contract contract.
ContractReportConsolidatedIterator is returned from FilterReportConsolidated and is used to iterate over the raw logs and unpacked data for ReportConsolidated events raised by the Contract contract.
ContractSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.
ContractSetRewardRecipient represents a SetRewardRecipient event raised by the Contract contract.
ContractSetRewardRecipientIterator is returned from FilterSetRewardRecipient and is used to iterate over the raw logs and unpacked data for SetRewardRecipient events raised by the Contract contract.
ContractSubmitReport represents a SubmitReport event raised by the Contract contract.
ContractSubmitReportIterator is returned from FilterSubmitReport and is used to iterate over the raw logs and unpacked data for SubmitReport events raised by the Contract contract.
ContractSubscribeValidator represents a SubscribeValidator event raised by the Contract contract.
ContractSubscribeValidatorIterator is returned from FilterSubscribeValidator and is used to iterate over the raw logs and unpacked data for SubscribeValidator events raised by the Contract contract.
ContractTransactor is an auto generated write-only Go binding around an Ethereum contract.
ContractTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
ContractTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.
ContractTransferGovernance represents a TransferGovernance event raised by the Contract contract.
ContractTransferGovernanceIterator is returned from FilterTransferGovernance and is used to iterate over the raw logs and unpacked data for TransferGovernance events raised by the Contract contract.
ContractUnsubscribeValidator represents a UnsubscribeValidator event raised by the Contract contract.
ContractUnsubscribeValidatorIterator is returned from FilterUnsubscribeValidator and is used to iterate over the raw logs and unpacked data for UnsubscribeValidator events raised by the Contract contract.
ContractUpdateCheckpointSlotSize represents a UpdateCheckpointSlotSize event raised by the Contract contract.
ContractUpdateCheckpointSlotSizeIterator is returned from FilterUpdateCheckpointSlotSize and is used to iterate over the raw logs and unpacked data for UpdateCheckpointSlotSize events raised by the Contract contract.
ContractUpdatePoolFee represents a UpdatePoolFee event raised by the Contract contract.
ContractUpdatePoolFeeIterator is returned from FilterUpdatePoolFee and is used to iterate over the raw logs and unpacked data for UpdatePoolFee events raised by the Contract contract.
ContractUpdatePoolFeeRecipient represents a UpdatePoolFeeRecipient event raised by the Contract contract.
ContractUpdatePoolFeeRecipientIterator is returned from FilterUpdatePoolFeeRecipient and is used to iterate over the raw logs and unpacked data for UpdatePoolFeeRecipient events raised by the Contract contract.
ContractUpdateQuorum represents a UpdateQuorum event raised by the Contract contract.
ContractUpdateQuorumIterator is returned from FilterUpdateQuorum and is used to iterate over the raw logs and unpacked data for UpdateQuorum events raised by the Contract contract.
ContractUpdateSubscriptionCollateral represents a UpdateSubscriptionCollateral event raised by the Contract contract.
ContractUpdateSubscriptionCollateralIterator is returned from FilterUpdateSubscriptionCollateral and is used to iterate over the raw logs and unpacked data for UpdateSubscriptionCollateral events raised by the Contract contract.