validation

package
v0.85.0 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StreamClientInterceptor

func StreamClientInterceptor() grpc.StreamClientInterceptor

StreamClientInterceptor returns a grpc.StreamClientInterceptor that validates inbound and outbound messages. If any streamed service request is invalid, a codes.InvalidArgument is returned. If any streamed service response is invalid, a codes.Internal is returned.

func StreamServerInterceptor

func StreamServerInterceptor() grpc.StreamServerInterceptor

StreamServerInterceptor returns a grpc.StreamServerInterceptor that validates inbound and outbound messages. If an inbound message is invalid, a codes.InvalidArgument is returned. If an outbound message is invalid, a codes.Internal is returned.

func UnaryClientInterceptor

func UnaryClientInterceptor() grpc.UnaryClientInterceptor

UnaryClientInterceptor returns a grpc.UnaryClientInterceptor that validates inbound and outbound messages. If a service request is invalid, a codes.InvalidArgument is returned. If a service response is invalid, a codes.Internal is returned.

func UnaryServerInterceptor

func UnaryServerInterceptor() grpc.UnaryServerInterceptor

UnaryServerInterceptor returns a grpc.UnaryServerInterceptor that validates inbound and outbound messages. If an inbound message is invalid, a codes.InvalidArgument is returned. If an outbound message is invalid, a codes.Internal is returned.

Types

type Validator

type Validator interface {
	Validate() error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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