pb

package
v0.0.0-...-a1e0f3c Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LoggerRequest_Actions_name = map[int32]string{
		0: "REGISTER",
		1: "LOGIN",
		2: "CREATE",
		3: "UPDATE",
		4: "GET",
		5: "DELETE",
	}
	LoggerRequest_Actions_value = map[string]int32{
		"REGISTER": 0,
		"LOGIN":    1,
		"CREATE":   2,
		"UPDATE":   3,
		"GET":      4,
		"DELETE":   5,
	}
)

Enum value maps for LoggerRequest_Actions.

View Source
var (
	LoggerRequest_Entities_name = map[int32]string{
		0: "USER",
		1: "BOOK",
	}
	LoggerRequest_Entities_value = map[string]int32{
		"USER": 0,
		"BOOK": 1,
	}
)

Enum value maps for LoggerRequest_Entities.

View Source
var File_logger_proto protoreflect.FileDescriptor
View Source
var LoggerService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "logger.LoggerService",
	HandlerType: (*LoggerServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Log",
			Handler:    _LoggerService_Log_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "logger.proto",
}

LoggerService_ServiceDesc is the grpc.ServiceDesc for LoggerService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterLoggerServiceServer

func RegisterLoggerServiceServer(s grpc.ServiceRegistrar, srv LoggerServiceServer)

Types

type EmptyResponse

type EmptyResponse struct {
	// contains filtered or unexported fields
}

func (*EmptyResponse) Descriptor deprecated

func (*EmptyResponse) Descriptor() ([]byte, []int)

Deprecated: Use EmptyResponse.ProtoReflect.Descriptor instead.

func (*EmptyResponse) ProtoMessage

func (*EmptyResponse) ProtoMessage()

func (*EmptyResponse) ProtoReflect

func (x *EmptyResponse) ProtoReflect() protoreflect.Message

func (*EmptyResponse) Reset

func (x *EmptyResponse) Reset()

func (*EmptyResponse) String

func (x *EmptyResponse) String() string

type LoggerRequest

type LoggerRequest struct {
	Action    LoggerRequest_Actions  `protobuf:"varint,1,opt,name=action,proto3,enum=logger.LoggerRequest_Actions" json:"action,omitempty"`
	Entity    LoggerRequest_Entities `protobuf:"varint,2,opt,name=entity,proto3,enum=logger.LoggerRequest_Entities" json:"entity,omitempty"`
	EntityId  int64                  `protobuf:"varint,3,opt,name=entity_id,json=entityId,proto3" json:"entity_id,omitempty"`
	Timestamp *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	// contains filtered or unexported fields
}

func (*LoggerRequest) Descriptor deprecated

func (*LoggerRequest) Descriptor() ([]byte, []int)

Deprecated: Use LoggerRequest.ProtoReflect.Descriptor instead.

func (*LoggerRequest) GetAction

func (x *LoggerRequest) GetAction() LoggerRequest_Actions

func (*LoggerRequest) GetEntity

func (x *LoggerRequest) GetEntity() LoggerRequest_Entities

func (*LoggerRequest) GetEntityId

func (x *LoggerRequest) GetEntityId() int64

func (*LoggerRequest) GetTimestamp

func (x *LoggerRequest) GetTimestamp() *timestamppb.Timestamp

func (*LoggerRequest) ProtoMessage

func (*LoggerRequest) ProtoMessage()

func (*LoggerRequest) ProtoReflect

func (x *LoggerRequest) ProtoReflect() protoreflect.Message

func (*LoggerRequest) Reset

func (x *LoggerRequest) Reset()

func (*LoggerRequest) String

func (x *LoggerRequest) String() string

type LoggerRequest_Actions

type LoggerRequest_Actions int32
const (
	LoggerRequest_REGISTER LoggerRequest_Actions = 0
	LoggerRequest_LOGIN    LoggerRequest_Actions = 1
	LoggerRequest_CREATE   LoggerRequest_Actions = 2
	LoggerRequest_UPDATE   LoggerRequest_Actions = 3
	LoggerRequest_GET      LoggerRequest_Actions = 4
	LoggerRequest_DELETE   LoggerRequest_Actions = 5
)

func (LoggerRequest_Actions) Descriptor

func (LoggerRequest_Actions) Enum

func (LoggerRequest_Actions) EnumDescriptor deprecated

func (LoggerRequest_Actions) EnumDescriptor() ([]byte, []int)

Deprecated: Use LoggerRequest_Actions.Descriptor instead.

func (LoggerRequest_Actions) Number

func (LoggerRequest_Actions) String

func (x LoggerRequest_Actions) String() string

func (LoggerRequest_Actions) Type

type LoggerRequest_Entities

type LoggerRequest_Entities int32
const (
	LoggerRequest_USER LoggerRequest_Entities = 0
	LoggerRequest_BOOK LoggerRequest_Entities = 1
)

func (LoggerRequest_Entities) Descriptor

func (LoggerRequest_Entities) Enum

func (LoggerRequest_Entities) EnumDescriptor deprecated

func (LoggerRequest_Entities) EnumDescriptor() ([]byte, []int)

Deprecated: Use LoggerRequest_Entities.Descriptor instead.

func (LoggerRequest_Entities) Number

func (LoggerRequest_Entities) String

func (x LoggerRequest_Entities) String() string

func (LoggerRequest_Entities) Type

type LoggerServiceClient

type LoggerServiceClient interface {
	Log(ctx context.Context, in *LoggerRequest, opts ...grpc.CallOption) (*EmptyResponse, error)
}

LoggerServiceClient is the client API for LoggerService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type LoggerServiceServer

type LoggerServiceServer interface {
	Log(context.Context, *LoggerRequest) (*EmptyResponse, error)
}

LoggerServiceServer is the server API for LoggerService service. All implementations should embed UnimplementedLoggerServiceServer for forward compatibility

type UnimplementedLoggerServiceServer

type UnimplementedLoggerServiceServer struct {
}

UnimplementedLoggerServiceServer should be embedded to have forward compatible implementations.

func (UnimplementedLoggerServiceServer) Log

type UnsafeLoggerServiceServer

type UnsafeLoggerServiceServer interface {
	// contains filtered or unexported methods
}

UnsafeLoggerServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to LoggerServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

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