Documentation
¶
Index ¶
- type DaoProposalManager
- func (c *DaoProposalManager) CreateProposalFromID(id uint64, opts *bind.CallOpts) (IProposal, error)
- func (c *DaoProposalManager) GetProposals(proposalCount uint64, includeDetails bool, opts *bind.CallOpts) ([]*OracleDaoProposal, []*SecurityCouncilProposal, error)
- func (c *DaoProposalManager) NewProposalFromDao(id uint64, dao rocketpool.ContractName) (IProposal, error)
- type IProposal
- type OracleDaoProposal
- func (c *OracleDaoProposal) Cancel(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
- func (c *OracleDaoProposal) Common() *ProposalCommon
- func (c *OracleDaoProposal) Execute(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
- func (c *OracleDaoProposal) GetPayloadAsString() (string, error)
- func (c *OracleDaoProposal) QueryAllFields(mc *batch.MultiCaller)
- func (c *OracleDaoProposal) VoteOn(support bool, opts *bind.TransactOpts) (*eth.TransactionInfo, error)
- type ProposalCommon
- type SecurityCouncilProposal
- func (c *SecurityCouncilProposal) Cancel(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
- func (c *SecurityCouncilProposal) Common() *ProposalCommon
- func (c *SecurityCouncilProposal) Execute(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
- func (c *SecurityCouncilProposal) GetPayloadAsString() (string, error)
- func (c *SecurityCouncilProposal) QueryAllFields(mc *batch.MultiCaller)
- func (c *SecurityCouncilProposal) VoteOn(support bool, opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DaoProposalManager ¶
type DaoProposalManager struct { // The total number of DAO proposals // NOTE: Proposals are 1-indexed ProposalCount *core.FormattedUint256Field[uint64] // contains filtered or unexported fields }
Binding for RocketDAOProposal
func NewDaoProposalManager ¶
func NewDaoProposalManager(rp *rocketpool.RocketPool) (*DaoProposalManager, error)
Creates a new DaoProposalManager contract binding
func (*DaoProposalManager) CreateProposalFromID ¶
func (c *DaoProposalManager) CreateProposalFromID(id uint64, opts *bind.CallOpts) (IProposal, error)
Create a proposal binding by ID
func (*DaoProposalManager) GetProposals ¶
func (c *DaoProposalManager) GetProposals(proposalCount uint64, includeDetails bool, opts *bind.CallOpts) ([]*OracleDaoProposal, []*SecurityCouncilProposal, error)
Get all of the Oracle DAO and security council proposals NOTE: Proposals are 1-indexed
func (*DaoProposalManager) NewProposalFromDao ¶
func (c *DaoProposalManager) NewProposalFromDao(id uint64, dao rocketpool.ContractName) (IProposal, error)
Create a proposal binding from an explicit DAO ID if you already know what it is
type IProposal ¶
type IProposal interface { // Get all of the proposal's details QueryAllFields(mc *batch.MultiCaller) // Get the binding common across each type of proposal Common() *ProposalCommon }
type OracleDaoProposal ¶
type OracleDaoProposal struct { *ProposalCommon // contains filtered or unexported fields }
Binding for Oracle DAO proposals
func GetProposalAsOracle ¶
func GetProposalAsOracle(proposal IProposal) (*OracleDaoProposal, bool)
Get a proposal as an Oracle DAO propsal
func (*OracleDaoProposal) Cancel ¶
func (c *OracleDaoProposal) Cancel(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Get info for cancelling a proposal
func (*OracleDaoProposal) Common ¶
func (c *OracleDaoProposal) Common() *ProposalCommon
Get the common fields
func (*OracleDaoProposal) Execute ¶
func (c *OracleDaoProposal) Execute(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Get info for executing a proposal
func (*OracleDaoProposal) GetPayloadAsString ¶
func (c *OracleDaoProposal) GetPayloadAsString() (string, error)
Get the proposal's payload as a string
func (*OracleDaoProposal) QueryAllFields ¶
func (c *OracleDaoProposal) QueryAllFields(mc *batch.MultiCaller)
Get the basic details
func (*OracleDaoProposal) VoteOn ¶
func (c *OracleDaoProposal) VoteOn(support bool, opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Get info for voting on a proposal
type ProposalCommon ¶
type ProposalCommon struct { // The proposal's ID ID uint64 // The address of the node that created the proposal ProposerAddress *core.SimpleField[common.Address] // The message provided with the proposal Message *core.SimpleField[string] // The time the proposal was created CreatedTime *core.FormattedUint256Field[time.Time] // The time the voting window on the proposal started StartTime *core.FormattedUint256Field[time.Time] // The time the voting window on the proposal ended EndTime *core.FormattedUint256Field[time.Time] // The time the proposal expires ExpiryTime *core.FormattedUint256Field[time.Time] // The number of votes required for the proposal to pass VotesRequired *core.FormattedUint256Field[float64] // The number of votes in favor of the proposal VotesFor *core.FormattedUint256Field[float64] // The number of votes against the proposal VotesAgainst *core.FormattedUint256Field[float64] // True if the proposal has been cancelled IsCancelled *core.SimpleField[bool] // True if the proposal has been executed IsExecuted *core.SimpleField[bool] // The proposal's payload Payload *core.SimpleField[[]byte] // The proposal's state State *core.FormattedUint8Field[types.ProposalState] // contains filtered or unexported fields }
Binding for proposals
func (*ProposalCommon) GetMemberHasVoted ¶
func (c *ProposalCommon) GetMemberHasVoted(mc *batch.MultiCaller, out *bool, address common.Address)
Check if a node has voted on the proposal
func (*ProposalCommon) GetMemberSupported ¶
func (c *ProposalCommon) GetMemberSupported(mc *batch.MultiCaller, out *bool, address common.Address)
Check if a node has voted in favor of the proposal
type SecurityCouncilProposal ¶
type SecurityCouncilProposal struct { *ProposalCommon // contains filtered or unexported fields }
Binding for security council proposals
func GetProposalAsSecurity ¶
func GetProposalAsSecurity(proposal IProposal) (*SecurityCouncilProposal, bool)
Get a proposal as a security council propsal
func (*SecurityCouncilProposal) Cancel ¶
func (c *SecurityCouncilProposal) Cancel(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Get info for cancelling a proposal
func (*SecurityCouncilProposal) Common ¶
func (c *SecurityCouncilProposal) Common() *ProposalCommon
Get the common fields
func (*SecurityCouncilProposal) Execute ¶
func (c *SecurityCouncilProposal) Execute(opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Get info for executing a proposal
func (*SecurityCouncilProposal) GetPayloadAsString ¶
func (c *SecurityCouncilProposal) GetPayloadAsString() (string, error)
Get the proposal's payload as a string
func (*SecurityCouncilProposal) QueryAllFields ¶
func (c *SecurityCouncilProposal) QueryAllFields(mc *batch.MultiCaller)
Get the basic details
func (*SecurityCouncilProposal) VoteOn ¶
func (c *SecurityCouncilProposal) VoteOn(support bool, opts *bind.TransactOpts) (*eth.TransactionInfo, error)
Get info for voting on a proposal