pub enum Document {
V0(DocumentV0),
}Variants§
V0(DocumentV0)
Implementations§
Source§impl Document
impl Document
Sourcepub fn generate_document_id_v0(
contract_id: &Identifier,
owner_id: &Identifier,
document_type_name: &str,
entropy: &[u8],
) -> Identifier
pub fn generate_document_id_v0( contract_id: &Identifier, owner_id: &Identifier, document_type_name: &str, entropy: &[u8], ) -> Identifier
Generates the document ID
Source§impl Document
impl Document
pub fn try_into_asset_unlock_base_transaction_info( &self, transaction_index: WithdrawalTransactionIndex, platform_version: &PlatformVersion, ) -> Result<AssetUnlockBaseTransactionInfo, ProtocolError>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Document
impl<'de> Deserialize<'de> for Document
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl DocumentCborMethodsV0 for Document
impl DocumentCborMethodsV0 for Document
Source§fn from_cbor(
document_cbor: &[u8],
document_id: Option<[u8; 32]>,
owner_id: Option<[u8; 32]>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
fn from_cbor(
document_cbor: &[u8],
document_id: Option<[u8; 32]>,
owner_id: Option<[u8; 32]>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
Reads a CBOR-serialized document and creates a Document from it.
If Document and Owner IDs are provided, they are used, otherwise they are created.
fn to_cbor_value(&self) -> Result<CborValue, ProtocolError>
Source§impl DocumentFromCreateTransition for Document
impl DocumentFromCreateTransition for Document
Source§fn try_from_create_transition(
document_create_transition: &DocumentCreateTransition,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
fn try_from_create_transition(
document_create_transition: &DocumentCreateTransition,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
Attempts to create a new
Document from the given DocumentCreateTransition reference, owner_id, and additional metadata. Read moreSource§fn try_from_owned_create_transition(
document_create_transition: DocumentCreateTransition,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
fn try_from_owned_create_transition(
document_create_transition: DocumentCreateTransition,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
Attempts to create a new
Document from the given DocumentCreateTransition instance, owner_id, and additional metadata. Read moreSource§impl DocumentFromCreateTransitionV0 for Document
impl DocumentFromCreateTransitionV0 for Document
Source§fn try_from_owned_create_transition_v0(
v0: DocumentCreateTransitionV0,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
fn try_from_owned_create_transition_v0(
v0: DocumentCreateTransitionV0,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
Attempts to create a new
Document from the given DocumentCreateTransitionV0 instance, incorporating additional metadata such as ownership and block information. Read moreSource§fn try_from_create_transition_v0(
v0: &DocumentCreateTransitionV0,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
fn try_from_create_transition_v0(
v0: &DocumentCreateTransitionV0,
owner_id: Identifier,
block_info: &BlockInfo,
contract: &DataContract,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>where
Self: Sized,
Attempts to create a new
Document from the given DocumentCreateTransitionV0 reference, incorporating additional metadata like ownership and block information. Read moreSource§impl DocumentFromReplaceTransition for Document
impl DocumentFromReplaceTransition for Document
Source§fn try_from_replace_transition(
document_replace_transition: &DocumentReplaceTransition,
owner_id: Identifier,
created_at: Option<TimestampMillis>,
created_at_block_height: Option<BlockHeight>,
created_at_core_block_height: Option<CoreBlockHeight>,
transferred_at: Option<TimestampMillis>,
transferred_at_block_height: Option<BlockHeight>,
transferred_at_core_block_height: Option<CoreBlockHeight>,
creator_id: Option<Identifier>,
block_info: &BlockInfo,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn try_from_replace_transition( document_replace_transition: &DocumentReplaceTransition, owner_id: Identifier, created_at: Option<TimestampMillis>, created_at_block_height: Option<BlockHeight>, created_at_core_block_height: Option<CoreBlockHeight>, transferred_at: Option<TimestampMillis>, transferred_at_block_height: Option<BlockHeight>, transferred_at_core_block_height: Option<CoreBlockHeight>, creator_id: Option<Identifier>, block_info: &BlockInfo, document_type: &DocumentTypeRef<'_>, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Attempts to create a new
Document from the given DocumentReplaceTransition reference, incorporating owner_id, creation metadata, and additional blockchain-related information. Read moreSource§fn try_from_owned_replace_transition(
document_replace_transition: DocumentReplaceTransition,
owner_id: Identifier,
created_at: Option<TimestampMillis>,
created_at_block_height: Option<BlockHeight>,
created_at_core_block_height: Option<CoreBlockHeight>,
transferred_at: Option<TimestampMillis>,
transferred_at_block_height: Option<BlockHeight>,
transferred_at_core_block_height: Option<CoreBlockHeight>,
creator_id: Option<Identifier>,
block_info: &BlockInfo,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn try_from_owned_replace_transition( document_replace_transition: DocumentReplaceTransition, owner_id: Identifier, created_at: Option<TimestampMillis>, created_at_block_height: Option<BlockHeight>, created_at_core_block_height: Option<CoreBlockHeight>, transferred_at: Option<TimestampMillis>, transferred_at_block_height: Option<BlockHeight>, transferred_at_core_block_height: Option<CoreBlockHeight>, creator_id: Option<Identifier>, block_info: &BlockInfo, document_type: &DocumentTypeRef<'_>, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Attempts to create a new
Document from the given DocumentReplaceTransition instance, incorporating owner_id, creation metadata, and additional blockchain-related information. Read moreSource§impl DocumentFromReplaceTransitionV0 for Document
impl DocumentFromReplaceTransitionV0 for Document
Source§fn try_from_replace_transition_v0(
value: &DocumentReplaceTransitionV0,
owner_id: Identifier,
created_at: Option<TimestampMillis>,
created_at_block_height: Option<BlockHeight>,
created_at_core_block_height: Option<CoreBlockHeight>,
transferred_at: Option<TimestampMillis>,
transferred_at_block_height: Option<BlockHeight>,
transferred_at_core_block_height: Option<CoreBlockHeight>,
creator_id: Option<Identifier>,
block_info: &BlockInfo,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn try_from_replace_transition_v0( value: &DocumentReplaceTransitionV0, owner_id: Identifier, created_at: Option<TimestampMillis>, created_at_block_height: Option<BlockHeight>, created_at_core_block_height: Option<CoreBlockHeight>, transferred_at: Option<TimestampMillis>, transferred_at_block_height: Option<BlockHeight>, transferred_at_core_block_height: Option<CoreBlockHeight>, creator_id: Option<Identifier>, block_info: &BlockInfo, document_type: &DocumentTypeRef<'_>, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Attempts to create a new
Document from the given DocumentReplaceTransitionV0 reference. This operation is typically used to replace or update an existing document with new information. Read moreSource§fn try_from_owned_replace_transition_v0(
value: DocumentReplaceTransitionV0,
owner_id: Identifier,
created_at: Option<TimestampMillis>,
created_at_block_height: Option<BlockHeight>,
created_at_core_block_height: Option<CoreBlockHeight>,
transferred_at: Option<TimestampMillis>,
transferred_at_block_height: Option<BlockHeight>,
transferred_at_core_block_height: Option<CoreBlockHeight>,
creator_id: Option<Identifier>,
block_info: &BlockInfo,
document_type: &DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn try_from_owned_replace_transition_v0( value: DocumentReplaceTransitionV0, owner_id: Identifier, created_at: Option<TimestampMillis>, created_at_block_height: Option<BlockHeight>, created_at_core_block_height: Option<CoreBlockHeight>, transferred_at: Option<TimestampMillis>, transferred_at_block_height: Option<BlockHeight>, transferred_at_core_block_height: Option<CoreBlockHeight>, creator_id: Option<Identifier>, block_info: &BlockInfo, document_type: &DocumentTypeRef<'_>, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Attempts to create a new
Document from the given DocumentReplaceTransitionV0 instance. This function is similar to try_from_replace_transition_v0 but consumes the DocumentReplaceTransitionV0 instance, making it suitable for scenarios where the transition is owned and should not be reused after document creation. Read moreSource§impl DocumentJsonMethodsV0<'_> for Document
impl DocumentJsonMethodsV0<'_> for Document
Source§fn to_json_with_identifiers_using_bytes(
&self,
platform_version: &PlatformVersion,
) -> Result<JsonValue, ProtocolError>
fn to_json_with_identifiers_using_bytes( &self, platform_version: &PlatformVersion, ) -> Result<JsonValue, ProtocolError>
Convert the document to JSON with identifiers using bytes.
Source§fn to_json(
&self,
platform_version: &PlatformVersion,
) -> Result<JsonValue, ProtocolError>
fn to_json( &self, platform_version: &PlatformVersion, ) -> Result<JsonValue, ProtocolError>
Convert the document to a JSON value.
Source§fn from_json_value<S, E>(
document_value: JsonValue,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn from_json_value<S, E>( document_value: JsonValue, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Create a document from a JSON value.
Source§impl DocumentMethodsV0 for Document
impl DocumentMethodsV0 for Document
Source§fn get_raw_for_contract(
&self,
key: &str,
document_type_name: &str,
contract: &DataContract,
owner_id: Option<[u8; 32]>,
platform_version: &PlatformVersion,
) -> Result<Option<Vec<u8>>, ProtocolError>
fn get_raw_for_contract( &self, key: &str, document_type_name: &str, contract: &DataContract, owner_id: Option<[u8; 32]>, platform_version: &PlatformVersion, ) -> Result<Option<Vec<u8>>, ProtocolError>
Return a value given the path to its key and the document type for a contract.
Source§fn get_raw_for_document_type(
&self,
key_path: &str,
document_type: DocumentTypeRef<'_>,
owner_id: Option<[u8; 32]>,
platform_version: &PlatformVersion,
) -> Result<Option<Vec<u8>>, ProtocolError>
fn get_raw_for_document_type( &self, key_path: &str, document_type: DocumentTypeRef<'_>, owner_id: Option<[u8; 32]>, platform_version: &PlatformVersion, ) -> Result<Option<Vec<u8>>, ProtocolError>
Return a value given the path to its key for a document type.
fn hash( &self, contract: &DataContract, document_type: DocumentTypeRef<'_>, platform_version: &PlatformVersion, ) -> Result<Vec<u8>, ProtocolError>
fn increment_revision(&mut self) -> Result<(), ProtocolError>
Source§fn is_equal_ignoring_time_based_fields(
&self,
rhs: &Self,
also_ignore_fields: Option<Vec<&str>>,
platform_version: &PlatformVersion,
) -> Result<bool, ProtocolError>
fn is_equal_ignoring_time_based_fields( &self, rhs: &Self, also_ignore_fields: Option<Vec<&str>>, platform_version: &PlatformVersion, ) -> Result<bool, ProtocolError>
Checks to see if a document is equal without time based fields.
Since these fields are set on the network this function can be useful to make sure that
fields that were supplied have not changed, while ignoring those that are set network side.
Time based fields that are ignored are
created_at/updated_at
created_at_block_height/updated_at_block_height
created_at_core_block_height/updated_at_core_block_height
Source§impl DocumentPlatformConversionMethodsV0 for Document
impl DocumentPlatformConversionMethodsV0 for Document
Source§fn serialize(
&self,
document_type: DocumentTypeRef<'_>,
data_contract: &DataContract,
platform_version: &PlatformVersion,
) -> Result<Vec<u8>, ProtocolError>
fn serialize( &self, document_type: DocumentTypeRef<'_>, data_contract: &DataContract, platform_version: &PlatformVersion, ) -> Result<Vec<u8>, ProtocolError>
Serializes the document.
The serialization of a document follows the pattern: id 32 bytes + owner_id 32 bytes + encoded values byte arrays
Source§fn from_bytes(
serialized_document: &[u8],
document_type: DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn from_bytes( serialized_document: &[u8], document_type: DocumentTypeRef<'_>, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Reads a serialized document and creates a Document from it.
Source§fn serialize_specific_version(
&self,
document_type: DocumentTypeRef<'_>,
data_contract: &DataContract,
feature_version: FeatureVersion,
) -> Result<Vec<u8>, ProtocolError>
fn serialize_specific_version( &self, document_type: DocumentTypeRef<'_>, data_contract: &DataContract, feature_version: FeatureVersion, ) -> Result<Vec<u8>, ProtocolError>
Serializes the document. Read more
Source§fn from_bytes_in_consensus(
serialized_document: &[u8],
document_type: DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<ConsensusValidationResult<Self>, ProtocolError>where
Self: Sized,
fn from_bytes_in_consensus(
serialized_document: &[u8],
document_type: DocumentTypeRef<'_>,
platform_version: &PlatformVersion,
) -> Result<ConsensusValidationResult<Self>, ProtocolError>where
Self: Sized,
Reads a serialized document and creates a Document from it.
This will return a ConsensusValidationResult instead when the error is happening
in consensus (deserialization of a message from the network)
Source§impl DocumentPlatformValueMethodsV0<'_> for Document
impl DocumentPlatformValueMethodsV0<'_> for Document
Source§fn to_map_value(&self) -> Result<BTreeMap<String, Value>, ProtocolError>
fn to_map_value(&self) -> Result<BTreeMap<String, Value>, ProtocolError>
Convert the document to a map value.
Source§fn into_map_value(self) -> Result<BTreeMap<String, Value>, ProtocolError>
fn into_map_value(self) -> Result<BTreeMap<String, Value>, ProtocolError>
Convert the document to a map value consuming the document.
Source§fn into_value(self) -> Result<Value, ProtocolError>
fn into_value(self) -> Result<Value, ProtocolError>
Convert the document to a value consuming the document.
Source§fn to_object(&self) -> Result<Value, ProtocolError>
fn to_object(&self) -> Result<Value, ProtocolError>
Convert the document to an object.
Source§fn from_platform_value(
document_value: Value,
platform_version: &PlatformVersion,
) -> Result<Self, ProtocolError>
fn from_platform_value( document_value: Value, platform_version: &PlatformVersion, ) -> Result<Self, ProtocolError>
Create a document from a platform value.
Source§impl DocumentV0Getters for Document
impl DocumentV0Getters for Document
Source§fn id(&self) -> Identifier
fn id(&self) -> Identifier
Returns the unique document ID.
fn id_ref(&self) -> &Identifier
Source§fn owner_id(&self) -> Identifier
fn owner_id(&self) -> Identifier
Returns the ID of the document’s owner.
fn owner_id_ref(&self) -> &Identifier
Source§fn properties(&self) -> &BTreeMap<String, Value>
fn properties(&self) -> &BTreeMap<String, Value>
Returns the document’s properties (data).
Source§fn properties_mut(&mut self) -> &mut BTreeMap<String, Value>
fn properties_mut(&mut self) -> &mut BTreeMap<String, Value>
Returns a mutable reference to the document’s properties (data).
fn properties_consumed(self) -> BTreeMap<String, Value>
Source§fn created_at(&self) -> Option<TimestampMillis>
fn created_at(&self) -> Option<TimestampMillis>
Returns the time in milliseconds that the document was created.
Source§fn updated_at(&self) -> Option<TimestampMillis>
fn updated_at(&self) -> Option<TimestampMillis>
Returns the time in milliseconds that the document was last updated.
Source§fn transferred_at(&self) -> Option<TimestampMillis>
fn transferred_at(&self) -> Option<TimestampMillis>
Returns the time in milliseconds that the document was last transferred.
fn created_at_block_height(&self) -> Option<BlockHeight>
fn updated_at_block_height(&self) -> Option<BlockHeight>
fn transferred_at_block_height(&self) -> Option<BlockHeight>
fn created_at_core_block_height(&self) -> Option<CoreBlockHeight>
fn updated_at_core_block_height(&self) -> Option<CoreBlockHeight>
fn transferred_at_core_block_height(&self) -> Option<CoreBlockHeight>
fn creator_id(&self) -> Option<Identifier>
Source§impl DocumentV0Setters for Document
impl DocumentV0Setters for Document
Source§fn set_id(&mut self, id: Identifier)
fn set_id(&mut self, id: Identifier)
Sets the unique document ID.
Source§fn set_owner_id(&mut self, owner_id: Identifier)
fn set_owner_id(&mut self, owner_id: Identifier)
Sets the ID of the document’s owner.
Source§fn set_properties(&mut self, properties: BTreeMap<String, Value>)
fn set_properties(&mut self, properties: BTreeMap<String, Value>)
Sets the document’s properties (data).
Source§fn set_revision(&mut self, revision: Option<Revision>)
fn set_revision(&mut self, revision: Option<Revision>)
Sets the document revision.
fn bump_revision(&mut self)
Source§fn set_created_at(&mut self, created_at: Option<TimestampMillis>)
fn set_created_at(&mut self, created_at: Option<TimestampMillis>)
Sets the time in milliseconds that the document was created.
Source§fn set_updated_at(&mut self, updated_at: Option<TimestampMillis>)
fn set_updated_at(&mut self, updated_at: Option<TimestampMillis>)
Sets the time in milliseconds that the document was last updated.
fn set_transferred_at(&mut self, transferred_at: Option<TimestampMillis>)
fn set_created_at_block_height(&mut self, created_at_block_height: Option<u64>)
fn set_updated_at_block_height(&mut self, updated_at_block_height: Option<u64>)
fn set_transferred_at_block_height( &mut self, transferred_at_block_height: Option<u64>, )
fn set_created_at_core_block_height( &mut self, created_at_core_block_height: Option<u32>, )
fn set_updated_at_core_block_height( &mut self, updated_at_core_block_height: Option<u32>, )
fn set_transferred_at_core_block_height( &mut self, transferred_at_core_block_height: Option<u32>, )
Source§fn set_creator_id(&mut self, creator_id: Option<Identifier>)
fn set_creator_id(&mut self, creator_id: Option<Identifier>)
Sets the creator identifier of the document. This is applicable if the document’s
schema requires this information. Read more
Source§fn set(&mut self, path: &str, value: Value)
fn set(&mut self, path: &str, value: Value)
Set the value under the given path.
The path supports syntax from the
lodash JS library. Example: “root.people[0].name”.
If parents are not present, they will be automatically created.Source§fn remove(&mut self, path: &str) -> Option<Value>
fn remove(&mut self, path: &str) -> Option<Value>
Removes the value under the given path.
The path supports syntax from the
lodash JS library. Example: “root.people[0].name”.
If parents are not present, they will be automatically created.Source§fn set_u8(&mut self, property_name: &str, value: u8)
fn set_u8(&mut self, property_name: &str, value: u8)
Sets a
u8 value for the specified property name.Source§fn set_i8(&mut self, property_name: &str, value: i8)
fn set_i8(&mut self, property_name: &str, value: i8)
Sets an
i8 value for the specified property name.Source§fn set_u16(&mut self, property_name: &str, value: u16)
fn set_u16(&mut self, property_name: &str, value: u16)
Sets a
u16 value for the specified property name.Source§fn set_i16(&mut self, property_name: &str, value: i16)
fn set_i16(&mut self, property_name: &str, value: i16)
Sets an
i16 value for the specified property name.Source§fn set_u32(&mut self, property_name: &str, value: u32)
fn set_u32(&mut self, property_name: &str, value: u32)
Sets a
u32 value for the specified property name.Source§fn set_i32(&mut self, property_name: &str, value: i32)
fn set_i32(&mut self, property_name: &str, value: i32)
Sets an
i32 value for the specified property name.Source§fn set_u64(&mut self, property_name: &str, value: u64)
fn set_u64(&mut self, property_name: &str, value: u64)
Sets a
u64 value for the specified property name.Source§impl From<DocumentV0> for Document
impl From<DocumentV0> for Document
Source§fn from(value: DocumentV0) -> Self
fn from(value: DocumentV0) -> Self
Converts to this type from the input type.
Source§impl TryFrom<StateTransitionProofResult> for Document
impl TryFrom<StateTransitionProofResult> for Document
Source§type Error = TryIntoError<StateTransitionProofResult>
type Error = TryIntoError<StateTransitionProofResult>
The type returned in the event of a conversion error.
impl StructuralPartialEq for Document
Auto Trait Implementations§
impl Freeze for Document
impl RefUnwindSafe for Document
impl Send for Document
impl Sync for Document
impl Unpin for Document
impl UnwindSafe for Document
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Conv for T
impl<T> Conv for T
§impl<T> CostsExt for T
impl<T> CostsExt for T
§fn wrap_with_cost(self, cost: OperationCost) -> CostContext<Self>where
Self: Sized,
fn wrap_with_cost(self, cost: OperationCost) -> CostContext<Self>where
Self: Sized,
Wraps any value into a
CostContext object with provided costs.§fn wrap_fn_cost(
self,
f: impl FnOnce(&Self) -> OperationCost,
) -> CostContext<Self>where
Self: Sized,
fn wrap_fn_cost(
self,
f: impl FnOnce(&Self) -> OperationCost,
) -> CostContext<Self>where
Self: Sized,
Wraps any value into
CostContext object with costs computed using the
value getting wrapped.§impl<T> FmtForward for T
impl<T> FmtForward for T
§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
Causes
self to use its Binary implementation when Debug-formatted.§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
Causes
self to use its Display implementation when
Debug-formatted.§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
Causes
self to use its LowerExp implementation when
Debug-formatted.§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
Causes
self to use its LowerHex implementation when
Debug-formatted.§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
Causes
self to use its Octal implementation when Debug-formatted.§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
Causes
self to use its Pointer implementation when
Debug-formatted.§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
Causes
self to use its UpperExp implementation when
Debug-formatted.§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
Causes
self to use its UpperHex implementation when
Debug-formatted.§fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
fn fmt_list(self) -> FmtList<Self>where
&'a Self: for<'a> IntoIterator,
Formats each item in a sequence. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T, U> IntoOnNetwork<U> for Twhere
U: FromOnNetwork<T>,
impl<T, U> IntoOnNetwork<U> for Twhere
U: FromOnNetwork<T>,
§fn into_on_network(self, network: Network) -> U
fn into_on_network(self, network: Network) -> U
Calls U::from_on_network(self).
§impl<T, U> IntoPlatformVersioned<U> for Twhere
U: FromPlatformVersioned<T>,
impl<T, U> IntoPlatformVersioned<U> for Twhere
U: FromPlatformVersioned<T>,
§fn into_platform_versioned(self, platform_version: &PlatformVersion) -> U
fn into_platform_versioned(self, platform_version: &PlatformVersion) -> U
Performs the conversion.
§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
Pipes by value. This is generally the method you want to use. Read more
§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
Borrows
self and passes that borrow into the pipe function. Read more§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
Mutably borrows
self and passes that borrow into the pipe function. Read more§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
Borrows
self, then passes self.as_ref() into the pipe function.§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
Mutably borrows
self, then passes self.as_mut() into the pipe
function.§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
Borrows
self, then passes self.deref() into the pipe function.§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> Tap for T
impl<T> Tap for T
§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Immutable access to the
Borrow<B> of a value. Read more§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
Mutable access to the
BorrowMut<B> of a value. Read more§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
Immutable access to the
AsRef<R> view of a value. Read more§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
Mutable access to the
AsMut<R> view of a value. Read more§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Immutable access to the
Deref::Target of a value. Read more§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Mutable access to the
Deref::Target of a value. Read more§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
Calls
.tap() only in debug builds, and is erased in release builds.§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
Calls
.tap_mut() only in debug builds, and is erased in release
builds.§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
Calls
.tap_borrow() only in debug builds, and is erased in release
builds.§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
Calls
.tap_borrow_mut() only in debug builds, and is erased in release
builds.§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
Calls
.tap_ref() only in debug builds, and is erased in release
builds.§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
Calls
.tap_ref_mut() only in debug builds, and is erased in release
builds.§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
Calls
.tap_deref() only in debug builds, and is erased in release
builds.§impl<T> TryConv for T
impl<T> TryConv for T
§impl<T, U> TryIntoPlatformVersioned<U> for Twhere
U: TryFromPlatformVersioned<T>,
impl<T, U> TryIntoPlatformVersioned<U> for Twhere
U: TryFromPlatformVersioned<T>,
§type Error = <U as TryFromPlatformVersioned<T>>::Error
type Error = <U as TryFromPlatformVersioned<T>>::Error
The type returned in the event of a conversion error.
§fn try_into_platform_versioned(
self,
platform_version: &PlatformVersion,
) -> Result<U, <U as TryFromPlatformVersioned<T>>::Error>
fn try_into_platform_versioned( self, platform_version: &PlatformVersion, ) -> Result<U, <U as TryFromPlatformVersioned<T>>::Error>
Performs the conversion.
§impl<T, U> TryIntoVersioned<U> for Twhere
U: TryFromVersioned<T>,
impl<T, U> TryIntoVersioned<U> for Twhere
U: TryFromVersioned<T>,
§type Error = <U as TryFromVersioned<T>>::Error
type Error = <U as TryFromVersioned<T>>::Error
The type returned in the event of a conversion error.
§fn try_into_versioned(
self,
grove_version: &GroveVersion,
) -> Result<U, <U as TryFromVersioned<T>>::Error>
fn try_into_versioned( self, grove_version: &GroveVersion, ) -> Result<U, <U as TryFromVersioned<T>>::Error>
Performs the conversion.