TokenFaucet

package
v0.0.0-...-73c85e8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 26, 2024 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NativeTokenAddress = "0x0000000000000000000000000000000000000000"
)

Variables

View Source
var ErrNoRPCURL error = errors.New("no RPC URL provided -- please pass an RPC URL from the command line or set the TOKEN_FAUCET_RPC_URL environment variable")
View Source
var TokenFaucetABI = TokenFaucetMetaData.ABI

TokenFaucetABI is the input ABI used to generate the binding from. Deprecated: Use TokenFaucetMetaData.ABI instead.

View Source
var TokenFaucetBin = TokenFaucetMetaData.Bin

TokenFaucetBin is the compiled bytecode used for deploying new contracts. Deprecated: Use TokenFaucetMetaData.Bin instead.

View Source
var TokenFaucetMetaData = &bind.MetaData{
	ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_tokenAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_inboxAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_faucetAmount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_faucetTimeInterval\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"OwnableInvalidOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"OwnableUnauthorizedAccount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TokenFaucetClaimIntervalNotPassed\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"DEFAULT_GAS_LIMIT\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claim\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"claimL3\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"faucetAmount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"faucetTimeInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"inboxAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"lastClaimedL2Timestamp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"lastClaimedL3Timestamp\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"rescueTokens\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_faucetAmount\",\"type\":\"uint256\"}],\"name\":\"setFaucetAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_faucetTimeInterval\",\"type\":\"uint256\"}],\"name\":\"setFaucetTimeInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_inboxAddress\",\"type\":\"address\"}],\"name\":\"setInboxAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_tokenAddress\",\"type\":\"address\"}],\"name\":\"setTokenAddress\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"tokenAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]",
	Bin: "0x608060405261520860055534801561001657600080fd5b5060405162000bba38038062000bba83398101604081905261003791610197565b836001600160a01b03811661006757604051631e4fbdf760e01b8152600060048201526024015b60405180910390fd5b610070816100be565b50600180546001600160a01b038088166001600160a01b0319928316179092556002805492861692909116919091179055600382905560048190556100b48461010e565b50505050506101ed565b600080546001600160a01b038381166001600160a01b0319831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b61011661014c565b6001600160a01b03811661014057604051631e4fbdf760e01b81526000600482015260240161005e565b610149816100be565b50565b6000546001600160a01b031633146101795760405163118cdaa760e01b815233600482015260240161005e565b565b80516001600160a01b038116811461019257600080fd5b919050565b600080600080600060a086880312156101af57600080fd5b6101b88661017b565b94506101c66020870161017b565b93506101d46040870161017b565b6060870151608090970151959894975095949392505050565b6109bd80620001fd6000396000f3fe608060405234801561001057600080fd5b506004361061011b5760003560e01c80638da5cb5b116100b2578063b8dbe3f511610081578063cea9d26f11610066578063cea9d26f1461026a578063d6be695a1461027d578063f2fde38b1461028657600080fd5b8063b8dbe3f514610237578063cdffca3a1461025757600080fd5b80638da5cb5b146101c65780639c281430146102055780639d76ea581461020e578063a42532ad1461022e57600080fd5b8063706bb59a116100ee578063706bb59a14610183578063715018a61461018b57806371559c751461019357806381d2fd9c146101b357600080fd5b8063020c324e1461012057806326a4e8d21461013557806331c32cbe146101485780634e71d92d1461017b575b600080fd5b61013361012e36600461084d565b610299565b005b61013361014336600461088f565b6102a6565b61016861015636600461088f565b60066020526000908152604090205481565b6040519081526020015b60405180910390f35b6101336102f5565b6101336103fe565b610133610605565b6101686101a136600461088f565b60076020526000908152604090205481565b6101336101c136600461084d565b610619565b60005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610172565b61016860035481565b6001546101e09073ffffffffffffffffffffffffffffffffffffffff1681565b61016860045481565b6002546101e09073ffffffffffffffffffffffffffffffffffffffff1681565b61013361026536600461088f565b610626565b6101336102783660046108b1565b610675565b61016860055481565b61013361029436600461088f565b61071c565b6102a1610785565b600455565b6102ae610785565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60045433600090815260066020526040902054610312919061091c565b421161034a576040517f6fab395900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001546003546040517fa9059cbb000000000000000000000000000000000000000000000000000000008152336004820152602481019190915273ffffffffffffffffffffffffffffffffffffffff9091169063a9059cbb906044016020604051808303816000875af11580156103c5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906103e99190610935565b50336000908152600660205260409020429055565b6004543360009081526007602052604090205461041b919061091c565b4211610453576040517f6fab395900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000600354486005546104669190610957565b610470919061091c565b6001546002546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff918216600482015260248101849052929350169063095ea7b3906044016020604051808303816000875af11580156104ed573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105119190610935565b506002546003546005546040517f549e842600000000000000000000000000000000000000000000000000000000815233600482015260248101929092526000604483018190523060648401819052608484015260a48301919091524860c483015260e4820184905261012061010483015261012482015273ffffffffffffffffffffffffffffffffffffffff9091169063549e842690610144016020604051808303816000875af11580156105cb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105ef919061096e565b5050336000908152600760205260409020429055565b61060d610785565b61061760006107d8565b565b610621610785565b600355565b61062e610785565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b61067d610785565b6040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526024820183905284169063a9059cbb906044016020604051808303816000875af11580156106f2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107169190610935565b50505050565b610724610785565b73ffffffffffffffffffffffffffffffffffffffff8116610779576040517f1e4fbdf7000000000000000000000000000000000000000000000000000000008152600060048201526024015b60405180910390fd5b610782816107d8565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610617576040517f118cdaa7000000000000000000000000000000000000000000000000000000008152336004820152602401610770565b6000805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff0000000000000000000000000000000000000000831681178455604051919092169283917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e09190a35050565b60006020828403121561085f57600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461088a57600080fd5b919050565b6000602082840312156108a157600080fd5b6108aa82610866565b9392505050565b6000806000606084860312156108c657600080fd5b6108cf84610866565b92506108dd60208501610866565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561092f5761092f6108ed565b92915050565b60006020828403121561094757600080fd5b815180151581146108aa57600080fd5b808202811582820484141761092f5761092f6108ed565b60006020828403121561098057600080fd5b505191905056fea2646970667358221220695d0ebba8bdc0aedf19cfe101419c324c0623b00f59f1ef5e00dc2e450da37664736f6c63430008180033",
}

