Struct identity_iota::client::ResolvedIotaDocument
source · [−]pub struct ResolvedIotaDocument {
pub document: IotaDocument,
pub integration_message_id: MessageId,
pub diff_message_id: MessageId,
}
Expand description
An IOTA DID document resolved from the Tangle. Represents an integration chain message possibly merged with one or more diff messages.
Fields
document: IotaDocument
integration_message_id: MessageId
MessageId
of this integration chain document.
diff_message_id: MessageId
diff chain features are slated for removal
MessageId
of the last diff chain message merged into this during resolution, or null.
Implementations
sourceimpl ResolvedIotaDocument
impl ResolvedIotaDocument
sourcepub fn merge_diff_message(
&mut self,
diff_message: &DiffMessage
) -> Result<(), Error>
👎 Deprecated since 0.5.0: diff chain features are slated for removal
pub fn merge_diff_message(
&mut self,
diff_message: &DiffMessage
) -> Result<(), Error>
diff chain features are slated for removal
Attempts to merge changes from a DiffMessage
into this document and
updates the ResolvedIotaDocument::diff_message_id
.
If merging fails the document remains unmodified, otherwise this represents the merged document state.
Errors
Fails if the merge operation or signature verification on the diff fails.
Trait Implementations
sourceimpl AsRef<IotaDocument> for ResolvedIotaDocument
impl AsRef<IotaDocument> for ResolvedIotaDocument
sourcefn as_ref(&self) -> &IotaDocument
fn as_ref(&self) -> &IotaDocument
Converts this type into a shared reference of the (usually inferred) input type.
sourceimpl Clone for ResolvedIotaDocument
impl Clone for ResolvedIotaDocument
sourcefn clone(&self) -> ResolvedIotaDocument
fn clone(&self) -> ResolvedIotaDocument
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for ResolvedIotaDocument
impl Debug for ResolvedIotaDocument
sourceimpl<'de> Deserialize<'de> for ResolvedIotaDocument
impl<'de> Deserialize<'de> for ResolvedIotaDocument
sourcefn deserialize<__D>(
__deserializer: __D
) -> Result<ResolvedIotaDocument, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<ResolvedIotaDocument, <__D as Deserializer<'de>>::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Display for ResolvedIotaDocument
impl Display for ResolvedIotaDocument
sourceimpl From<IotaDocument> for ResolvedIotaDocument
impl From<IotaDocument> for ResolvedIotaDocument
sourcefn from(document: IotaDocument) -> ResolvedIotaDocument
fn from(document: IotaDocument) -> ResolvedIotaDocument
Converts to this type from the input type.
sourceimpl PartialEq<ResolvedIotaDocument> for ResolvedIotaDocument
impl PartialEq<ResolvedIotaDocument> for ResolvedIotaDocument
sourcefn eq(&self, other: &ResolvedIotaDocument) -> bool
fn eq(&self, other: &ResolvedIotaDocument) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &ResolvedIotaDocument) -> bool
fn ne(&self, other: &ResolvedIotaDocument) -> bool
This method tests for !=
.
sourceimpl Serialize for ResolvedIotaDocument
impl Serialize for ResolvedIotaDocument
sourcefn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
sourceimpl TangleRef for ResolvedIotaDocument
impl TangleRef for ResolvedIotaDocument
fn did(&self) -> &IotaDID
fn message_id(&self) -> &MessageId
fn set_message_id(&mut self, message_id: MessageId)
fn previous_message_id(&self) -> &MessageId
fn set_previous_message_id(&mut self, message_id: MessageId)
sourceimpl TryFromMessage for ResolvedIotaDocument
impl TryFromMessage for ResolvedIotaDocument
fn try_from_message(
message: &Message,
did: &IotaDID
) -> Option<ResolvedIotaDocument>
impl StructuralPartialEq for ResolvedIotaDocument
Auto Trait Implementations
impl RefUnwindSafe for ResolvedIotaDocument
impl Send for ResolvedIotaDocument
impl Sync for ResolvedIotaDocument
impl Unpin for ResolvedIotaDocument
impl UnwindSafe for ResolvedIotaDocument
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> FromJson for T where
T: for<'de> Deserialize<'de>,
impl<T> FromJson for T where
T: for<'de> Deserialize<'de>,
sourcefn from_json(json: &impl AsRef<str>) -> Result<Self, Error>
fn from_json(json: &impl AsRef<str>) -> Result<Self, Error>
Deserialize Self
from a string of JSON text.
sourcefn from_json_slice(json: &impl AsRef<[u8]>) -> Result<Self, Error>
fn from_json_slice(json: &impl AsRef<[u8]>) -> Result<Self, Error>
Deserialize Self
from bytes of JSON text.
sourcefn from_json_value(json: Value) -> Result<Self, Error>
fn from_json_value(json: Value) -> Result<Self, Error>
Deserialize Self
from a [serde_json::Value
].
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> ToJson for T where
T: Serialize,
impl<T> ToJson for T where
T: Serialize,
sourcefn to_json_value(&self) -> Result<Value, Error>
fn to_json_value(&self) -> Result<Value, Error>
Serialize self
as a [serde_json::Value
].
sourcefn to_json_pretty(&self) -> Result<String, Error>
fn to_json_pretty(&self) -> Result<String, Error>
Serialize self
as a pretty-printed string of JSON.
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more