MCPcopy Create free account
hub / github.com/MegEngine/MegFlow / describe_responses

Method describe_responses

flow-plugins/src/utils/image.rs:57–78  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

55
56impl ResponseEntity for Image {
57 fn describe_responses() -> Responses {
58 let mut resps = IndexMap::new();
59
60 let mut content = IndexMap::new();
61 content.insert(
62 Cow::Borrowed("image/jpeg"),
63 MediaType {
64 schema: Some(ObjectOrReference::Object(Self::describe())),
65 examples: None,
66 encoding: Default::default(),
67 },
68 );
69
70 resps.insert(
71 Cow::Borrowed("200"),
72 Response {
73 content,
74 ..Default::default()
75 },
76 );
77 resps
78 }
79}
80
81impl Deref for Image {

Callers

nothing calls this directly

Calls 1

insertMethod · 0.80

Tested by

no test coverage detected