MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / readJSON

Method readJSON

rest/handler.go:1322–1325  ·  view source on GitHub ↗

Parses a JSON request body, returning it as a Body map.

()

Source from the content-addressed store, hash-verified

1320
1321// Parses a JSON request body, returning it as a Body map.
1322func (h *handler) readJSON() (db.Body, error) {
1323 var body db.Body
1324 return body, h.readJSONInto(&body)
1325}
1326
1327// Parses a JSON request body into a custom structure.
1328func (h *handler) readJSONInto(into interface{}) error {

Callers 6

handlePurgeMethod · 0.95
readDocumentMethod · 0.95
handlePutLocalDocMethod · 0.95
handleAllDocsMethod · 0.95
handleBulkGetMethod · 0.95
handleBulkDocsMethod · 0.95

Calls 1

readJSONIntoMethod · 0.95

Tested by

no test coverage detected