chore: updated grpc stubs
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.36.10
|
||||
// protoc-gen-go v1.36.11
|
||||
// protoc v6.33.2
|
||||
// source: api/proto/competition.proto
|
||||
|
||||
@@ -9,6 +9,7 @@ package competition
|
||||
import (
|
||||
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||||
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||||
timestamppb "google.golang.org/protobuf/types/known/timestamppb"
|
||||
reflect "reflect"
|
||||
sync "sync"
|
||||
unsafe "unsafe"
|
||||
@@ -25,24 +26,30 @@ type CompetitionState int32
|
||||
|
||||
const (
|
||||
CompetitionState_COMPETITION_STATE_UNSPECIFIED CompetitionState = 0
|
||||
CompetitionState_COMPETITION_STATE_NOT_STARTED CompetitionState = 1
|
||||
CompetitionState_COMPETITION_STATE_STARTED CompetitionState = 2
|
||||
CompetitionState_COMPETITION_STATE_FINISHED CompetitionState = 3
|
||||
CompetitionState_COMPETITION_STATE_DRAFT CompetitionState = 1
|
||||
CompetitionState_COMPETITION_STATE_NOT_STARTED CompetitionState = 2
|
||||
CompetitionState_COMPETITION_STATE_STARTED CompetitionState = 3
|
||||
CompetitionState_COMPETITION_STATE_FINISHED CompetitionState = 4
|
||||
CompetitionState_COMPETITION_STATE_ARCHIVED CompetitionState = 5
|
||||
)
|
||||
|
||||
// Enum value maps for CompetitionState.
|
||||
var (
|
||||
CompetitionState_name = map[int32]string{
|
||||
0: "COMPETITION_STATE_UNSPECIFIED",
|
||||
1: "COMPETITION_STATE_NOT_STARTED",
|
||||
2: "COMPETITION_STATE_STARTED",
|
||||
3: "COMPETITION_STATE_FINISHED",
|
||||
1: "COMPETITION_STATE_DRAFT",
|
||||
2: "COMPETITION_STATE_NOT_STARTED",
|
||||
3: "COMPETITION_STATE_STARTED",
|
||||
4: "COMPETITION_STATE_FINISHED",
|
||||
5: "COMPETITION_STATE_ARCHIVED",
|
||||
}
|
||||
CompetitionState_value = map[string]int32{
|
||||
"COMPETITION_STATE_UNSPECIFIED": 0,
|
||||
"COMPETITION_STATE_NOT_STARTED": 1,
|
||||
"COMPETITION_STATE_STARTED": 2,
|
||||
"COMPETITION_STATE_FINISHED": 3,
|
||||
"COMPETITION_STATE_DRAFT": 1,
|
||||
"COMPETITION_STATE_NOT_STARTED": 2,
|
||||
"COMPETITION_STATE_STARTED": 3,
|
||||
"COMPETITION_STATE_FINISHED": 4,
|
||||
"COMPETITION_STATE_ARCHIVED": 5,
|
||||
}
|
||||
)
|
||||
|
||||
@@ -73,6 +80,228 @@ func (CompetitionState) EnumDescriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
type ParticipationType int32
|
||||
|
||||
const (
|
||||
ParticipationType_PARTICIPATION_TYPE_UNSPECIFIED ParticipationType = 0
|
||||
ParticipationType_PARTICIPATION_TYPE_INDIVIDUAL ParticipationType = 1
|
||||
ParticipationType_PARTICIPATION_TYPE_TEAM ParticipationType = 2
|
||||
)
|
||||
|
||||
// Enum value maps for ParticipationType.
|
||||
var (
|
||||
ParticipationType_name = map[int32]string{
|
||||
0: "PARTICIPATION_TYPE_UNSPECIFIED",
|
||||
1: "PARTICIPATION_TYPE_INDIVIDUAL",
|
||||
2: "PARTICIPATION_TYPE_TEAM",
|
||||
}
|
||||
ParticipationType_value = map[string]int32{
|
||||
"PARTICIPATION_TYPE_UNSPECIFIED": 0,
|
||||
"PARTICIPATION_TYPE_INDIVIDUAL": 1,
|
||||
"PARTICIPATION_TYPE_TEAM": 2,
|
||||
}
|
||||
)
|
||||
|
||||
func (x ParticipationType) Enum() *ParticipationType {
|
||||
p := new(ParticipationType)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x ParticipationType) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (ParticipationType) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_api_proto_competition_proto_enumTypes[1].Descriptor()
|
||||
}
|
||||
|
||||
func (ParticipationType) Type() protoreflect.EnumType {
|
||||
return &file_api_proto_competition_proto_enumTypes[1]
|
||||
}
|
||||
|
||||
func (x ParticipationType) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use ParticipationType.Descriptor instead.
|
||||
func (ParticipationType) EnumDescriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
type CompetitionType int32
|
||||
|
||||
const (
|
||||
CompetitionType_COMPETITION_TYPE_UNSPECIFIED CompetitionType = 0
|
||||
CompetitionType_COMPETITION_TYPE_EDUCATIVE CompetitionType = 1
|
||||
CompetitionType_COMPETITION_TYPE_COMPETETIVE CompetitionType = 2
|
||||
)
|
||||
|
||||
// Enum value maps for CompetitionType.
|
||||
var (
|
||||
CompetitionType_name = map[int32]string{
|
||||
0: "COMPETITION_TYPE_UNSPECIFIED",
|
||||
1: "COMPETITION_TYPE_EDUCATIVE",
|
||||
2: "COMPETITION_TYPE_COMPETETIVE",
|
||||
}
|
||||
CompetitionType_value = map[string]int32{
|
||||
"COMPETITION_TYPE_UNSPECIFIED": 0,
|
||||
"COMPETITION_TYPE_EDUCATIVE": 1,
|
||||
"COMPETITION_TYPE_COMPETETIVE": 2,
|
||||
}
|
||||
)
|
||||
|
||||
func (x CompetitionType) Enum() *CompetitionType {
|
||||
p := new(CompetitionType)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x CompetitionType) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (CompetitionType) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_api_proto_competition_proto_enumTypes[2].Descriptor()
|
||||
}
|
||||
|
||||
func (CompetitionType) Type() protoreflect.EnumType {
|
||||
return &file_api_proto_competition_proto_enumTypes[2]
|
||||
}
|
||||
|
||||
func (x CompetitionType) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use CompetitionType.Descriptor instead.
|
||||
func (CompetitionType) EnumDescriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
type Competition struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
||||
State CompetitionState `protobuf:"varint,2,opt,name=state,proto3,enum=competition.CompetitionState" json:"state,omitempty"`
|
||||
Title string `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty"`
|
||||
Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"`
|
||||
ImageUrl *string `protobuf:"bytes,5,opt,name=image_url,json=imageUrl,proto3,oneof" json:"image_url,omitempty"`
|
||||
StartTime *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=start_time,json=startTime,proto3" json:"start_time,omitempty"`
|
||||
EndTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=end_time,json=endTime,proto3" json:"end_time,omitempty"`
|
||||
Type CompetitionType `protobuf:"varint,8,opt,name=type,proto3,enum=competition.CompetitionType" json:"type,omitempty"`
|
||||
ParticipationType ParticipationType `protobuf:"varint,9,opt,name=participation_type,json=participationType,proto3,enum=competition.ParticipationType" json:"participation_type,omitempty"`
|
||||
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,10,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
|
||||
UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *Competition) Reset() {
|
||||
*x = Competition{}
|
||||
mi := &file_api_proto_competition_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *Competition) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Competition) ProtoMessage() {}
|
||||
|
||||
func (x *Competition) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_proto_competition_proto_msgTypes[0]
|
||||
if x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Competition.ProtoReflect.Descriptor instead.
|
||||
func (*Competition) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *Competition) GetId() string {
|
||||
if x != nil {
|
||||
return x.Id
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetState() CompetitionState {
|
||||
if x != nil {
|
||||
return x.State
|
||||
}
|
||||
return CompetitionState_COMPETITION_STATE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *Competition) GetTitle() string {
|
||||
if x != nil {
|
||||
return x.Title
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetDescription() string {
|
||||
if x != nil {
|
||||
return x.Description
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetImageUrl() string {
|
||||
if x != nil && x.ImageUrl != nil {
|
||||
return *x.ImageUrl
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetStartTime() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.StartTime
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *Competition) GetEndTime() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.EndTime
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *Competition) GetType() CompetitionType {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return CompetitionType_COMPETITION_TYPE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *Competition) GetParticipationType() ParticipationType {
|
||||
if x != nil {
|
||||
return x.ParticipationType
|
||||
}
|
||||
return ParticipationType_PARTICIPATION_TYPE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *Competition) GetCreatedAt() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.CreatedAt
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *Competition) GetUpdatedAt() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.UpdatedAt
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type GetCompetitionRequest struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
CompetitionId string `protobuf:"bytes,1,opt,name=competition_id,json=competitionId,proto3" json:"competition_id,omitempty"`
|
||||
@@ -82,7 +311,7 @@ type GetCompetitionRequest struct {
|
||||
|
||||
func (x *GetCompetitionRequest) Reset() {
|
||||
*x = GetCompetitionRequest{}
|
||||
mi := &file_api_proto_competition_proto_msgTypes[0]
|
||||
mi := &file_api_proto_competition_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@@ -94,7 +323,7 @@ func (x *GetCompetitionRequest) String() string {
|
||||
func (*GetCompetitionRequest) ProtoMessage() {}
|
||||
|
||||
func (x *GetCompetitionRequest) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_proto_competition_proto_msgTypes[0]
|
||||
mi := &file_api_proto_competition_proto_msgTypes[1]
|
||||
if x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@@ -107,7 +336,7 @@ func (x *GetCompetitionRequest) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use GetCompetitionRequest.ProtoReflect.Descriptor instead.
|
||||
func (*GetCompetitionRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{0}
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *GetCompetitionRequest) GetCompetitionId() string {
|
||||
@@ -117,53 +346,13 @@ func (x *GetCompetitionRequest) GetCompetitionId() string {
|
||||
return ""
|
||||
}
|
||||
|
||||
type GetCompetitionResponse struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Competition *Competition `protobuf:"bytes,1,opt,name=competition,proto3" json:"competition,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *GetCompetitionResponse) Reset() {
|
||||
*x = GetCompetitionResponse{}
|
||||
mi := &file_api_proto_competition_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *GetCompetitionResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*GetCompetitionResponse) ProtoMessage() {}
|
||||
|
||||
func (x *GetCompetitionResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_proto_competition_proto_msgTypes[1]
|
||||
if x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use GetCompetitionResponse.ProtoReflect.Descriptor instead.
|
||||
func (*GetCompetitionResponse) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *GetCompetitionResponse) GetCompetition() *Competition {
|
||||
if x != nil {
|
||||
return x.Competition
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type ListCompetitionsRequest struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
IsParticipating bool `protobuf:"varint,1,opt,name=is_participating,json=isParticipating,proto3" json:"is_participating,omitempty"`
|
||||
PageSize int32 `protobuf:"varint,1,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
|
||||
PageToken int32 `protobuf:"varint,2,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"`
|
||||
State *CompetitionState `protobuf:"varint,3,opt,name=state,proto3,enum=competition.CompetitionState,oneof" json:"state,omitempty"`
|
||||
IsParticipating *bool `protobuf:"varint,4,opt,name=is_participating,json=isParticipating,proto3,oneof" json:"is_participating,omitempty"`
|
||||
SearchQuery *string `protobuf:"bytes,5,opt,name=search_query,json=searchQuery,proto3,oneof" json:"search_query,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
@@ -198,15 +387,45 @@ func (*ListCompetitionsRequest) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsRequest) GetIsParticipating() bool {
|
||||
func (x *ListCompetitionsRequest) GetPageSize() int32 {
|
||||
if x != nil {
|
||||
return x.IsParticipating
|
||||
return x.PageSize
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsRequest) GetPageToken() int32 {
|
||||
if x != nil {
|
||||
return x.PageToken
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsRequest) GetState() CompetitionState {
|
||||
if x != nil && x.State != nil {
|
||||
return *x.State
|
||||
}
|
||||
return CompetitionState_COMPETITION_STATE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsRequest) GetIsParticipating() bool {
|
||||
if x != nil && x.IsParticipating != nil {
|
||||
return *x.IsParticipating
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsRequest) GetSearchQuery() string {
|
||||
if x != nil && x.SearchQuery != nil {
|
||||
return *x.SearchQuery
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type ListCompetitionsResponse struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
TotalCount int32 `protobuf:"varint,2,opt,name=total_count,json=totalCount,proto3" json:"total_count,omitempty"`
|
||||
NextPageToken int32 `protobuf:"varint,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
|
||||
Competitions []*Competition `protobuf:"bytes,1,rep,name=competitions,proto3" json:"competitions,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
@@ -242,6 +461,20 @@ func (*ListCompetitionsResponse) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsResponse) GetTotalCount() int32 {
|
||||
if x != nil {
|
||||
return x.TotalCount
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsResponse) GetNextPageToken() int32 {
|
||||
if x != nil {
|
||||
return x.NextPageToken
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *ListCompetitionsResponse) GetCompetitions() []*Competition {
|
||||
if x != nil {
|
||||
return x.Competitions
|
||||
@@ -301,200 +534,68 @@ func (x *ChangeCompetitionStateRequest) GetState() CompetitionState {
|
||||
return CompetitionState_COMPETITION_STATE_UNSPECIFIED
|
||||
}
|
||||
|
||||
type ChangeCompetitionStateResponse struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
State CompetitionState `protobuf:"varint,1,opt,name=state,proto3,enum=competition.CompetitionState" json:"state,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *ChangeCompetitionStateResponse) Reset() {
|
||||
*x = ChangeCompetitionStateResponse{}
|
||||
mi := &file_api_proto_competition_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *ChangeCompetitionStateResponse) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*ChangeCompetitionStateResponse) ProtoMessage() {}
|
||||
|
||||
func (x *ChangeCompetitionStateResponse) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_proto_competition_proto_msgTypes[5]
|
||||
if x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use ChangeCompetitionStateResponse.ProtoReflect.Descriptor instead.
|
||||
func (*ChangeCompetitionStateResponse) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
func (x *ChangeCompetitionStateResponse) GetState() CompetitionState {
|
||||
if x != nil {
|
||||
return x.State
|
||||
}
|
||||
return CompetitionState_COMPETITION_STATE_UNSPECIFIED
|
||||
}
|
||||
|
||||
type Competition struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
|
||||
State CompetitionState `protobuf:"varint,2,opt,name=state,proto3,enum=competition.CompetitionState" json:"state,omitempty"`
|
||||
Title string `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty"`
|
||||
Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"`
|
||||
ImageUrl *string `protobuf:"bytes,5,opt,name=image_url,json=imageUrl,proto3,oneof" json:"image_url,omitempty"`
|
||||
EndDate *string `protobuf:"bytes,6,opt,name=end_date,json=endDate,proto3,oneof" json:"end_date,omitempty"`
|
||||
StartDate *string `protobuf:"bytes,7,opt,name=start_date,json=startDate,proto3,oneof" json:"start_date,omitempty"`
|
||||
Type string `protobuf:"bytes,8,opt,name=type,proto3" json:"type,omitempty"`
|
||||
ParticipationType string `protobuf:"bytes,9,opt,name=participation_type,json=participationType,proto3" json:"participation_type,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *Competition) Reset() {
|
||||
*x = Competition{}
|
||||
mi := &file_api_proto_competition_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *Competition) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*Competition) ProtoMessage() {}
|
||||
|
||||
func (x *Competition) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_api_proto_competition_proto_msgTypes[6]
|
||||
if x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use Competition.ProtoReflect.Descriptor instead.
|
||||
func (*Competition) Descriptor() ([]byte, []int) {
|
||||
return file_api_proto_competition_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
func (x *Competition) GetId() string {
|
||||
if x != nil {
|
||||
return x.Id
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetState() CompetitionState {
|
||||
if x != nil {
|
||||
return x.State
|
||||
}
|
||||
return CompetitionState_COMPETITION_STATE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *Competition) GetTitle() string {
|
||||
if x != nil {
|
||||
return x.Title
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetDescription() string {
|
||||
if x != nil {
|
||||
return x.Description
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetImageUrl() string {
|
||||
if x != nil && x.ImageUrl != nil {
|
||||
return *x.ImageUrl
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetEndDate() string {
|
||||
if x != nil && x.EndDate != nil {
|
||||
return *x.EndDate
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetStartDate() string {
|
||||
if x != nil && x.StartDate != nil {
|
||||
return *x.StartDate
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetType() string {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *Competition) GetParticipationType() string {
|
||||
if x != nil {
|
||||
return x.ParticipationType
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
var File_api_proto_competition_proto protoreflect.FileDescriptor
|
||||
|
||||
const file_api_proto_competition_proto_rawDesc = "" +
|
||||
"\n" +
|
||||
"\x1bapi/proto/competition.proto\x12\vcompetition\">\n" +
|
||||
"\x15GetCompetitionRequest\x12%\n" +
|
||||
"\x0ecompetition_id\x18\x01 \x01(\tR\rcompetitionId\"T\n" +
|
||||
"\x16GetCompetitionResponse\x12:\n" +
|
||||
"\vcompetition\x18\x01 \x01(\v2\x18.competition.CompetitionR\vcompetition\"D\n" +
|
||||
"\x17ListCompetitionsRequest\x12)\n" +
|
||||
"\x10is_participating\x18\x01 \x01(\bR\x0fisParticipating\"X\n" +
|
||||
"\x18ListCompetitionsResponse\x12<\n" +
|
||||
"\fcompetitions\x18\x01 \x03(\v2\x18.competition.CompetitionR\fcompetitions\"{\n" +
|
||||
"\x1dChangeCompetitionStateRequest\x12%\n" +
|
||||
"\x0ecompetition_id\x18\x01 \x01(\tR\rcompetitionId\x123\n" +
|
||||
"\x05state\x18\x02 \x01(\x0e2\x1d.competition.CompetitionStateR\x05state\"U\n" +
|
||||
"\x1eChangeCompetitionStateResponse\x123\n" +
|
||||
"\x05state\x18\x01 \x01(\x0e2\x1d.competition.CompetitionStateR\x05state\"\xdd\x02\n" +
|
||||
"\x1bapi/proto/competition.proto\x12\vcompetition\x1a\x1fgoogle/protobuf/timestamp.proto\"\xa3\x04\n" +
|
||||
"\vCompetition\x12\x0e\n" +
|
||||
"\x02id\x18\x01 \x01(\tR\x02id\x123\n" +
|
||||
"\x05state\x18\x02 \x01(\x0e2\x1d.competition.CompetitionStateR\x05state\x12\x14\n" +
|
||||
"\x05title\x18\x03 \x01(\tR\x05title\x12 \n" +
|
||||
"\vdescription\x18\x04 \x01(\tR\vdescription\x12 \n" +
|
||||
"\timage_url\x18\x05 \x01(\tH\x00R\bimageUrl\x88\x01\x01\x12\x1e\n" +
|
||||
"\bend_date\x18\x06 \x01(\tH\x01R\aendDate\x88\x01\x01\x12\"\n" +
|
||||
"\timage_url\x18\x05 \x01(\tH\x00R\bimageUrl\x88\x01\x01\x129\n" +
|
||||
"\n" +
|
||||
"start_date\x18\a \x01(\tH\x02R\tstartDate\x88\x01\x01\x12\x12\n" +
|
||||
"\x04type\x18\b \x01(\tR\x04type\x12-\n" +
|
||||
"\x12participation_type\x18\t \x01(\tR\x11participationTypeB\f\n" +
|
||||
"start_time\x18\x06 \x01(\v2\x1a.google.protobuf.TimestampR\tstartTime\x125\n" +
|
||||
"\bend_time\x18\a \x01(\v2\x1a.google.protobuf.TimestampR\aendTime\x120\n" +
|
||||
"\x04type\x18\b \x01(\x0e2\x1c.competition.CompetitionTypeR\x04type\x12M\n" +
|
||||
"\x12participation_type\x18\t \x01(\x0e2\x1e.competition.ParticipationTypeR\x11participationType\x129\n" +
|
||||
"\n" +
|
||||
"_image_urlB\v\n" +
|
||||
"\t_end_dateB\r\n" +
|
||||
"\v_start_date*\x97\x01\n" +
|
||||
"created_at\x18\n" +
|
||||
" \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\x129\n" +
|
||||
"\n" +
|
||||
"updated_at\x18\v \x01(\v2\x1a.google.protobuf.TimestampR\tupdatedAtB\f\n" +
|
||||
"\n" +
|
||||
"_image_url\">\n" +
|
||||
"\x15GetCompetitionRequest\x12%\n" +
|
||||
"\x0ecompetition_id\x18\x01 \x01(\tR\rcompetitionId\"\x97\x02\n" +
|
||||
"\x17ListCompetitionsRequest\x12\x1b\n" +
|
||||
"\tpage_size\x18\x01 \x01(\x05R\bpageSize\x12\x1d\n" +
|
||||
"\n" +
|
||||
"page_token\x18\x02 \x01(\x05R\tpageToken\x128\n" +
|
||||
"\x05state\x18\x03 \x01(\x0e2\x1d.competition.CompetitionStateH\x00R\x05state\x88\x01\x01\x12.\n" +
|
||||
"\x10is_participating\x18\x04 \x01(\bH\x01R\x0fisParticipating\x88\x01\x01\x12&\n" +
|
||||
"\fsearch_query\x18\x05 \x01(\tH\x02R\vsearchQuery\x88\x01\x01B\b\n" +
|
||||
"\x06_stateB\x13\n" +
|
||||
"\x11_is_participatingB\x0f\n" +
|
||||
"\r_search_query\"\xa1\x01\n" +
|
||||
"\x18ListCompetitionsResponse\x12\x1f\n" +
|
||||
"\vtotal_count\x18\x02 \x01(\x05R\n" +
|
||||
"totalCount\x12&\n" +
|
||||
"\x0fnext_page_token\x18\x03 \x01(\x05R\rnextPageToken\x12<\n" +
|
||||
"\fcompetitions\x18\x01 \x03(\v2\x18.competition.CompetitionR\fcompetitions\"{\n" +
|
||||
"\x1dChangeCompetitionStateRequest\x12%\n" +
|
||||
"\x0ecompetition_id\x18\x01 \x01(\tR\rcompetitionId\x123\n" +
|
||||
"\x05state\x18\x02 \x01(\x0e2\x1d.competition.CompetitionStateR\x05state*\xd4\x01\n" +
|
||||
"\x10CompetitionState\x12!\n" +
|
||||
"\x1dCOMPETITION_STATE_UNSPECIFIED\x10\x00\x12!\n" +
|
||||
"\x1dCOMPETITION_STATE_NOT_STARTED\x10\x01\x12\x1d\n" +
|
||||
"\x19COMPETITION_STATE_STARTED\x10\x02\x12\x1e\n" +
|
||||
"\x1aCOMPETITION_STATE_FINISHED\x10\x032\xc3\x02\n" +
|
||||
"\x12CompetitionService\x12Y\n" +
|
||||
"\x0eGetCompetition\x12\".competition.GetCompetitionRequest\x1a#.competition.GetCompetitionResponse\x12_\n" +
|
||||
"\x10ListCompetitions\x12$.competition.ListCompetitionsRequest\x1a%.competition.ListCompetitionsResponse\x12q\n" +
|
||||
"\x16ChangeCompetitionState\x12*.competition.ChangeCompetitionStateRequest\x1a+.competition.ChangeCompetitionStateResponseB\x15Z\x13pkg/api/competitionb\x06proto3"
|
||||
"\x1dCOMPETITION_STATE_UNSPECIFIED\x10\x00\x12\x1b\n" +
|
||||
"\x17COMPETITION_STATE_DRAFT\x10\x01\x12!\n" +
|
||||
"\x1dCOMPETITION_STATE_NOT_STARTED\x10\x02\x12\x1d\n" +
|
||||
"\x19COMPETITION_STATE_STARTED\x10\x03\x12\x1e\n" +
|
||||
"\x1aCOMPETITION_STATE_FINISHED\x10\x04\x12\x1e\n" +
|
||||
"\x1aCOMPETITION_STATE_ARCHIVED\x10\x05*w\n" +
|
||||
"\x11ParticipationType\x12\"\n" +
|
||||
"\x1ePARTICIPATION_TYPE_UNSPECIFIED\x10\x00\x12!\n" +
|
||||
"\x1dPARTICIPATION_TYPE_INDIVIDUAL\x10\x01\x12\x1b\n" +
|
||||
"\x17PARTICIPATION_TYPE_TEAM\x10\x02*u\n" +
|
||||
"\x0fCompetitionType\x12 \n" +
|
||||
"\x1cCOMPETITION_TYPE_UNSPECIFIED\x10\x00\x12\x1e\n" +
|
||||
"\x1aCOMPETITION_TYPE_EDUCATIVE\x10\x01\x12 \n" +
|
||||
"\x1cCOMPETITION_TYPE_COMPETETIVE\x10\x022\xa5\x02\n" +
|
||||
"\x12CompetitionService\x12N\n" +
|
||||
"\x0eGetCompetition\x12\".competition.GetCompetitionRequest\x1a\x18.competition.Competition\x12_\n" +
|
||||
"\x10ListCompetitions\x12$.competition.ListCompetitionsRequest\x1a%.competition.ListCompetitionsResponse\x12^\n" +
|
||||
"\x16ChangeCompetitionState\x12*.competition.ChangeCompetitionStateRequest\x1a\x18.competition.CompetitionB\x15Z\x13pkg/api/competitionb\x06proto3"
|
||||
|
||||
var (
|
||||
file_api_proto_competition_proto_rawDescOnce sync.Once
|
||||
@@ -508,35 +609,41 @@ func file_api_proto_competition_proto_rawDescGZIP() []byte {
|
||||
return file_api_proto_competition_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_api_proto_competition_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_api_proto_competition_proto_msgTypes = make([]protoimpl.MessageInfo, 7)
|
||||
var file_api_proto_competition_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
|
||||
var file_api_proto_competition_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
|
||||
var file_api_proto_competition_proto_goTypes = []any{
|
||||
(CompetitionState)(0), // 0: competition.CompetitionState
|
||||
(*GetCompetitionRequest)(nil), // 1: competition.GetCompetitionRequest
|
||||
(*GetCompetitionResponse)(nil), // 2: competition.GetCompetitionResponse
|
||||
(*ListCompetitionsRequest)(nil), // 3: competition.ListCompetitionsRequest
|
||||
(*ListCompetitionsResponse)(nil), // 4: competition.ListCompetitionsResponse
|
||||
(*ChangeCompetitionStateRequest)(nil), // 5: competition.ChangeCompetitionStateRequest
|
||||
(*ChangeCompetitionStateResponse)(nil), // 6: competition.ChangeCompetitionStateResponse
|
||||
(*Competition)(nil), // 7: competition.Competition
|
||||
(CompetitionState)(0), // 0: competition.CompetitionState
|
||||
(ParticipationType)(0), // 1: competition.ParticipationType
|
||||
(CompetitionType)(0), // 2: competition.CompetitionType
|
||||
(*Competition)(nil), // 3: competition.Competition
|
||||
(*GetCompetitionRequest)(nil), // 4: competition.GetCompetitionRequest
|
||||
(*ListCompetitionsRequest)(nil), // 5: competition.ListCompetitionsRequest
|
||||
(*ListCompetitionsResponse)(nil), // 6: competition.ListCompetitionsResponse
|
||||
(*ChangeCompetitionStateRequest)(nil), // 7: competition.ChangeCompetitionStateRequest
|
||||
(*timestamppb.Timestamp)(nil), // 8: google.protobuf.Timestamp
|
||||
}
|
||||
var file_api_proto_competition_proto_depIdxs = []int32{
|
||||
7, // 0: competition.GetCompetitionResponse.competition:type_name -> competition.Competition
|
||||
7, // 1: competition.ListCompetitionsResponse.competitions:type_name -> competition.Competition
|
||||
0, // 2: competition.ChangeCompetitionStateRequest.state:type_name -> competition.CompetitionState
|
||||
0, // 3: competition.ChangeCompetitionStateResponse.state:type_name -> competition.CompetitionState
|
||||
0, // 4: competition.Competition.state:type_name -> competition.CompetitionState
|
||||
1, // 5: competition.CompetitionService.GetCompetition:input_type -> competition.GetCompetitionRequest
|
||||
3, // 6: competition.CompetitionService.ListCompetitions:input_type -> competition.ListCompetitionsRequest
|
||||
5, // 7: competition.CompetitionService.ChangeCompetitionState:input_type -> competition.ChangeCompetitionStateRequest
|
||||
2, // 8: competition.CompetitionService.GetCompetition:output_type -> competition.GetCompetitionResponse
|
||||
4, // 9: competition.CompetitionService.ListCompetitions:output_type -> competition.ListCompetitionsResponse
|
||||
6, // 10: competition.CompetitionService.ChangeCompetitionState:output_type -> competition.ChangeCompetitionStateResponse
|
||||
8, // [8:11] is the sub-list for method output_type
|
||||
5, // [5:8] is the sub-list for method input_type
|
||||
5, // [5:5] is the sub-list for extension type_name
|
||||
5, // [5:5] is the sub-list for extension extendee
|
||||
0, // [0:5] is the sub-list for field type_name
|
||||
0, // 0: competition.Competition.state:type_name -> competition.CompetitionState
|
||||
8, // 1: competition.Competition.start_time:type_name -> google.protobuf.Timestamp
|
||||
8, // 2: competition.Competition.end_time:type_name -> google.protobuf.Timestamp
|
||||
2, // 3: competition.Competition.type:type_name -> competition.CompetitionType
|
||||
1, // 4: competition.Competition.participation_type:type_name -> competition.ParticipationType
|
||||
8, // 5: competition.Competition.created_at:type_name -> google.protobuf.Timestamp
|
||||
8, // 6: competition.Competition.updated_at:type_name -> google.protobuf.Timestamp
|
||||
0, // 7: competition.ListCompetitionsRequest.state:type_name -> competition.CompetitionState
|
||||
3, // 8: competition.ListCompetitionsResponse.competitions:type_name -> competition.Competition
|
||||
0, // 9: competition.ChangeCompetitionStateRequest.state:type_name -> competition.CompetitionState
|
||||
4, // 10: competition.CompetitionService.GetCompetition:input_type -> competition.GetCompetitionRequest
|
||||
5, // 11: competition.CompetitionService.ListCompetitions:input_type -> competition.ListCompetitionsRequest
|
||||
7, // 12: competition.CompetitionService.ChangeCompetitionState:input_type -> competition.ChangeCompetitionStateRequest
|
||||
3, // 13: competition.CompetitionService.GetCompetition:output_type -> competition.Competition
|
||||
6, // 14: competition.CompetitionService.ListCompetitions:output_type -> competition.ListCompetitionsResponse
|
||||
3, // 15: competition.CompetitionService.ChangeCompetitionState:output_type -> competition.Competition
|
||||
13, // [13:16] is the sub-list for method output_type
|
||||
10, // [10:13] is the sub-list for method input_type
|
||||
10, // [10:10] is the sub-list for extension type_name
|
||||
10, // [10:10] is the sub-list for extension extendee
|
||||
0, // [0:10] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_api_proto_competition_proto_init() }
|
||||
@@ -544,14 +651,15 @@ func file_api_proto_competition_proto_init() {
|
||||
if File_api_proto_competition_proto != nil {
|
||||
return
|
||||
}
|
||||
file_api_proto_competition_proto_msgTypes[6].OneofWrappers = []any{}
|
||||
file_api_proto_competition_proto_msgTypes[0].OneofWrappers = []any{}
|
||||
file_api_proto_competition_proto_msgTypes[2].OneofWrappers = []any{}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: unsafe.Slice(unsafe.StringData(file_api_proto_competition_proto_rawDesc), len(file_api_proto_competition_proto_rawDesc)),
|
||||
NumEnums: 1,
|
||||
NumMessages: 7,
|
||||
NumEnums: 3,
|
||||
NumMessages: 5,
|
||||
NumExtensions: 0,
|
||||
NumServices: 1,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user