MCPcopy
hub / github.com/cayleygraph/cayley / valuesFromString

Function valuesFromString

server/http/api_v2.go:304–314  ·  view source on GitHub ↗
(s string)

Source from the content-addressed store, hash-verified

302}
303
304func valuesFromString(s string) []quad.Value {
305 if s == "" {
306 return nil
307 }
308 arr := strings.Split(s, ",")
309 out := make([]quad.Value, 0, len(arr))
310 for _, s := range arr {
311 out = append(out, quad.StringToValue(s))
312 }
313 return out
314}
315
316func (api *APIv2) ServeRead(w http.ResponseWriter, r *http.Request) {
317 format := getFormat(r, "format", hdrAccept)

Callers 1

ServeReadMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected