utils

package
v1.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 6, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsCanceled

func IsCanceled(err error) bool

func JSONToStruct

func JSONToStruct(data []byte, v interface{}) error

func NewJSONRPCError

func NewJSONRPCError(id string, code int, message string, data interface{}) (*protocol.JSONRPCMessage, error)

func NewJSONRPCNotification

func NewJSONRPCNotification(method string, params interface{}) (*protocol.JSONRPCMessage, error)

func NewJSONRPCRequest

func NewJSONRPCRequest(method string, params interface{}) (*protocol.JSONRPCMessage, error)

func NewJSONRPCResponse

func NewJSONRPCResponse(id string, result interface{}) (*protocol.JSONRPCMessage, error)

func StructToJSON

func StructToJSON(v interface{}) ([]byte, error)

func StructToJSONSchema

func StructToJSONSchema(v interface{}) (protocol.JSONSchema, error)

func ValidateJSONRPCMessage

func ValidateJSONRPCMessage(msg *protocol.JSONRPCMessage) error

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL