[][src]Trait ckb_standalone_types::prelude::Entity

pub trait Entity: Clone + Default + Debug {
    type Builder: Builder;

    const NAME: &'static str;

    fn new_unchecked(data: Bytes) -> Self;
fn as_bytes(&self) -> Bytes;
fn as_slice(&self) -> &[u8];
fn from_slice(slice: &[u8]) -> Result<Self, VerificationError>;
fn from_compatible_slice(slice: &[u8]) -> Result<Self, VerificationError>;
fn new_builder() -> Self::Builder;
fn as_builder(self) -> Self::Builder; }

Associated Types

type Builder: Builder

Loading content...

Associated Constants

const NAME: &'static str

Loading content...

Required methods

fn new_unchecked(data: Bytes) -> Self

fn as_bytes(&self) -> Bytes

fn as_slice(&self) -> &[u8]

fn from_slice(slice: &[u8]) -> Result<Self, VerificationError>

fn from_compatible_slice(slice: &[u8]) -> Result<Self, VerificationError>

fn new_builder() -> Self::Builder

fn as_builder(self) -> Self::Builder

Loading content...

Implementors

impl Entity for Block[src]

type Builder = BlockBuilder

impl Entity for Byte32[src]

type Builder = Byte32Builder

impl Entity for Byte32Vec[src]

type Builder = Byte32VecBuilder

impl Entity for Bytes[src]

type Builder = BytesBuilder

impl Entity for BytesOpt[src]

type Builder = BytesOptBuilder

impl Entity for BytesVec[src]

type Builder = BytesVecBuilder

impl Entity for CellDep[src]

type Builder = CellDepBuilder

impl Entity for CellDepVec[src]

type Builder = CellDepVecBuilder

impl Entity for CellInput[src]

type Builder = CellInputBuilder

impl Entity for CellInputVec[src]

type Builder = CellInputVecBuilder

impl Entity for CellOutput[src]

type Builder = CellOutputBuilder

impl Entity for CellOutputVec[src]

type Builder = CellOutputVecBuilder

impl Entity for CellbaseWitness[src]

type Builder = CellbaseWitnessBuilder

impl Entity for Header[src]

type Builder = HeaderBuilder

impl Entity for OutPoint[src]

type Builder = OutPointBuilder

impl Entity for ProposalShortId[src]

type Builder = ProposalShortIdBuilder

impl Entity for ProposalShortIdVec[src]

type Builder = ProposalShortIdVecBuilder

impl Entity for RawHeader[src]

type Builder = RawHeaderBuilder

impl Entity for RawTransaction[src]

type Builder = RawTransactionBuilder

impl Entity for Script[src]

type Builder = ScriptBuilder

impl Entity for ScriptOpt[src]

type Builder = ScriptOptBuilder

impl Entity for Transaction[src]

type Builder = TransactionBuilder

impl Entity for TransactionVec[src]

type Builder = TransactionVecBuilder

impl Entity for Uint128[src]

type Builder = Uint128Builder

impl Entity for Uint256[src]

type Builder = Uint256Builder

impl Entity for Uint32[src]

type Builder = Uint32Builder

impl Entity for Uint64[src]

type Builder = Uint64Builder

impl Entity for UncleBlock[src]

type Builder = UncleBlockBuilder

impl Entity for UncleBlockVec[src]

type Builder = UncleBlockVecBuilder

impl Entity for WitnessArgs[src]

type Builder = WitnessArgsBuilder

Loading content...