MCPcopy
hub / github.com/minio/minio-go / toQueryValues

Method toQueryValues

api-get-options.go:192–210  ·  view source on GitHub ↗

toQueryValues - Convert the versionId, partNumber, and reqParams in Options to query string parameters.

()

Source from the content-addressed store, hash-verified

190
191// toQueryValues - Convert the versionId, partNumber, and reqParams in Options to query string parameters.
192func (o *GetObjectOptions) toQueryValues() url.Values {
193 urlValues := make(url.Values)
194 if o.VersionID != "" {
195 urlValues.Set("versionId", o.VersionID)
196 }
197 if o.PartNumber > 0 {
198 urlValues.Set("partNumber", strconv.Itoa(o.PartNumber))
199 }
200
201 if o.reqParams != nil {
202 for key, values := range o.reqParams {
203 for _, value := range values {
204 urlValues.Add(key, value)
205 }
206 }
207 }
208
209 return urlValues
210}

Callers 3

StatObjectMethod · 0.45
getObjectMethod · 0.45
PromptObjectMethod · 0.45

Calls 2

SetMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected