MCPcopy
hub / github.com/nats-io/nats.go / PutString

Method PutString

jetstream/kv.go:1054–1056  ·  view source on GitHub ↗

PutString will place the string for the key into the store.

(ctx context.Context, key string, value string)

Source from the content-addressed store, hash-verified

1052
1053// PutString will place the string for the key into the store.
1054func (kv *kvs) PutString(ctx context.Context, key string, value string) (uint64, error) {
1055 return kv.Put(ctx, key, []byte(value))
1056}
1057
1058// Create will add the key/value pair if it does not exist.
1059func (kv *kvs) Create(ctx context.Context, key string, value []byte, opts ...KVCreateOpt) (revision uint64, err error) {

Callers

nothing calls this directly

Calls 1

PutMethod · 0.95

Tested by

no test coverage detected