proto

package
v0.0.0-...-8c4f088 Latest Latest
Warning

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

Go to latest
Published: Jul 20, 2023 License: MIT Imports: 18 Imported by: 0

Documentation

Overview

Package proto is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

View Source
var CloudrollService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "CloudrollService",
	HandlerType: (*CloudrollServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Ping",
			Handler:    _CloudrollService_Ping_Handler,
		},
		{
			MethodName: "CreateTeam",
			Handler:    _CloudrollService_CreateTeam_Handler,
		},
		{
			MethodName: "JoinTeam",
			Handler:    _CloudrollService_JoinTeam_Handler,
		},
		{
			MethodName: "AddTask",
			Handler:    _CloudrollService_AddTask_Handler,
		},
		{
			MethodName: "DeleteTask",
			Handler:    _CloudrollService_DeleteTask_Handler,
		},
		{
			MethodName: "ShowTasks",
			Handler:    _CloudrollService_ShowTasks_Handler,
		},
		{
			MethodName: "GetBoard",
			Handler:    _CloudrollService_GetBoard_Handler,
		},
		{
			MethodName: "UpdateBoard",
			Handler:    _CloudrollService_UpdateBoard_Handler,
		},
		{
			MethodName: "GetScoreboard",
			Handler:    _CloudrollService_GetScoreboard_Handler,
		},
		{
			MethodName: "SubmitTask",
			Handler:    _CloudrollService_SubmitTask_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/cloudroll.proto",
}

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

View Source
var File_proto_cloudroll_proto protoreflect.FileDescriptor

Functions

func RegisterCloudrollServiceHandler

func RegisterCloudrollServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterCloudrollServiceHandler registers the http handlers for service CloudrollService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterCloudrollServiceHandlerClient

func RegisterCloudrollServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client CloudrollServiceClient) error

RegisterCloudrollServiceHandlerClient registers the http handlers for service CloudrollService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "CloudrollServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "CloudrollServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "CloudrollServiceClient" to call the correct interceptors.

func RegisterCloudrollServiceHandlerFromEndpoint

func RegisterCloudrollServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterCloudrollServiceHandlerFromEndpoint is same as RegisterCloudrollServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterCloudrollServiceHandlerServer

func RegisterCloudrollServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server CloudrollServiceServer) error

RegisterCloudrollServiceHandlerServer registers the http handlers for service CloudrollService to "mux". UnaryRPC :call CloudrollServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterCloudrollServiceHandlerFromEndpoint instead.

func RegisterCloudrollServiceServer

func RegisterCloudrollServiceServer(s grpc.ServiceRegistrar, srv CloudrollServiceServer)

Types

type Board

type Board struct {
	Columns []*Column `protobuf:"bytes,1,rep,name=columns,proto3" json:"columns,omitempty"`
	// contains filtered or unexported fields
}

func (*Board) Descriptor deprecated

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

Deprecated: Use Board.ProtoReflect.Descriptor instead.

func (*Board) GetColumns

func (x *Board) GetColumns() []*Column

func (*Board) ProtoMessage

func (*Board) ProtoMessage()

func (*Board) ProtoReflect

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

func (*Board) Reset

func (x *Board) Reset()

func (*Board) String

func (x *Board) String() string

type Card

type Card struct {
	Id     string       `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Title  string       `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty"`
	Labels []*Labels    `protobuf:"bytes,3,rep,name=labels,proto3" json:"labels,omitempty"`
	Tasks  []*TeamTasks `protobuf:"bytes,4,rep,name=tasks,proto3" json:"tasks,omitempty"`
	// contains filtered or unexported fields
}

func (*Card) Descriptor deprecated

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

Deprecated: Use Card.ProtoReflect.Descriptor instead.

func (*Card) GetId

func (x *Card) GetId() string

func (*Card) GetLabels

func (x *Card) GetLabels() []*Labels

func (*Card) GetTasks

func (x *Card) GetTasks() []*TeamTasks

func (*Card) GetTitle

func (x *Card) GetTitle() string

func (*Card) ProtoMessage

func (*Card) ProtoMessage()

func (*Card) ProtoReflect

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

func (*Card) Reset

func (x *Card) Reset()

func (*Card) String

func (x *Card) String() string

type CloudrollServiceClient

type CloudrollServiceClient interface {
	Ping(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*EchoMessage, error)
	CreateTeam(ctx context.Context, in *TeamCreateReq, opts ...grpc.CallOption) (*TeamInfo, error)
	JoinTeam(ctx context.Context, in *JoinTeamReq, opts ...grpc.CallOption) (*TeamInfo, error)
	AddTask(ctx context.Context, in *Task, opts ...grpc.CallOption) (*Task, error)
	DeleteTask(ctx context.Context, in *Task, opts ...grpc.CallOption) (*Empty, error)
	ShowTasks(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Tasks, error)
	GetBoard(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Board, error)
	UpdateBoard(ctx context.Context, in *Board, opts ...grpc.CallOption) (*Board, error)
	GetScoreboard(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*ScoreboardResponse, error)
	SubmitTask(ctx context.Context, in *SubmitRequest, opts ...grpc.CallOption) (*EchoMessage, error)
}

CloudrollServiceClient is the client API for CloudrollService 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 CloudrollServiceServer

type CloudrollServiceServer interface {
	Ping(context.Context, *Empty) (*EchoMessage, error)
	CreateTeam(context.Context, *TeamCreateReq) (*TeamInfo, error)
	JoinTeam(context.Context, *JoinTeamReq) (*TeamInfo, error)
	AddTask(context.Context, *Task) (*Task, error)
	DeleteTask(context.Context, *Task) (*Empty, error)
	ShowTasks(context.Context, *Empty) (*Tasks, error)
	GetBoard(context.Context, *Empty) (*Board, error)
	UpdateBoard(context.Context, *Board) (*Board, error)
	GetScoreboard(context.Context, *Empty) (*ScoreboardResponse, error)
	SubmitTask(context.Context, *SubmitRequest) (*EchoMessage, error)
	// contains filtered or unexported methods
}

CloudrollServiceServer is the server API for CloudrollService service. All implementations must embed UnimplementedCloudrollServiceServer for forward compatibility

type Column

type Column struct {
	Id    string  `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name  string  `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Cards []*Card `protobuf:"bytes,3,rep,name=cards,proto3" json:"cards,omitempty"`
	// contains filtered or unexported fields
}

func (*Column) Descriptor deprecated

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

Deprecated: Use Column.ProtoReflect.Descriptor instead.

func (*Column) GetCards

func (x *Column) GetCards() []*Card

func (*Column) GetId

func (x *Column) GetId() string

func (*Column) GetName

func (x *Column) GetName() string

func (*Column) ProtoMessage

func (*Column) ProtoMessage()

func (*Column) ProtoReflect

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

func (*Column) Reset

func (x *Column) Reset()

func (*Column) String

func (x *Column) String() string

type EchoMessage

type EchoMessage struct {
	Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*EchoMessage) Descriptor deprecated

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

Deprecated: Use EchoMessage.ProtoReflect.Descriptor instead.

func (*EchoMessage) GetValue

func (x *EchoMessage) GetValue() string

func (*EchoMessage) ProtoMessage

func (*EchoMessage) ProtoMessage()

func (*EchoMessage) ProtoReflect

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

func (*EchoMessage) Reset

func (x *EchoMessage) Reset()

func (*EchoMessage) String

func (x *EchoMessage) String() string

type Empty

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

func (*Empty) Descriptor deprecated

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

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

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

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type JoinTeamReq

type JoinTeamReq struct {
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*JoinTeamReq) Descriptor deprecated

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

Deprecated: Use JoinTeamReq.ProtoReflect.Descriptor instead.

func (*JoinTeamReq) GetId

func (x *JoinTeamReq) GetId() string

func (*JoinTeamReq) ProtoMessage

func (*JoinTeamReq) ProtoMessage()

func (*JoinTeamReq) ProtoReflect

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

func (*JoinTeamReq) Reset

func (x *JoinTeamReq) Reset()

func (*JoinTeamReq) String

func (x *JoinTeamReq) String() string

type Labels

type Labels struct {
	Name  string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Color string `protobuf:"bytes,2,opt,name=color,proto3" json:"color,omitempty"`
	// contains filtered or unexported fields
}

func (*Labels) Descriptor deprecated

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

Deprecated: Use Labels.ProtoReflect.Descriptor instead.

func (*Labels) GetColor

func (x *Labels) GetColor() string

func (*Labels) GetName

func (x *Labels) GetName() string

func (*Labels) ProtoMessage

func (*Labels) ProtoMessage()

func (*Labels) ProtoReflect

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

func (*Labels) Reset

func (x *Labels) Reset()

func (*Labels) String

func (x *Labels) String() string

type Score

type Score struct {
	Id    string  `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name  string  `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Score int64   `protobuf:"varint,3,opt,name=score,proto3" json:"score,omitempty"`
	Tasks []*Task `protobuf:"bytes,4,rep,name=tasks,proto3" json:"tasks,omitempty"`
	// contains filtered or unexported fields
}

func (*Score) Descriptor deprecated

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

Deprecated: Use Score.ProtoReflect.Descriptor instead.

func (*Score) GetId

func (x *Score) GetId() string

func (*Score) GetName

func (x *Score) GetName() string

func (*Score) GetScore

func (x *Score) GetScore() int64

func (*Score) GetTasks

func (x *Score) GetTasks() []*Task

func (*Score) ProtoMessage

func (*Score) ProtoMessage()

func (*Score) ProtoReflect

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

func (*Score) Reset

func (x *Score) Reset()

func (*Score) String

func (x *Score) String() string

type ScoreboardResponse

type ScoreboardResponse struct {
	Score []*Score               `protobuf:"bytes,1,rep,name=score,proto3" json:"score,omitempty"`
	Time  *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=time,proto3" json:"time,omitempty"`
	// contains filtered or unexported fields
}

func (*ScoreboardResponse) Descriptor deprecated

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

Deprecated: Use ScoreboardResponse.ProtoReflect.Descriptor instead.

func (*ScoreboardResponse) GetScore

func (x *ScoreboardResponse) GetScore() []*Score

func (*ScoreboardResponse) GetTime

func (*ScoreboardResponse) ProtoMessage

func (*ScoreboardResponse) ProtoMessage()

func (*ScoreboardResponse) ProtoReflect

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

func (*ScoreboardResponse) Reset

func (x *ScoreboardResponse) Reset()

func (*ScoreboardResponse) String

func (x *ScoreboardResponse) String() string

type SubmitRequest

type SubmitRequest struct {
	Id   int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Task *Task `protobuf:"bytes,2,opt,name=task,proto3" json:"task,omitempty"`
	// contains filtered or unexported fields
}

func (*SubmitRequest) Descriptor deprecated

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

Deprecated: Use SubmitRequest.ProtoReflect.Descriptor instead.

func (*SubmitRequest) GetId

func (x *SubmitRequest) GetId() int64

func (*SubmitRequest) GetTask

func (x *SubmitRequest) GetTask() *Task

func (*SubmitRequest) ProtoMessage

func (*SubmitRequest) ProtoMessage()

func (*SubmitRequest) ProtoReflect

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

func (*SubmitRequest) Reset

func (x *SubmitRequest) Reset()

func (*SubmitRequest) String

func (x *SubmitRequest) String() string

type Task

type Task struct {
	Id          string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name        string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"`
	Points      int64  `protobuf:"varint,4,opt,name=points,proto3" json:"points,omitempty"`
	// contains filtered or unexported fields
}

func (*Task) Descriptor deprecated

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

Deprecated: Use Task.ProtoReflect.Descriptor instead.

func (*Task) GetDescription

func (x *Task) GetDescription() string

func (*Task) GetId

func (x *Task) GetId() string

func (*Task) GetName

func (x *Task) GetName() string

func (*Task) GetPoints

func (x *Task) GetPoints() int64

func (*Task) ProtoMessage

func (*Task) ProtoMessage()

func (*Task) ProtoReflect

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

func (*Task) Reset

func (x *Task) Reset()

func (*Task) String

func (x *Task) String() string

type Tasks

type Tasks struct {
	Tasks []*Task `protobuf:"bytes,1,rep,name=tasks,proto3" json:"tasks,omitempty"`
	// contains filtered or unexported fields
}

func (*Tasks) Descriptor deprecated

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

Deprecated: Use Tasks.ProtoReflect.Descriptor instead.

func (*Tasks) GetTasks

func (x *Tasks) GetTasks() []*Task

func (*Tasks) ProtoMessage

func (*Tasks) ProtoMessage()

func (*Tasks) ProtoReflect

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

func (*Tasks) Reset

func (x *Tasks) Reset()

func (*Tasks) String

func (x *Tasks) String() string

type TeamCreateReq

type TeamCreateReq struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*TeamCreateReq) Descriptor deprecated

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

Deprecated: Use TeamCreateReq.ProtoReflect.Descriptor instead.

func (*TeamCreateReq) GetName

func (x *TeamCreateReq) GetName() string

func (*TeamCreateReq) ProtoMessage

func (*TeamCreateReq) ProtoMessage()

func (*TeamCreateReq) ProtoReflect

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

func (*TeamCreateReq) Reset

func (x *TeamCreateReq) Reset()

func (*TeamCreateReq) String

func (x *TeamCreateReq) String() string

type TeamInfo

type TeamInfo struct {
	Name   string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Invite string `protobuf:"bytes,2,opt,name=invite,proto3" json:"invite,omitempty"`
	// contains filtered or unexported fields
}

func (*TeamInfo) Descriptor deprecated

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

Deprecated: Use TeamInfo.ProtoReflect.Descriptor instead.

func (*TeamInfo) GetInvite

func (x *TeamInfo) GetInvite() string

func (*TeamInfo) GetName

func (x *TeamInfo) GetName() string

func (*TeamInfo) ProtoMessage

func (*TeamInfo) ProtoMessage()

func (*TeamInfo) ProtoReflect

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

func (*TeamInfo) Reset

func (x *TeamInfo) Reset()

func (*TeamInfo) String

func (x *TeamInfo) String() string

type TeamTasks

type TeamTasks struct {
	Id        string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Info      *Task  `protobuf:"bytes,2,opt,name=info,proto3" json:"info,omitempty"`
	Completed bool   `protobuf:"varint,3,opt,name=completed,proto3" json:"completed,omitempty"`
	// contains filtered or unexported fields
}

func (*TeamTasks) Descriptor deprecated

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

Deprecated: Use TeamTasks.ProtoReflect.Descriptor instead.

func (*TeamTasks) GetCompleted

func (x *TeamTasks) GetCompleted() bool

func (*TeamTasks) GetId

func (x *TeamTasks) GetId() string

func (*TeamTasks) GetInfo

func (x *TeamTasks) GetInfo() *Task

func (*TeamTasks) ProtoMessage

func (*TeamTasks) ProtoMessage()

func (*TeamTasks) ProtoReflect

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

func (*TeamTasks) Reset

func (x *TeamTasks) Reset()

func (*TeamTasks) String

func (x *TeamTasks) String() string

type UnimplementedCloudrollServiceServer

type UnimplementedCloudrollServiceServer struct {
}

UnimplementedCloudrollServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedCloudrollServiceServer) AddTask

func (UnimplementedCloudrollServiceServer) CreateTeam

func (UnimplementedCloudrollServiceServer) DeleteTask

func (UnimplementedCloudrollServiceServer) GetBoard

func (UnimplementedCloudrollServiceServer) GetScoreboard

func (UnimplementedCloudrollServiceServer) JoinTeam

func (UnimplementedCloudrollServiceServer) Ping

func (UnimplementedCloudrollServiceServer) ShowTasks

func (UnimplementedCloudrollServiceServer) SubmitTask

func (UnimplementedCloudrollServiceServer) UpdateBoard

type UnsafeCloudrollServiceServer

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

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

Jump to

Keyboard shortcuts

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