MCPcopy Create free account
hub / github.com/goadesign/goa / MarshalXML

Method MarshalXML

http/error.go:61–79  ·  view source on GitHub ↗
(e *xml.Encoder, _ xml.StartElement)

Source from the content-addressed store, hash-verified

59}
60
61func (resp *ErrorResponse) MarshalXML(e *xml.Encoder, _ xml.StartElement) error {
62 return e.Encode(struct {
63 XMLName xml.Name
64 Name string `xml:"name"`
65 ID string `xml:"id"`
66 Message string `xml:"message"`
67 Temporary bool `xml:"temporary"`
68 Timeout bool `xml:"timeout"`
69 Fault bool `xml:"fault"`
70 }{
71 XMLName: ErrorResponseXMLName,
72 Name: resp.Name,
73 ID: resp.ID,
74 Message: resp.Message,
75 Temporary: resp.Temporary,
76 Timeout: resp.Timeout,
77 Fault: resp.Fault,
78 })
79}
80
81// StatusCode implements a heuristic that computes a HTTP response status code
82// appropriate for the timeout, temporary and fault characteristics of the

Callers

nothing calls this directly

Calls 1

EncodeMethod · 0.65

Tested by

no test coverage detected