Skip to main content

KnowledgePackManifest

Trait KnowledgePackManifest 

Source
pub trait KnowledgePackManifest: Send + Sync {
    // Required methods
    fn pack_id(&self) -> &str;
    fn version(&self) -> &str;
    fn schema_version(&self) -> u32;
    fn root_uri(&self) -> &str;
    fn content_hash(&self) -> &str;
    fn docs(&self) -> &[KnowledgeDocManifest];

    // Provided method
    fn read_doc_manifest(&self, selector: &str) -> Option<&KnowledgeDocManifest> { ... }
}
Expand description

Shared read-only metadata contract for any knowledge pack manifest.

This trait intentionally covers only pack identity and document metadata. Concrete pack manifests, such as project or remote manifests, should expose their own sync/cache mutation methods on their concrete types.

Required Methods§

Source

fn pack_id(&self) -> &str

Source

fn version(&self) -> &str

Source

fn schema_version(&self) -> u32

Source

fn root_uri(&self) -> &str

Source

fn content_hash(&self) -> &str

Source

fn docs(&self) -> &[KnowledgeDocManifest]

Provided Methods§

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§