MCPcopy Create free account
hub / github.com/AI45Lab/Code / collect_artifact_uris

Function collect_artifact_uris

core/src/verification.rs:500–517  ·  view source on GitHub ↗
(value: &serde_json::Value, uris: &mut Vec<String>)

Source from the content-addressed store, hash-verified

498}
499
500fn collect_artifact_uris(value: &serde_json::Value, uris: &mut Vec<String>) {
501 match value {
502 serde_json::Value::Object(object) => {
503 if let Some(uri) = object.get("artifact_uri").and_then(|value| value.as_str()) {
504 uris.push(uri.to_string());
505 }
506 for value in object.values() {
507 collect_artifact_uris(value, uris);
508 }
509 }
510 serde_json::Value::Array(items) => {
511 for value in items {
512 collect_artifact_uris(value, uris);
513 }
514 }
515 _ => {}
516 }
517}
518
519#[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)]
520pub struct VerificationSummary {

Callers 1

artifact_urisFunction · 0.70

Calls 2

getMethod · 0.45
as_strMethod · 0.45

Tested by

no test coverage detected