pub(super) trait Shred<'a>: Sized {
type SignedData: AsRef<[u8]>;
const SIZE_OF_PAYLOAD: usize;
const SIZE_OF_HEADERS: usize;
// Required methods
fn from_payload(shred: Vec<u8>) -> Result<Self, Error>;
fn common_header(&self) -> &ShredCommonHeader;
fn sanitize(&self) -> Result<(), Error>;
fn set_signature(&mut self, signature: Signature);
fn payload(&self) -> &Vec<u8> ⓘ;
fn into_payload(self) -> Vec<u8> ⓘ;
fn erasure_shard_index(&self) -> Result<usize, Error>;
fn erasure_shard(self) -> Result<Vec<u8>, Error>;
fn erasure_shard_as_slice(&self) -> Result<&[u8], Error>;
fn signed_data(&'a self) -> Result<Self::SignedData, Error>;
fn set_index(&mut self, index: u32);
fn set_slot(&mut self, slot: Slot);
}