MCPcopy Create free account
hub / github.com/temporalio/temporal / EncodeString

Function EncodeString

common/payload/payload.go:20–24  ·  view source on GitHub ↗
(str string)

Source from the content-addressed store, hash-verified

18)
19
20func EncodeString(str string) *commonpb.Payload {
21 // Error can be safely ignored here because string always can be converted to JSON
22 p, _ := defaultDataConverter.ToPayload(str)
23 return p
24}
25
26func EncodeBytes(bytes []byte) *commonpb.Payload {
27 // Error can be safely ignored here because []byte always can be raw encoded

Calls 1

ToPayloadMethod · 0.80