Functions

func CalculateSafeTxHash

func CalculateSafeTxHash(safeAddress common.Address, txData SafeTransactionData, chainID *big.Int) (common.Hash, error)

func CreateClaimCommand

func CreateClaimCommand() *cobra.Command

func CreateClaimL3Command

func CreateClaimL3Command() *cobra.Command

func CreateDefaultgaslimitCommand

func CreateDefaultgaslimitCommand() *cobra.Command

func CreateFaucetAmountCommand

func CreateFaucetAmountCommand() *cobra.Command

func CreateFaucetTimeIntervalCommand

func CreateFaucetTimeIntervalCommand() *cobra.Command

func CreateInboxAddressCommand

func CreateInboxAddressCommand() *cobra.Command

func CreateLastClaimedL2TimestampCommand

func CreateLastClaimedL2TimestampCommand() *cobra.Command

func CreateLastClaimedL3TimestampCommand

func CreateLastClaimedL3TimestampCommand() *cobra.Command

func CreateOwnerCommand

func CreateOwnerCommand() *cobra.Command

func CreateRenounceOwnershipCommand

func CreateRenounceOwnershipCommand() *cobra.Command

func CreateRescueTokensCommand

func CreateRescueTokensCommand() *cobra.Command

func CreateSafeProposal

func CreateSafeProposal(client *ethclient.Client, key *keystore.Key, safeAddress common.Address, to common.Address, data []byte, value *big.Int, safeApi string, safeOperationType SafeOperationType, safeNonce *big.Int) error

func CreateSetFaucetAmountCommand

func CreateSetFaucetAmountCommand() *cobra.Command

func CreateSetFaucetTimeIntervalCommand

func CreateSetFaucetTimeIntervalCommand() *cobra.Command

func CreateSetInboxAddressCommand

func CreateSetInboxAddressCommand() *cobra.Command

func CreateSetTokenAddressCommand

func CreateSetTokenAddressCommand() *cobra.Command

func CreateTokenAddressCommand

func CreateTokenAddressCommand() *cobra.Command

func CreateTokenFaucetCommand

