MCPcopy
hub / github.com/danielgtaylor/huma / MarshalJSON

Method MarshalJSON

openapi.go:305–313  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

303}
304
305func (e *Example) MarshalJSON() ([]byte, error) {
306 return marshalJSON([]jsonFieldInfo{
307 {"$ref", e.Ref, omitEmpty},
308 {"summary", e.Summary, omitEmpty},
309 {"description", e.Description, omitEmpty},
310 {"value", e.Value, omitNil},
311 {"externalValue", e.ExternalValue, omitEmpty},
312 }, e.Extensions)
313}
314
315// Encoding is a single encoding definition applied to a single schema property.
316//

Callers

nothing calls this directly

Calls 1

marshalJSONFunction · 0.85

Tested by

no test coverage detected