[−][src]Struct ckb_jsonrpc_types::CellOutputWithOutPoint
This is used as return value of get_cells_by_lock_hash
RPC.
It contains both OutPoint data used for referencing a cell, as well as the cell's properties such as lock and capacity.
Examples
# serde_json::from_str::<ckb_jsonrpc_types::CellOutputWithOutPoint>(r#"
{
"block_hash": "0xf293d02ce5e101b160912aaf15b1b87517b7a6d572c13af9ae4101c1143b22ad",
"capacity": "0x2ca86f2642",
"cellbase": true,
"lock": {
"args": "0x",
"code_hash": "0x28e83a1277d48add8e72fadaa9248559e1b632bab2bd60b27955ebc4c03800a5",
"hash_type": "data"
},
"out_point": {
"index": "0x0",
"tx_hash": "0xa510932a80fda15a774203404453c5f9c0e8582f11c40f8ce5396f2460f8ccbf"
},
"output_data_len": "0x0",
"type": null
}
# "#).unwrap();
Fields
out_point: OutPoint
Reference to a cell via transaction hash and output index.
block_hash: H256
The block hash of the block which committed the transaction.
capacity: Capacity
The cell capacity.
The capacity of a cell is the value of the cell in Shannons. It is also the upper limit of the cell occupied storage size where every 100,000,000 Shannons give 1-byte storage.
lock: Script
The lock script.
type_: Option<Script>
The optional type script.
The JSON field name is "type".
output_data_len: Uint64
The bytes count of the cell data.
cellbase: bool
Whether this is a cellbase transaction output.
The cellbase transaction is the first transaction in a block which issues rewards and fees to miners.
The cellbase transaction has a maturity period of 4 epochs. Its output cells can only be used as inputs after 4 epochs.
Trait Implementations
impl Debug for CellOutputWithOutPoint
[src]
impl<'de> Deserialize<'de> for CellOutputWithOutPoint
[src]
pub fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl Serialize for CellOutputWithOutPoint
[src]
Auto Trait Implementations
impl RefUnwindSafe for CellOutputWithOutPoint
[src]
impl Send for CellOutputWithOutPoint
[src]
impl Sync for CellOutputWithOutPoint
[src]
impl Unpin for CellOutputWithOutPoint
[src]
impl UnwindSafe for CellOutputWithOutPoint
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,