DocumentProfile
yosoi::DocumentProfile
pub struct DocumentProfile
Validated interpretation contract for one immutable payload.
Source: crates/yosoi/src/internal/documents/document_profile.rs:110
SDK re-export: Source: crates/yosoi/src/lib.rs:32
Methods
Section titled “Methods”accessibility_tree_v1
Section titled “accessibility_tree_v1”pub const fn accessibility_tree_v1(epoch: yosoi::documents::DocumentEpoch) -> Self
Declares a version-1 accessibility JSON snapshot at the supplied positive epoch. This does not capture a browser or validate payload membership in that epoch.
Source: crates/yosoi/src/internal/documents/document_profile.rs:171
pub const fn class(self) -> Result<yosoi::documents::DocumentClass, DocumentProfileError>
Resolves a supported capability class after checking all metadata axes together.
Returns [DocumentProfileError] for incompatible schema/syntax or epoch
presence. Resolution does not parse bytes or prove evidence completeness.
Source: crates/yosoi/src/internal/documents/document_profile.rs:212
pub const fn epoch(self) -> Option<yosoi::documents::DocumentEpoch>
Returns snapshot-local generation for rendered evidence, absent for source payloads.
Source: crates/yosoi/src/internal/documents/document_profile.rs:205
rendered_dom
Section titled “rendered_dom”pub const fn rendered_dom(epoch: yosoi::documents::DocumentEpoch) -> Self
Declares a version-1 rendered-DOM JSON snapshot at the supplied positive epoch. This does not capture a browser or validate payload membership in that epoch.
Source: crates/yosoi/src/internal/documents/document_profile.rs:160
representation
Section titled “representation”pub const fn representation(self) -> yosoi::documents::DocumentRepresentation
Returns whether this profile interprets source, rendered-DOM, or accessibility evidence.
Source: crates/yosoi/src/internal/documents/document_profile.rs:190
schema
Section titled “schema”pub const fn schema(self) -> yosoi::documents::DocumentSchemaProfile
Returns the exact parser or versioned snapshot-schema interpretation.
Source: crates/yosoi/src/internal/documents/document_profile.rs:200
source_format
Section titled “source_format”pub const fn source_format(self) -> yosoi::documents::SourceFormat
Returns the syntax expected for the owned payload bytes.
Source: crates/yosoi/src/internal/documents/document_profile.rs:195
source_html
Section titled “source_html”pub const fn source_html() -> Self
Creates HTML5 source metadata without a snapshot epoch or document acquisition.
Source: crates/yosoi/src/internal/documents/document_profile.rs:139
source_json
Section titled “source_json”pub const fn source_json() -> Self
Creates RFC 8259 source JSON metadata without an epoch or acquisition.
Source: crates/yosoi/src/internal/documents/document_profile.rs:149
source_text
Section titled “source_text”pub const fn source_text() -> Self
Creates UTF-8 source text metadata without an epoch or acquisition.
Source: crates/yosoi/src/internal/documents/document_profile.rs:154
source_xml
Section titled “source_xml”pub const fn source_xml() -> Self
Creates XML 1.0 source metadata without an epoch or document acquisition.
Source: crates/yosoi/src/internal/documents/document_profile.rs:144
try_new
Section titled “try_new”pub fn try_new(representation: yosoi::documents::DocumentRepresentation, source_format: yosoi::documents::SourceFormat, schema: yosoi::documents::DocumentSchemaProfile, epoch: Option<yosoi::documents::DocumentEpoch>) -> Result<Self, DocumentProfileError>
Validates representation, payload syntax, schema, and optional epoch as one profile.
Returns [DocumentProfileError] for incompatible axes or incorrect epoch
presence. This validates interpretation metadata, not payload bytes or
live browser state; parsing and evidence acquisition are separate phases.
Source: crates/yosoi/src/internal/documents/document_profile.rs:122
Trait implementations
Section titled “Trait implementations”Clone
fn clone(&self) -> yosoi::DocumentProfile
Source: crates/yosoi/src/internal/documents/document_profile.rs:108
Debug
fn fmt(&self, f: &mut $crate::fmt::Formatter<'_>) -> $crate::fmt::Result
Source: crates/yosoi/src/internal/documents/document_profile.rs:108
Deserialize
deserialize
Section titled “deserialize”fn deserialize<D>(deserializer: D) -> Result<Self, <D as >::Error> where D: Deserializer<'de>
Source: crates/yosoi/src/internal/documents/document_profile.rs:270
PartialEq
fn eq(&self, other: &yosoi::DocumentProfile) -> bool
Source: crates/yosoi/src/internal/documents/document_profile.rs:108
Serialize
serialize
Section titled “serialize”fn serialize<__S>(&self, __serializer: __S) -> _serde::__private229::Result<<__S as >::Ok, <__S as >::Error> where __S: _serde::Serializer
Source: crates/yosoi/src/internal/documents/document_profile.rs:108