func CreateTokenFaucetCommand() *cobra.Command

func CreateTokenFaucetDeploymentCommand

func CreateTokenFaucetDeploymentCommand() *cobra.Command

func CreateTransferOwnershipCommand

func CreateTransferOwnershipCommand() *cobra.Command

func DeployWithSafe

func DeployWithSafe(client *ethclient.Client, key *keystore.Key, safeAddress common.Address, factoryAddress common.Address, value *big.Int, safeApi string, deployBytecode []byte, safeOperationType SafeOperationType, salt [32]byte, safeNonce *big.Int) error

func KeyFromFile

func KeyFromFile(keystoreFile string, password string) (*keystore.Key, error)

Loads a key from file, prompting the user for the password if it is not provided as a function argument.

func NewChainContext

func NewChainContext(timeout uint) (context.Context, context.CancelFunc)

Creates a new context to be used when interacting with the chain client.

func NewClient

func NewClient(rpcURL string) (*ethclient.Client, error)

Generates an Ethereum client to the JSONRPC API at the given URL. If rpcURL is empty, then it attempts to read the RPC URL from the TOKEN_FAUCET_RPC_URL environment variable. If that is empty, too, then it returns an error.

func PredictDeploymentAddressSafe

func PredictDeploymentAddressSafe(from common.Address, salt [32]byte, deployBytecode []byte) (common.Address, error)

func SetCallParametersFromArgs

func SetCallParametersFromArgs(opts *bind.CallOpts, pending bool, fromAddress, blockNumber string)

This method is used to set the parameters on a view call from command line arguments (represented mostly as strings).

func SetTransactionParametersFromArgs

func SetTransactionParametersFromArgs(opts *bind.TransactOpts, nonce, value, gasPrice, maxFeePerGas, maxPriorityFeePerGas string, gasLimit uint64, noSend bool)

This method is used to set the parameters on a transaction from command line arguments (represented mostly as strings).

func UnlockKeystore

func UnlockKeystore(keystoreData []byte, password string) (*keystore.Key, error)

Unlocks a key from a keystore (byte contents of a keystore file) with the given password.

Types

type SafeOperationType

type SafeOperationType uint8

SafeOperationType represents the type of operation for a Safe transaction

const (
	Call         SafeOperationType = 0
	DelegateCall SafeOperationType = 1
)

func (SafeOperationType) String

func (o SafeOperationType) String() string

String returns the string representation of the SafeOperationType

type SafeTransactionData

type SafeTransactionData struct {
	To             string            `json:"to"`
	Value          string            `json:"value"`
	Data           string            `json:"data"`
	Operation      SafeOperationType `json:"operation"`
	SafeTxGas      uint64            `json:"safeTxGas"`
	BaseGas        uint64            `json:"baseGas"`
	GasPrice       string            `json:"gasPrice"`
	GasToken       string            `json:"gasToken"`
	RefundReceiver string            `json:"refundReceiver"`
	Nonce          *big.Int          `json:"nonce"`
	SafeTxHash     string            `json:"safeTxHash"`
	Sender         string            `json:"sender"`
	Signature      string            `json:"signature"`
	Origin         string            `json:"origin"`
}

SafeTransactionData represents the data for a Safe transaction

type TokenFaucet

type TokenFaucet struct {
	TokenFaucetCaller     // Read-only binding to the contract
	TokenFaucetTransactor // Write-only binding to the contract
	TokenFaucetFilterer   // Log filterer for contract events
}

TokenFaucet is an auto generated Go binding around an Ethereum contract.

func DeployTokenFaucet

func DeployTokenFaucet(auth *bind.TransactOpts, backend bind.ContractBackend, _tokenAddress common.Address, _owner common.Address, _inboxAddress common.Address, _faucetAmount *big.Int, _faucetTimeInterval *big.Int) (common.Address, *types.Transaction, *TokenFaucet, error)

DeployTokenFaucet deploys a new Ethereum contract, binding an instance of TokenFaucet to it.

func NewTokenFaucet

func NewTokenFaucet(address common.Address, backend bind.ContractBackend) (*TokenFaucet, error)

NewTokenFaucet creates a new instance of TokenFaucet, bound to a specific deployed contract.

type TokenFaucetCaller

type TokenFaucetCaller struct {
	// contains filtered or unexported fields
}

TokenFaucetCaller is an auto generated read-only Go binding around an Ethereum contract.

func NewTokenFaucetCaller

func NewTokenFaucetCaller(address common.Address, caller bind.ContractCaller) (*TokenFaucetCaller, error)

NewTokenFaucetCaller creates a new read-only instance of TokenFaucet, bound to a specific deployed contract.

func (*TokenFaucetCaller) DEFAULTGASLIMIT

func (_TokenFaucet *TokenFaucetCaller) DEFAULTGASLIMIT(opts *bind.CallOpts) (*big.Int, error)

DEFAULTGASLIMIT is a free data retrieval call binding the contract method 0xd6be695a.

Solidity: function DEFAULT_GAS_LIMIT() view returns(uint256)

func (*TokenFaucetCaller) FaucetAmount

func (_TokenFaucet *TokenFaucetCaller) FaucetAmount(opts *bind.CallOpts) (*big.Int, error)

FaucetAmount is a free data retrieval call binding the contract method 0x9c281430.

Solidity: function faucetAmount() view returns(uint256)

func (*TokenFaucetCaller) FaucetTimeInterval

func (_TokenFaucet *TokenFaucetCaller) FaucetTimeInterval(opts *bind.CallOpts) (*big.Int, error)

FaucetTimeInterval is a free data retrieval call binding the contract method 0xa42532ad.

Solidity: function faucetTimeInterval() view returns(uint256)

func (*TokenFaucetCaller) InboxAddress

func (_TokenFaucet *TokenFaucetCaller) InboxAddress(opts *bind.CallOpts) (common.Address, error)

InboxAddress is a free data retrieval call binding the contract method 0xb8dbe3f5.

Solidity: function inboxAddress() view returns(address)

func (*TokenFaucetCaller) LastClaimedL2Timestamp

func (_TokenFaucet *TokenFaucetCaller) LastClaimedL2Timestamp(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error)

LastClaimedL2Timestamp is a free data retrieval call binding the contract method 0x31c32cbe.

Solidity: function lastClaimedL2Timestamp(address ) view returns(uint256)

func (*TokenFaucetCaller) LastClaimedL3Timestamp

func (_TokenFaucet *TokenFaucetCaller) LastClaimedL3Timestamp(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error)

LastClaimedL3Timestamp is a free data retrieval call binding the contract method 0x71559c75.

Solidity: function lastClaimedL3Timestamp(address ) view returns(uint256)

func (*TokenFaucetCaller) Owner

func (_TokenFaucet *TokenFaucetCaller) Owner(opts *bind.CallOpts) (common.Address, error)

Owner is a free data retrieval call binding the contract method 0x8da5cb5b.

Solidity: function owner() view returns(address)

func (*TokenFaucetCaller) TokenAddress

func (_TokenFaucet *TokenFaucetCaller) TokenAddress(opts *bind.CallOpts) (common.Address, error)

TokenAddress is a free data retrieval call binding the contract method 0x9d76ea58.

Solidity: function tokenAddress() view returns(address)

type TokenFaucetCallerRaw

type TokenFaucetCallerRaw struct {
	Contract *TokenFaucetCaller // Generic read-only contract binding to access the raw methods on
}

TokenFaucetCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.

func (*TokenFaucetCallerRaw) Call

