genResponsePayload generates the payload returned at the end of each client request function
(operationID string)
| 116 | |
| 117 | // genResponsePayload generates the payload returned at the end of each client request function |
| 118 | func genResponsePayload(operationID string) string { |
| 119 | var buffer = bytes.NewBufferString("") |
| 120 | |
| 121 | // Here is where we build up a response: |
| 122 | fmt.Fprintf(buffer, "&%s{\n", genResponseTypeName(operationID)) |
| 123 | fmt.Fprintf(buffer, "Body: bodyBytes,\n") |
| 124 | fmt.Fprintf(buffer, "HTTPResponse: rsp,\n") |
| 125 | fmt.Fprintf(buffer, "}") |
| 126 | |
| 127 | return buffer.String() |
| 128 | } |
| 129 | |
| 130 | // genResponseUnmarshal generates unmarshaling steps for structured response payloads |
| 131 | func genResponseUnmarshal(op *OperationDefinition) string { |
nothing calls this directly
no test coverage detected