func GetPrepareDecorators(ctx context.Context, defaultPrepareDecorators ...PrepareDecorator) []PrepareDecorator {
	inCtx := ctx.Value(ctxPrepareDecorators{})
	if pd, ok := inCtx.([]PrepareDecorator); ok {
		return pd
	}
	return defaultPrepareDecorators
}
GetPrepareDecorators returns the PrepareDecorators in the provided context or the provided default PrepareDecorators.
package autorest
import (
	"bytes"
	"context"
	"encoding/json"
	"encoding/xml"
	"fmt"
	"io"
	"io/ioutil"
	"mime/multipart"
	"net/http"
	"net/url"
	"strings"
)
const (
	mimeTypeJSON        = "application/json"
	mimeTypeOctetStream = "application/octet-stream"
	mimeTypeFormPost    = "application/x-www-form-urlencoded"
	headerAuthorization    = "Authorization"
	headerAuxAuthorization = "x-ms-authorization-auxiliary"
	headerContentType      = "Content-Type"
	headerUserAgent        = "User-Agent"
)
type ctxPrepareDecorators struct{}
func WithPrepareDecorators(ctx context.Context, prepareDecorator []PrepareDecorator) context.Context {
	if len(prepareDecorator) == 0 {
		return ctx
	}
	return context.WithValue(ctx, ctxPrepareDecorators{}, prepareDecorator)
}