MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / get_message

Method get_message

crates/openshell-server/src/persistence/mod.rs:371–379  ·  view source on GitHub ↗

Fetch and decode a protobuf message by id.

(
        &self,
        id: &str,
    )

Source from the content-addressed store, hash-verified

369
370 /// Fetch and decode a protobuf message by id.
371 pub async fn get_message<T: Message + Default + ObjectType + SetResourceVersion>(
372 &self,
373 id: &str,
374 ) -> PersistenceResult<Option<T>> {
375 self.get(T::object_type(), id)
376 .await?
377 .map(decode_record)
378 .transpose()
379 }
380
381 /// Fetch and decode a protobuf message by name.
382 pub async fn get_message_by_name<T: Message + Default + ObjectType + SetResourceVersion>(

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected