pub struct ContextManifest {
pub entries: Vec<ContextEntry>,
pub digest: String,
}Expand description
Every part of one call, sorted by kind and reference.
Fields§
§entries: Vec<ContextEntry>The parts.
digest: StringHex SHA-256 of ContextManifest::canonical.
Implementations§
Source§impl ContextManifest
impl ContextManifest
Sourcepub fn canonical(entries: &[ContextEntry]) -> String
pub fn canonical(entries: &[ContextEntry]) -> String
The entries’ canonical JSON (sorted): what the digest is over.
Sourcepub fn of(entries: Vec<ContextEntry>, hash: impl Fn(&[u8]) -> String) -> Self
pub fn of(entries: Vec<ContextEntry>, hash: impl Fn(&[u8]) -> String) -> Self
The entries, sorted, with the digest hash gives over them.
Sourcepub fn of_kind(&self, kind: ContextKind) -> impl Iterator<Item = &ContextEntry>
pub fn of_kind(&self, kind: ContextKind) -> impl Iterator<Item = &ContextEntry>
The entries of kind.
Trait Implementations§
Source§impl Clone for ContextManifest
impl Clone for ContextManifest
Source§impl Debug for ContextManifest
impl Debug for ContextManifest
Source§impl Default for ContextManifest
impl Default for ContextManifest
Source§impl<'de> Deserialize<'de> for ContextManifest
impl<'de> Deserialize<'de> for ContextManifest
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
impl Eq for ContextManifest
Source§impl JsonSchema for ContextManifest
impl JsonSchema for ContextManifest
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for ContextManifest
impl PartialEq for ContextManifest
Source§impl Serialize for ContextManifest
impl Serialize for ContextManifest
impl StructuralPartialEq for ContextManifest
Auto Trait Implementations§
impl Freeze for ContextManifest
impl RefUnwindSafe for ContextManifest
impl Send for ContextManifest
impl Sync for ContextManifest
impl Unpin for ContextManifest
impl UnsafeUnpin for ContextManifest
impl UnwindSafe for ContextManifest
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