func (_TokenFaucet *TokenFaucetCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

type TokenFaucetCallerSession

type TokenFaucetCallerSession struct {
	Contract *TokenFaucetCaller // Generic contract caller binding to set the session for
	CallOpts bind.CallOpts      // Call options to use throughout this session
}

TokenFaucetCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.

func (*TokenFaucetCallerSession) DEFAULTGASLIMIT

func (_TokenFaucet *TokenFaucetCallerSession) DEFAULTGASLIMIT() (*big.Int, error)

DEFAULTGASLIMIT is a free data retrieval call binding the contract method 0xd6be695a.

Solidity: function DEFAULT_GAS_LIMIT() view returns(uint256)

func (*TokenFaucetCallerSession) FaucetAmount

func (_TokenFaucet *TokenFaucetCallerSession) FaucetAmount() (*big.Int, error)

FaucetAmount is a free data retrieval call binding the contract method 0x9c281430.

Solidity: function faucetAmount() view returns(uint256)

func (*TokenFaucetCallerSession) FaucetTimeInterval

func (_TokenFaucet *TokenFaucetCallerSession) FaucetTimeInterval() (*big.Int, error)

FaucetTimeInterval is a free data retrieval call binding the contract method 0xa42532ad.

Solidity: function faucetTimeInterval() view returns(uint256)

func (*TokenFaucetCallerSession) InboxAddress

func (_TokenFaucet *TokenFaucetCallerSession) InboxAddress() (common.Address, error)

InboxAddress is a free data retrieval call binding the contract method 0xb8dbe3f5.

Solidity: function inboxAddress() view returns(address)

func (*TokenFaucetCallerSession) LastClaimedL2Timestamp

func (_TokenFaucet *TokenFaucetCallerSession) LastClaimedL2Timestamp(arg0 common.Address) (*big.Int, error)

LastClaimedL2Timestamp is a free data retrieval call binding the contract method 0x31c32cbe.

Solidity: function lastClaimedL2Timestamp(address ) view returns(uint256)

func (*TokenFaucetCallerSession) LastClaimedL3Timestamp

func (_TokenFaucet *TokenFaucetCallerSession) LastClaimedL3Timestamp(arg0 common.Address) (*big.Int, error)

LastClaimedL3Timestamp is a free data retrieval call binding the contract method 0x71559c75.

Solidity: function lastClaimedL3Timestamp(address ) view returns(uint256)

func (*TokenFaucetCallerSession) Owner

func (_TokenFaucet *TokenFaucetCallerSession) Owner() (common.Address, error)

Owner is a free data retrieval call binding the contract method 0x8da5cb5b.

Solidity: function owner() view returns(address)

func (*TokenFaucetCallerSession) TokenAddress

func (_TokenFaucet *TokenFaucetCallerSession) TokenAddress() (common.Address, error)

TokenAddress is a free data retrieval call binding the contract method 0x9d76ea58.

Solidity: function tokenAddress() view returns(address)

type TokenFaucetFilterer

type TokenFaucetFilterer struct {
	// contains filtered or unexported fields
}

TokenFaucetFilterer is an auto generated log filtering Go binding around an Ethereum contract events.

func NewTokenFaucetFilterer

func NewTokenFaucetFilterer(address common.Address, filterer bind.ContractFilterer) (*TokenFaucetFilterer, error)

NewTokenFaucetFilterer creates a new log filterer instance of TokenFaucet, bound to a specific deployed contract.

func (*TokenFaucetFilterer) FilterOwnershipTransferred

func (_TokenFaucet *TokenFaucetFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*TokenFaucetOwnershipTransferredIterator, error)

FilterOwnershipTransferred is a free log retrieval operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.

Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)

func (*TokenFaucetFilterer) ParseOwnershipTransferred

func (_TokenFaucet *TokenFaucetFilterer) ParseOwnershipTransferred(log types.Log) (*TokenFaucetOwnershipTransferred, error)

ParseOwnershipTransferred is a log parse operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.

Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)

func (*TokenFaucetFilterer) WatchOwnershipTransferred

func (_TokenFaucet *TokenFaucetFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *TokenFaucetOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error)

WatchOwnershipTransferred is a free log subscription operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.

Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)

type TokenFaucetOwnershipTransferred

type TokenFaucetOwnershipTransferred struct {
	PreviousOwner common.Address
	NewOwner      common.Address
	Raw           types.Log // Blockchain specific contextual infos
}

TokenFaucetOwnershipTransferred represents a OwnershipTransferred event raised by the TokenFaucet contract.

type TokenFaucetOwnershipTransferredIterator

