protocel

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(files *protoregistry.Files, md protoreflect.MessageDescriptor, celString string) (*protocel, error)

func WithCELContext

func WithCELContext(ctx context.Context, celCtx *CELContext) context.Context

Types

type CELContext

type CELContext struct {
	MethodDescriptor protoreflect.MethodDescriptor
	Req              proto.Message
}

func GetCELContext

func GetCELContext(ctx context.Context) *CELContext

func (*CELContext) ToInput

func (c *CELContext) ToInput() map[string]any

type CELMessage

type CELMessage interface {
	NewMessage(ctx context.Context) (proto.Message, error)
	SetDataOnMessage(ctx context.Context, msg protoreflect.ProtoMessage) error
}

Jump to

Keyboard shortcuts

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