pub trait Decidable {
    // Required methods
    fn id(&self) -> Id;
    fn status(&self) -> Status;
    fn accept(&mut self) -> Result<()>;
    fn reject(&mut self) -> Result<()>;
}
Expand description

Represents an element that can be decided. Decidable objects are transactions, blocks, or vertices. ref. https://pkg.go.dev/github.com/ava-labs/avalanchego/snow/choices#Decidable

Required Methods§

source

fn id(&self) -> Id

Returns the ID of this block’s parent.

source

fn status(&self) -> Status

Returns the current status.

source

fn accept(&mut self) -> Result<()>

Accepts this element.

source

fn reject(&mut self) -> Result<()>

Rejects this element.

Implementors§