// WithReturnBody sets Riak to return the value within its response after completing the write
// operation
507785
func (builder *UpdateSetCommandBuilder) WithReturnBody(returnBody bool) *UpdateSetCommandBuilder {
	builder.protobuf.ReturnBody = &returnBody
	return builder
}
854453
func (builder *SecondaryIndexQueryCommandBuilder) WithReturnKeyAndIndex(val bool) *SecondaryIndexQueryCommandBuilder {
	builder.protobuf.ReturnTerms = &val
	return builder
}
753772
func (o *AcceptConsentRequestParams) WithBody(body *models.HandledConsentRequest) *AcceptConsentRequestParams {
	o.SetBody(body)
	return o
}
1118583
func (o *AcceptLoginRequestParams) WithBody(body *models.HandledLoginRequest) *AcceptLoginRequestParams {
	o.SetBody(body)
	return o
}
288809
func (c *Client) drainBody(body io.ReadCloser) {
	defer body.Close()
	_, err := io.Copy(ioutil.Discard, io.LimitReader(body, respReadLimit))
	if err != nil {
		if c.Logger != nil {
			c.Logger.Printf("[ERR] error reading response body: %v", err)
		}
	}
}
907747
func (h *HTTPBin) RequestWithBody(w http.ResponseWriter, r *http.Request) {
	resp := &bodyResponse{
		Args:    r.URL.Query(),
		Headers: getRequestHeaders(r),
		Origin:  getOrigin(r),
		URL:     getURL(r).String(),
	}

	err := parseBody(w, r, resp)
	if err != nil {
		http.Error(w, fmt.Sprintf("error parsing request body: %s", err), http.StatusBadRequest)
		return
	}

	body, _ := json.Marshal(resp)
	writeJSON(w, body, http.StatusOK)
}
817792
func WithResponse(parent context.Context, value *Response) context.Context {
	return context.WithValue(contextOrBackground(parent), keyResponse, value)
}
1320867
func (b *RouteBuilder) DefaultReturns(message string, model interface{}) *RouteBuilder {
	b.defaultResponse = &ResponseError{
		Message: message,
		Model:   model,
	}
	return b
}
799718
func (o *PetCreateParams) WithBody(body *models.Pet) *PetCreateParams {
	o.SetBody(body)
	return o
}
255714
func (c *client) withRetry(ctx context.Context, f func() error) error {
	var lastError error
	for {
		select {
		case <-ctx.Done():
			return fmt.Errorf("%v: %v", ctx.Err(), lastError)
		default:
		}
		if err := f(); err != nil {
			if st, ok := status.FromError(err); ok {
				code := st.Code()
				if code == codes.Unavailable {
					lastError = err
					time.Sleep(100 * time.Millisecond)
					continue
				}
			}
			return err
		}
		return nil
	}
}
65636
func (p *PullRequest) GetBody() string {
	if p == nil || p.Body == nil {
		return ""
	}
	return *p.Body
}
856688
func (b *Block) WithBody(transactions []*Transaction, uncles []*Header) *Block {
	block := &Block{
		header:       CopyHeader(b.header),
		transactions: make([]*Transaction, len(transactions)),
		uncles:       make([]*Header, len(uncles)),
	}
	copy(block.transactions, transactions)
	for i := range uncles {
		block.uncles[i] = CopyHeader(uncles[i])
	}
	return block
}
974184
func (self *simplePBundle) SetReturnHeader(k string, v string) {
	self.out[k] = v
}
1337397
func (remote *RemoteDebugger) GetResponseBody(req string) ([]byte, error) {
	res, err := remote.SendRequest("Network.getResponseBody", Params{
		"requestId": req,
	})

	if err != nil {
		return nil, err
	}

	body := res["body"]
	if body == nil {
		return nil, nil
	}

	if b, ok := res["base64Encoded"]; ok && b.(bool) {
		return base64.StdEncoding.DecodeString(body.(string))
	} else {
		return []byte(body.(string)), nil
	}
}
726340
func (o *CreateOAuth2ClientParams) WithBody(body *models.Client) *CreateOAuth2ClientParams {
	o.SetBody(body)
	return o
}
796850
func (c *Client) NewRequestWithBody(method, path string, body io.Reader) *Request {
	r := c.NewRequest(method, path)

	// Set request body
	r.body = body

	return r
}
259237
func ErrorBody(body string, v ...interface{}) string {
	return fmt.Sprintf("%s\n", wordwrap.WrapString(fmt.Sprintf(body, v...), 40))
}