type TokenFaucetOwnershipTransferredIterator struct {
	Event *TokenFaucetOwnershipTransferred // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

TokenFaucetOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the TokenFaucet contract.

func (*TokenFaucetOwnershipTransferredIterator) Close

Close terminates the iteration process, releasing any pending underlying resources.

func (*TokenFaucetOwnershipTransferredIterator) Error

Error returns any retrieval or parsing error occurred during filtering.

func (*TokenFaucetOwnershipTransferredIterator) Next

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type TokenFaucetRaw

type TokenFaucetRaw struct {
	Contract *TokenFaucet // Generic contract binding to access the raw methods on
}

TokenFaucetRaw is an auto generated low-level Go binding around an Ethereum contract.

func (*TokenFaucetRaw) Call

func (_TokenFaucet *TokenFaucetRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

func (*TokenFaucetRaw) Transact

func (_TokenFaucet *TokenFaucetRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TokenFaucetRaw) Transfer

func (_TokenFaucet *TokenFaucetRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TokenFaucetSession

type TokenFaucetSession struct {
	Contract     *TokenFaucet      // Generic contract binding to set the session for
	CallOpts     bind.CallOpts     // Call options to use throughout this session
	TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}

TokenFaucetSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.

func (*TokenFaucetSession) Claim

func (_TokenFaucet *TokenFaucetSession) Claim() (*types.Transaction, error)

Claim is a paid mutator transaction binding the contract method 0x4e71d92d.

Solidity: function claim() returns()

func (*TokenFaucetSession) ClaimL3

func (_TokenFaucet *TokenFaucetSession) ClaimL3() (*types.Transaction, error)

ClaimL3 is a paid mutator transaction binding the contract method 0x706bb59a.

Solidity: function claimL3() returns()

func (*TokenFaucetSession) DEFAULTGASLIMIT

func (_TokenFaucet *TokenFaucetSession) DEFAULTGASLIMIT() (*big.Int, error)

DEFAULTGASLIMIT is a free data retrieval call binding the contract method 0xd6be695a.

Solidity: function DEFAULT_GAS_LIMIT() view returns(uint256)

func (*TokenFaucetSession) FaucetAmount

func (_TokenFaucet *TokenFaucetSession) FaucetAmount() (*big.Int, error)

FaucetAmount is a free data retrieval call binding the contract method 0x9c281430.

Solidity: function faucetAmount() view returns(uint256)

func (*TokenFaucetSession) FaucetTimeInterval

func (_TokenFaucet *TokenFaucetSession) FaucetTimeInterval() (*big.Int, error)

FaucetTimeInterval is a free data retrieval call binding the contract method 0xa42532ad.

Solidity: function faucetTimeInterval() view returns(uint256)

func (*TokenFaucetSession) InboxAddress

func (_TokenFaucet *TokenFaucetSession) InboxAddress() (common.Address, error)

InboxAddress is a free data retrieval call binding the contract method 0xb8dbe3f5.

Solidity: function inboxAddress() view returns(address)

func (*TokenFaucetSession) LastClaimedL2Timestamp

func (_TokenFaucet *TokenFaucetSession) LastClaimedL2Timestamp(arg0 common.Address) (*big.Int, error)

LastClaimedL2Timestamp is a free data retrieval call binding the contract method 0x31c32cbe.

Solidity: function lastClaimedL2Timestamp(address ) view returns(uint256)

func (*TokenFaucetSession) LastClaimedL3Timestamp

func (_TokenFaucet *TokenFaucetSession) LastClaimedL3Timestamp(arg0 common.Address) (*big.Int, error)

LastClaimedL3Timestamp is a free data retrieval call binding the contract method 0x71559c75.

Solidity: function lastClaimedL3Timestamp(address ) view returns(uint256)

func (*TokenFaucetSession) Owner

func (_TokenFaucet *TokenFaucetSession) Owner() (common.Address, error)

Owner is a free data retrieval call binding the contract method 0x8da5cb5b.

Solidity: function owner() view returns(address)

func (*TokenFaucetSession) RenounceOwnership

func (_TokenFaucet *TokenFaucetSession) RenounceOwnership() (*types.Transaction, error)

RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.

Solidity: function renounceOwnership() returns()

func (*TokenFaucetSession) RescueTokens

func (_TokenFaucet *TokenFaucetSession) RescueTokens(_token common.Address, _to common.Address, _amount *big.Int) (*types.Transaction, error)

RescueTokens is a paid mutator transaction binding the contract method 0xcea9d26f.

Solidity: function rescueTokens(address _token, address _to, uint256 _amount) returns()

func (*TokenFaucetSession) SetFaucetAmount

func (_TokenFaucet *TokenFaucetSession) SetFaucetAmount(_faucetAmount *big.Int) (*types.Transaction, error)

SetFaucetAmount is a paid mutator transaction binding the contract method 0x81d2fd9c.

Solidity: function setFaucetAmount(uint256 _faucetAmount) returns()

func (*TokenFaucetSession) SetFaucetTimeInterval

func (_TokenFaucet *TokenFaucetSession) SetFaucetTimeInterval(_faucetTimeInterval *big.Int) (*types.Transaction, error)

SetFaucetTimeInterval is a paid mutator transaction binding the contract method 0x020c324e.

Solidity: function setFaucetTimeInterval(uint256 _faucetTimeInterval) returns()

func (*TokenFaucetSession) SetInboxAddress

func (_TokenFaucet *TokenFaucetSession) SetInboxAddress(_inboxAddress common.Address) (*types.Transaction, error)

SetInboxAddress is a paid mutator transaction binding the contract method 0xcdffca3a.

Solidity: function setInboxAddress(address _inboxAddress) returns()

func (*TokenFaucetSession) SetTokenAddress

func (_TokenFaucet *TokenFaucetSession) SetTokenAddress(_tokenAddress common.Address) (*types.Transaction, error)

SetTokenAddress is a paid mutator transaction binding the contract method 0x26a4e8d2.

Solidity: function setTokenAddress(address _tokenAddress) returns()

func (*TokenFaucetSession) TokenAddress

func (_TokenFaucet *TokenFaucetSession) TokenAddress() (common.Address, error)

TokenAddress is a free data retrieval call binding the contract method 0x9d76ea58.

Solidity: function tokenAddress() view returns(address)

func (*TokenFaucetSession) TransferOwnership

func (_TokenFaucet *TokenFaucetSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error)

TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.

Solidity: function transferOwnership(address newOwner) returns()

type TokenFaucetTransactor

type TokenFaucetTransactor struct {
	// contains filtered or unexported fields
}

TokenFaucetTransactor is an auto generated write-only Go binding around an Ethereum contract.

func NewTokenFaucetTransactor

func NewTokenFaucetTransactor(address common.Address, transactor bind.ContractTransactor) (*TokenFaucetTransactor, error)

NewTokenFaucetTransactor creates a new write-only instance of TokenFaucet, bound to a specific deployed contract.

func (*TokenFaucetTransactor) Claim

func (_TokenFaucet *TokenFaucetTransactor) Claim(opts *bind.TransactOpts) (*types.Transaction, error)

Claim is a paid mutator transaction binding the contract method 0x4e71d92d.

Solidity: function claim() returns()

func (*TokenFaucetTransactor) ClaimL3

func (_TokenFaucet *TokenFaucetTransactor) ClaimL3(opts *bind.TransactOpts) (*types.Transaction, error)

ClaimL3 is a paid mutator transaction binding the contract method 0x706bb59a.

Solidity: function claimL3() returns()

func (*TokenFaucetTransactor) RenounceOwnership

func (_TokenFaucet *TokenFaucetTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error)

RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.

Solidity: function renounceOwnership() returns()

func (*TokenFaucetTransactor) RescueTokens

func (_TokenFaucet *TokenFaucetTransactor) RescueTokens(opts *bind.TransactOpts, _token common.Address, _to common.Address, _amount *big.Int) (*types.Transaction, error)

RescueTokens is a paid mutator transaction binding the contract method 0xcea9d26f.

Solidity: function rescueTokens(address _token, address _to, uint256 _amount) returns()

func (*TokenFaucetTransactor) SetFaucetAmount

func (_TokenFaucet *TokenFaucetTransactor) SetFaucetAmount(opts *bind.TransactOpts, _faucetAmount *big.Int) (*types.Transaction, error)

SetFaucetAmount is a paid mutator transaction binding the contract method 0x81d2fd9c.

Solidity: function setFaucetAmount(uint256 _faucetAmount) returns()

func (*TokenFaucetTransactor) SetFaucetTimeInterval

func (_TokenFaucet *TokenFaucetTransactor) SetFaucetTimeInterval(opts *bind.TransactOpts, _faucetTimeInterval *big.Int) (*types.Transaction, error)

SetFaucetTimeInterval is a paid mutator transaction binding the contract method 0x020c324e.

Solidity: function setFaucetTimeInterval(uint256 _faucetTimeInterval) returns()

func (*TokenFaucetTransactor) SetInboxAddress

func (_TokenFaucet *TokenFaucetTransactor) SetInboxAddress(opts *bind.TransactOpts, _inboxAddress common.Address) (*types.Transaction, error)

SetInboxAddress is a paid mutator transaction binding the contract method 0xcdffca3a.

Solidity: function setInboxAddress(address _inboxAddress) returns()

func (*TokenFaucetTransactor) SetTokenAddress

func (_TokenFaucet *TokenFaucetTransactor) SetTokenAddress(opts *bind.TransactOpts, _tokenAddress common.Address) (*types.Transaction, error)

SetTokenAddress is a paid mutator transaction binding the contract method 0x26a4e8d2.

Solidity: function setTokenAddress(address _tokenAddress) returns()

func (*TokenFaucetTransactor) TransferOwnership

func (_TokenFaucet *TokenFaucetTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error)

TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.

Solidity: function transferOwnership(address newOwner) returns()

type TokenFaucetTransactorRaw

type TokenFaucetTransactorRaw struct {
	Contract *TokenFaucetTransactor // Generic write-only contract binding to access the raw methods on
}

TokenFaucetTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.

func (*TokenFaucetTransactorRaw) Transact

func (_TokenFaucet *TokenFaucetTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TokenFaucetTransactorRaw) Transfer

func (_TokenFaucet *TokenFaucetTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TokenFaucetTransactorSession

type TokenFaucetTransactorSession struct {
	Contract     *TokenFaucetTransactor // Generic contract transactor binding to set the session for
	TransactOpts bind.TransactOpts      // Transaction auth options to use throughout this session
}

TokenFaucetTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.

func (*TokenFaucetTransactorSession) Claim

func (_TokenFaucet *TokenFaucetTransactorSession) Claim() (*types.Transaction, error)

Claim is a paid mutator transaction binding the contract method 0x4e71d92d.

Solidity: function claim() returns()

func (*TokenFaucetTransactorSession) ClaimL3

func (_TokenFaucet *TokenFaucetTransactorSession) ClaimL3() (*types.Transaction, error)

ClaimL3 is a paid mutator transaction binding the contract method 0x706bb59a.

Solidity: function claimL3() returns()

func (*TokenFaucetTransactorSession) RenounceOwnership

func (_TokenFaucet *TokenFaucetTransactorSession) RenounceOwnership() (*types.Transaction, error)

RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.

Solidity: function renounceOwnership() returns()

func (*TokenFaucetTransactorSession) RescueTokens

func (_TokenFaucet *TokenFaucetTransactorSession) RescueTokens(_token common.Address, _to common.Address, _amount *big.Int) (*types.Transaction, error)

RescueTokens is a paid mutator transaction binding the contract method 0xcea9d26f.

Solidity: function rescueTokens(address _token, address _to, uint256 _amount) returns()

func (*TokenFaucetTransactorSession) SetFaucetAmount

func (_TokenFaucet *TokenFaucetTransactorSession) SetFaucetAmount(_faucetAmount *big.Int) (*types.Transaction, error)

SetFaucetAmount is a paid mutator transaction binding the contract method 0x81d2fd9c.

Solidity: function setFaucetAmount(uint256 _faucetAmount) returns()

func (*TokenFaucetTransactorSession) SetFaucetTimeInterval

func (_TokenFaucet *TokenFaucetTransactorSession) SetFaucetTimeInterval(_faucetTimeInterval *big.Int) (*types.Transaction, error)

SetFaucetTimeInterval is a paid mutator transaction binding the contract method 0x020c324e.

Solidity: function setFaucetTimeInterval(uint256 _faucetTimeInterval) returns()

func (*TokenFaucetTransactorSession) SetInboxAddress

func (_TokenFaucet *TokenFaucetTransactorSession) SetInboxAddress(_inboxAddress common.Address) (*types.Transaction, error)

SetInboxAddress is a paid mutator transaction binding the contract method 0xcdffca3a.

Solidity: function setInboxAddress(address _inboxAddress) returns()

func (*TokenFaucetTransactorSession) SetTokenAddress

func (_TokenFaucet *TokenFaucetTransactorSession) SetTokenAddress(_tokenAddress common.Address) (*types.Transaction, error)

SetTokenAddress is a paid mutator transaction binding the contract method 0x26a4e8d2.

Solidity: function setTokenAddress(address _tokenAddress) returns()

func (*TokenFaucetTransactorSession) TransferOwnership

func (_TokenFaucet *TokenFaucetTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error)

TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.

Solidity: function transferOwnership(address newOwner) returns()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL