Trait hotshot_types::traits::node_implementation::NodeType
source · pub trait NodeType:
Clone
+ Copy
+ Debug
+ Hash
+ PartialEq
+ Eq
+ PartialOrd
+ Ord
+ Default
+ Serialize
+ for<'de> Deserialize<'de>
+ Send
+ Sync
+ 'static {
type View: ConsensusTime + Display;
type Epoch: ConsensusTime + Display;
type AuctionResult: Debug + HasUrls + DeserializeOwned + Default + PartialEq + Eq + Clone + Send + Sync;
type BlockHeader: BlockHeader<Self>;
type BlockPayload: BlockPayload<Self, Instance = Self::InstanceState, Transaction = Self::Transaction, ValidatedState = Self::ValidatedState>;
type SignatureKey: SignatureKey;
type Transaction: Transaction;
type InstanceState: InstanceState;
type ValidatedState: ValidatedState<Self, Instance = Self::InstanceState, Time = Self::View>;
type Membership: Membership<Self>;
type BuilderSignatureKey: BuilderSignatureKey;
const EPOCH_HEIGHT: u64;
}
Expand description
Trait with all the type definitions that are used in the current hotshot setup.
Required Associated Types§
sourcetype View: ConsensusTime + Display
type View: ConsensusTime + Display
The time type that this hotshot setup is using.
This should be the same Time
that ValidatedState::Time
is using.
sourcetype Epoch: ConsensusTime + Display
type Epoch: ConsensusTime + Display
Same as above but for epoch.
sourcetype AuctionResult: Debug + HasUrls + DeserializeOwned + Default + PartialEq + Eq + Clone + Send + Sync
type AuctionResult: Debug + HasUrls + DeserializeOwned + Default + PartialEq + Eq + Clone + Send + Sync
The AuctionSolverResult is a type that holds the data associated with a particular solver run, for a particular view.
sourcetype BlockHeader: BlockHeader<Self>
type BlockHeader: BlockHeader<Self>
The block header type that this hotshot setup is using.
sourcetype BlockPayload: BlockPayload<Self, Instance = Self::InstanceState, Transaction = Self::Transaction, ValidatedState = Self::ValidatedState>
type BlockPayload: BlockPayload<Self, Instance = Self::InstanceState, Transaction = Self::Transaction, ValidatedState = Self::ValidatedState>
The block type that this hotshot setup is using.
This should be the same block that ValidatedState::BlockPayload
is using.
sourcetype SignatureKey: SignatureKey
type SignatureKey: SignatureKey
The signature key that this hotshot setup is using.
sourcetype Transaction: Transaction
type Transaction: Transaction
The transaction type that this hotshot setup is using.
This should be equal to BlockPayload::Transaction
sourcetype InstanceState: InstanceState
type InstanceState: InstanceState
The instance-level state type that this hotshot setup is using.
sourcetype ValidatedState: ValidatedState<Self, Instance = Self::InstanceState, Time = Self::View>
type ValidatedState: ValidatedState<Self, Instance = Self::InstanceState, Time = Self::View>
The validated state type that this hotshot setup is using.
sourcetype Membership: Membership<Self>
type Membership: Membership<Self>
Membership used for this implementation
sourcetype BuilderSignatureKey: BuilderSignatureKey
type BuilderSignatureKey: BuilderSignatureKey
The type builder uses to sign its messages
Required Associated Constants§
sourceconst EPOCH_HEIGHT: u64
const EPOCH_HEIGHT: u64
constant for epoch height