Documentation
¶
Index ¶
- Constants
- Variables
- func ErrorCancelTrainingFail(format string, args ...interface{}) *errors.Error
- func ErrorIncorrectInput(format string, args ...interface{}) *errors.Error
- func ErrorQueryFail(format string, args ...interface{}) *errors.Error
- func ErrorUpdateAvailabilityFail(format string, args ...interface{}) *errors.Error
- func ErrorUserAuthFail(format string, args ...interface{}) *errors.Error
- func ErrorUserNotFound(format string, args ...interface{}) *errors.Error
- func IsCancelTrainingFail(err error) bool
- func IsIncorrectInput(err error) bool
- func IsQueryFail(err error) bool
- func IsUpdateAvailabilityFail(err error) bool
- func IsUserAuthFail(err error) bool
- func IsUserNotFound(err error) bool
- func RegisterTrainerServiceHTTPServer(s *http.Server, srv TrainerServiceHTTPServer)
- func RegisterTrainerServiceServer(s grpc.ServiceRegistrar, srv TrainerServiceServer)
- type GetTrainerAvailableHoursRequest
- func (*GetTrainerAvailableHoursRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetTrainerAvailableHoursRequest) GetDateFrom() *timestamppb.Timestamp
- func (x *GetTrainerAvailableHoursRequest) GetDateTo() *timestamppb.Timestamp
- func (*GetTrainerAvailableHoursRequest) ProtoMessage()
- func (x *GetTrainerAvailableHoursRequest) ProtoReflect() protoreflect.Message
- func (x *GetTrainerAvailableHoursRequest) Reset()
- func (x *GetTrainerAvailableHoursRequest) String() string
- type GetTrainerAvailableHoursRespone
- func (*GetTrainerAvailableHoursRespone) Descriptor() ([]byte, []int)deprecated
- func (x *GetTrainerAvailableHoursRespone) GetDates() []*GetTrainerAvailableHoursRespone_Date
- func (*GetTrainerAvailableHoursRespone) ProtoMessage()
- func (x *GetTrainerAvailableHoursRespone) ProtoReflect() protoreflect.Message
- func (x *GetTrainerAvailableHoursRespone) Reset()
- func (x *GetTrainerAvailableHoursRespone) String() string
- type GetTrainerAvailableHoursRespone_Date
- func (*GetTrainerAvailableHoursRespone_Date) Descriptor() ([]byte, []int)deprecated
- func (x *GetTrainerAvailableHoursRespone_Date) GetDate() *timestamppb.Timestamp
- func (x *GetTrainerAvailableHoursRespone_Date) GetHasFreeHours() bool
- func (x *GetTrainerAvailableHoursRespone_Date) GetHours() []*GetTrainerAvailableHoursRespone_Hour
- func (*GetTrainerAvailableHoursRespone_Date) ProtoMessage()
- func (x *GetTrainerAvailableHoursRespone_Date) ProtoReflect() protoreflect.Message
- func (x *GetTrainerAvailableHoursRespone_Date) Reset()
- func (x *GetTrainerAvailableHoursRespone_Date) String() string
- type GetTrainerAvailableHoursRespone_Hour
- func (*GetTrainerAvailableHoursRespone_Hour) Descriptor() ([]byte, []int)deprecated
- func (x *GetTrainerAvailableHoursRespone_Hour) GetAvailable() bool
- func (x *GetTrainerAvailableHoursRespone_Hour) GetHasTrainingScheduled() bool
- func (x *GetTrainerAvailableHoursRespone_Hour) GetHour() *timestamppb.Timestamp
- func (*GetTrainerAvailableHoursRespone_Hour) ProtoMessage()
- func (x *GetTrainerAvailableHoursRespone_Hour) ProtoReflect() protoreflect.Message
- func (x *GetTrainerAvailableHoursRespone_Hour) Reset()
- func (x *GetTrainerAvailableHoursRespone_Hour) String() string
- type IsHourAvailableRequest
- func (*IsHourAvailableRequest) Descriptor() ([]byte, []int)deprecated
- func (x *IsHourAvailableRequest) GetTime() *timestamppb.Timestamp
- func (*IsHourAvailableRequest) ProtoMessage()
- func (x *IsHourAvailableRequest) ProtoReflect() protoreflect.Message
- func (x *IsHourAvailableRequest) Reset()
- func (x *IsHourAvailableRequest) String() string
- type IsHourAvailableResponse
- func (*IsHourAvailableResponse) Descriptor() ([]byte, []int)deprecated
- func (x *IsHourAvailableResponse) GetIsAvailable() bool
- func (*IsHourAvailableResponse) ProtoMessage()
- func (x *IsHourAvailableResponse) ProtoReflect() protoreflect.Message
- func (x *IsHourAvailableResponse) Reset()
- func (x *IsHourAvailableResponse) String() string
- type MakeHourAvailableRequest
- func (*MakeHourAvailableRequest) Descriptor() ([]byte, []int)deprecated
- func (x *MakeHourAvailableRequest) GetTime() []*timestamppb.Timestamp
- func (*MakeHourAvailableRequest) ProtoMessage()
- func (x *MakeHourAvailableRequest) ProtoReflect() protoreflect.Message
- func (x *MakeHourAvailableRequest) Reset()
- func (x *MakeHourAvailableRequest) String() string
- type MakeHourUnavailableRequest
- func (*MakeHourUnavailableRequest) Descriptor() ([]byte, []int)deprecated
- func (x *MakeHourUnavailableRequest) GetTime() []*timestamppb.Timestamp
- func (*MakeHourUnavailableRequest) ProtoMessage()
- func (x *MakeHourUnavailableRequest) ProtoReflect() protoreflect.Message
- func (x *MakeHourUnavailableRequest) Reset()
- func (x *MakeHourUnavailableRequest) String() string
- type TrainerErrorReason
- func (TrainerErrorReason) Descriptor() protoreflect.EnumDescriptor
- func (x TrainerErrorReason) Enum() *TrainerErrorReason
- func (TrainerErrorReason) EnumDescriptor() ([]byte, []int)deprecated
- func (x TrainerErrorReason) Number() protoreflect.EnumNumber
- func (x TrainerErrorReason) String() string
- func (TrainerErrorReason) Type() protoreflect.EnumType
- type TrainerServiceClient
- type TrainerServiceHTTPClient
- type TrainerServiceHTTPClientImpl
- func (c *TrainerServiceHTTPClientImpl) GetTrainerAvailableHours(ctx context.Context, in *GetTrainerAvailableHoursRequest, ...) (*GetTrainerAvailableHoursRespone, error)
- func (c *TrainerServiceHTTPClientImpl) MakeHourAvailable(ctx context.Context, in *MakeHourAvailableRequest, opts ...http.CallOption) (*emptypb.Empty, error)
- func (c *TrainerServiceHTTPClientImpl) MakeHourUnavailable(ctx context.Context, in *MakeHourUnavailableRequest, opts ...http.CallOption) (*emptypb.Empty, error)
- type TrainerServiceHTTPServer
- type TrainerServiceServer
- type UnimplementedTrainerServiceServer
- func (UnimplementedTrainerServiceServer) CancelTraining(context.Context, *UpdateHourRequest) (*emptypb.Empty, error)
- func (UnimplementedTrainerServiceServer) GetTrainerAvailableHours(context.Context, *GetTrainerAvailableHoursRequest) (*GetTrainerAvailableHoursRespone, error)
- func (UnimplementedTrainerServiceServer) IsHourAvailable(context.Context, *IsHourAvailableRequest) (*IsHourAvailableResponse, error)
- func (UnimplementedTrainerServiceServer) MakeHourAvailable(context.Context, *MakeHourAvailableRequest) (*emptypb.Empty, error)
- func (UnimplementedTrainerServiceServer) MakeHourUnavailable(context.Context, *MakeHourUnavailableRequest) (*emptypb.Empty, error)
- func (UnimplementedTrainerServiceServer) ScheduleTraining(context.Context, *UpdateHourRequest) (*emptypb.Empty, error)
- type UnsafeTrainerServiceServer
- type UpdateHourRequest
- func (*UpdateHourRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateHourRequest) GetTime() *timestamppb.Timestamp
- func (*UpdateHourRequest) ProtoMessage()
- func (x *UpdateHourRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateHourRequest) Reset()
- func (x *UpdateHourRequest) String() string
Constants ¶
const ( TrainerService_IsHourAvailable_FullMethodName = "/trainer.TrainerService/IsHourAvailable" TrainerService_ScheduleTraining_FullMethodName = "/trainer.TrainerService/ScheduleTraining" TrainerService_CancelTraining_FullMethodName = "/trainer.TrainerService/CancelTraining" TrainerService_GetTrainerAvailableHours_FullMethodName = "/trainer.TrainerService/GetTrainerAvailableHours" TrainerService_MakeHourAvailable_FullMethodName = "/trainer.TrainerService/MakeHourAvailable" )
const OperationTrainerServiceGetTrainerAvailableHours = "/trainer.TrainerService/GetTrainerAvailableHours"
const OperationTrainerServiceMakeHourAvailable = "/trainer.TrainerService/MakeHourAvailable"
Variables ¶
var ( TrainerErrorReason_name = map[int32]string{ 0: "USER_NOT_FOUND", 1: "USER_AUTH_FAIL", 2: "INCORRECT_INPUT", 3: "QUERY_FAIL", 4: "CANCEL_TRAINING_FAIL", 5: "UPDATE_AVAILABILITY_FAIL", } TrainerErrorReason_value = map[string]int32{ "USER_NOT_FOUND": 0, "USER_AUTH_FAIL": 1, "INCORRECT_INPUT": 2, "QUERY_FAIL": 3, "CANCEL_TRAINING_FAIL": 4, "UPDATE_AVAILABILITY_FAIL": 5, } )
Enum value maps for TrainerErrorReason.
var File_trainer_v1_error_reason_proto protoreflect.FileDescriptor
var File_trainer_v1_trainer_proto protoreflect.FileDescriptor
var TrainerService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "trainer.TrainerService", HandlerType: (*TrainerServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "IsHourAvailable", Handler: _TrainerService_IsHourAvailable_Handler, }, { MethodName: "ScheduleTraining", Handler: _TrainerService_ScheduleTraining_Handler, }, { MethodName: "CancelTraining", Handler: _TrainerService_CancelTraining_Handler, }, { MethodName: "GetTrainerAvailableHours", Handler: _TrainerService_GetTrainerAvailableHours_Handler, }, { MethodName: "MakeHourAvailable", Handler: _TrainerService_MakeHourAvailable_Handler, }, { MethodName: "MakeHourUnavailable", Handler: _TrainerService_MakeHourUnavailable_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "trainer/v1/trainer.proto", }
TrainerService_ServiceDesc is the grpc.ServiceDesc for TrainerService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func ErrorCancelTrainingFail ¶
func ErrorIncorrectInput ¶
func ErrorQueryFail ¶
func ErrorUserAuthFail ¶
func ErrorUserNotFound ¶
func IsCancelTrainingFail ¶
func IsIncorrectInput ¶
func IsQueryFail ¶
func IsUserAuthFail ¶
func IsUserNotFound ¶
func RegisterTrainerServiceHTTPServer ¶
func RegisterTrainerServiceHTTPServer(s *http.Server, srv TrainerServiceHTTPServer)
func RegisterTrainerServiceServer ¶
func RegisterTrainerServiceServer(s grpc.ServiceRegistrar, srv TrainerServiceServer)
Types ¶
type GetTrainerAvailableHoursRequest ¶
type GetTrainerAvailableHoursRequest struct {
DateFrom *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=date_from,json=dateFrom,proto3" json:"date_from,omitempty"`
DateTo *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=date_to,json=dateTo,proto3" json:"date_to,omitempty"`
// contains filtered or unexported fields
}
func (*GetTrainerAvailableHoursRequest) Descriptor
deprecated
func (*GetTrainerAvailableHoursRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetTrainerAvailableHoursRequest.ProtoReflect.Descriptor instead.
func (*GetTrainerAvailableHoursRequest) GetDateFrom ¶
func (x *GetTrainerAvailableHoursRequest) GetDateFrom() *timestamppb.Timestamp
func (*GetTrainerAvailableHoursRequest) GetDateTo ¶
func (x *GetTrainerAvailableHoursRequest) GetDateTo() *timestamppb.Timestamp
func (*GetTrainerAvailableHoursRequest) ProtoMessage ¶
func (*GetTrainerAvailableHoursRequest) ProtoMessage()
func (*GetTrainerAvailableHoursRequest) ProtoReflect ¶
func (x *GetTrainerAvailableHoursRequest) ProtoReflect() protoreflect.Message
func (*GetTrainerAvailableHoursRequest) Reset ¶
func (x *GetTrainerAvailableHoursRequest) Reset()
func (*GetTrainerAvailableHoursRequest) String ¶
func (x *GetTrainerAvailableHoursRequest) String() string
type GetTrainerAvailableHoursRespone ¶
type GetTrainerAvailableHoursRespone struct {
Dates []*GetTrainerAvailableHoursRespone_Date `protobuf:"bytes,1,rep,name=dates,proto3" json:"dates,omitempty"`
// contains filtered or unexported fields
}
func (*GetTrainerAvailableHoursRespone) Descriptor
deprecated
func (*GetTrainerAvailableHoursRespone) Descriptor() ([]byte, []int)
Deprecated: Use GetTrainerAvailableHoursRespone.ProtoReflect.Descriptor instead.
func (*GetTrainerAvailableHoursRespone) GetDates ¶
func (x *GetTrainerAvailableHoursRespone) GetDates() []*GetTrainerAvailableHoursRespone_Date
func (*GetTrainerAvailableHoursRespone) ProtoMessage ¶
func (*GetTrainerAvailableHoursRespone) ProtoMessage()
func (*GetTrainerAvailableHoursRespone) ProtoReflect ¶
func (x *GetTrainerAvailableHoursRespone) ProtoReflect() protoreflect.Message
func (*GetTrainerAvailableHoursRespone) Reset ¶
func (x *GetTrainerAvailableHoursRespone) Reset()
func (*GetTrainerAvailableHoursRespone) String ¶
func (x *GetTrainerAvailableHoursRespone) String() string
type GetTrainerAvailableHoursRespone_Date ¶
type GetTrainerAvailableHoursRespone_Date struct {
Date *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=date,proto3" json:"date,omitempty"`
HasFreeHours bool `protobuf:"varint,2,opt,name=Has_free_hours,json=HasFreeHours,proto3" json:"Has_free_hours,omitempty"`
Hours []*GetTrainerAvailableHoursRespone_Hour `protobuf:"bytes,3,rep,name=hours,proto3" json:"hours,omitempty"`
// contains filtered or unexported fields
}
func (*GetTrainerAvailableHoursRespone_Date) Descriptor
deprecated
func (*GetTrainerAvailableHoursRespone_Date) Descriptor() ([]byte, []int)
Deprecated: Use GetTrainerAvailableHoursRespone_Date.ProtoReflect.Descriptor instead.
func (*GetTrainerAvailableHoursRespone_Date) GetDate ¶
func (x *GetTrainerAvailableHoursRespone_Date) GetDate() *timestamppb.Timestamp
func (*GetTrainerAvailableHoursRespone_Date) GetHasFreeHours ¶
func (x *GetTrainerAvailableHoursRespone_Date) GetHasFreeHours() bool
func (*GetTrainerAvailableHoursRespone_Date) GetHours ¶
func (x *GetTrainerAvailableHoursRespone_Date) GetHours() []*GetTrainerAvailableHoursRespone_Hour
func (*GetTrainerAvailableHoursRespone_Date) ProtoMessage ¶
func (*GetTrainerAvailableHoursRespone_Date) ProtoMessage()
func (*GetTrainerAvailableHoursRespone_Date) ProtoReflect ¶
func (x *GetTrainerAvailableHoursRespone_Date) ProtoReflect() protoreflect.Message
func (*GetTrainerAvailableHoursRespone_Date) Reset ¶
func (x *GetTrainerAvailableHoursRespone_Date) Reset()
func (*GetTrainerAvailableHoursRespone_Date) String ¶
func (x *GetTrainerAvailableHoursRespone_Date) String() string
type GetTrainerAvailableHoursRespone_Hour ¶
type GetTrainerAvailableHoursRespone_Hour struct {
Available bool `protobuf:"varint,1,opt,name=available,proto3" json:"available,omitempty"`
HasTrainingScheduled bool `protobuf:"varint,2,opt,name=has_training_scheduled,json=hasTrainingScheduled,proto3" json:"has_training_scheduled,omitempty"`
Hour *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=hour,proto3" json:"hour,omitempty"`
// contains filtered or unexported fields
}
func (*GetTrainerAvailableHoursRespone_Hour) Descriptor
deprecated
func (*GetTrainerAvailableHoursRespone_Hour) Descriptor() ([]byte, []int)
Deprecated: Use GetTrainerAvailableHoursRespone_Hour.ProtoReflect.Descriptor instead.
func (*GetTrainerAvailableHoursRespone_Hour) GetAvailable ¶
func (x *GetTrainerAvailableHoursRespone_Hour) GetAvailable() bool
func (*GetTrainerAvailableHoursRespone_Hour) GetHasTrainingScheduled ¶
func (x *GetTrainerAvailableHoursRespone_Hour) GetHasTrainingScheduled() bool
func (*GetTrainerAvailableHoursRespone_Hour) GetHour ¶
func (x *GetTrainerAvailableHoursRespone_Hour) GetHour() *timestamppb.Timestamp
func (*GetTrainerAvailableHoursRespone_Hour) ProtoMessage ¶
func (*GetTrainerAvailableHoursRespone_Hour) ProtoMessage()
func (*GetTrainerAvailableHoursRespone_Hour) ProtoReflect ¶
func (x *GetTrainerAvailableHoursRespone_Hour) ProtoReflect() protoreflect.Message
func (*GetTrainerAvailableHoursRespone_Hour) Reset ¶
func (x *GetTrainerAvailableHoursRespone_Hour) Reset()
func (*GetTrainerAvailableHoursRespone_Hour) String ¶
func (x *GetTrainerAvailableHoursRespone_Hour) String() string
type IsHourAvailableRequest ¶
type IsHourAvailableRequest struct {
Time *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
// contains filtered or unexported fields
}
func (*IsHourAvailableRequest) Descriptor
deprecated
func (*IsHourAvailableRequest) Descriptor() ([]byte, []int)
Deprecated: Use IsHourAvailableRequest.ProtoReflect.Descriptor instead.
func (*IsHourAvailableRequest) GetTime ¶
func (x *IsHourAvailableRequest) GetTime() *timestamppb.Timestamp
func (*IsHourAvailableRequest) ProtoMessage ¶
func (*IsHourAvailableRequest) ProtoMessage()
func (*IsHourAvailableRequest) ProtoReflect ¶
func (x *IsHourAvailableRequest) ProtoReflect() protoreflect.Message
func (*IsHourAvailableRequest) Reset ¶
func (x *IsHourAvailableRequest) Reset()
func (*IsHourAvailableRequest) String ¶
func (x *IsHourAvailableRequest) String() string
type IsHourAvailableResponse ¶
type IsHourAvailableResponse struct {
IsAvailable bool `protobuf:"varint,1,opt,name=is_available,json=isAvailable,proto3" json:"is_available,omitempty"`
// contains filtered or unexported fields
}
func (*IsHourAvailableResponse) Descriptor
deprecated
func (*IsHourAvailableResponse) Descriptor() ([]byte, []int)
Deprecated: Use IsHourAvailableResponse.ProtoReflect.Descriptor instead.
func (*IsHourAvailableResponse) GetIsAvailable ¶
func (x *IsHourAvailableResponse) GetIsAvailable() bool
func (*IsHourAvailableResponse) ProtoMessage ¶
func (*IsHourAvailableResponse) ProtoMessage()
func (*IsHourAvailableResponse) ProtoReflect ¶
func (x *IsHourAvailableResponse) ProtoReflect() protoreflect.Message
func (*IsHourAvailableResponse) Reset ¶
func (x *IsHourAvailableResponse) Reset()
func (*IsHourAvailableResponse) String ¶
func (x *IsHourAvailableResponse) String() string
type MakeHourAvailableRequest ¶
type MakeHourAvailableRequest struct {
Time []*timestamppb.Timestamp `protobuf:"bytes,1,rep,name=time,proto3" json:"time,omitempty"`
// contains filtered or unexported fields
}
func (*MakeHourAvailableRequest) Descriptor
deprecated
func (*MakeHourAvailableRequest) Descriptor() ([]byte, []int)
Deprecated: Use MakeHourAvailableRequest.ProtoReflect.Descriptor instead.
func (*MakeHourAvailableRequest) GetTime ¶
func (x *MakeHourAvailableRequest) GetTime() []*timestamppb.Timestamp
func (*MakeHourAvailableRequest) ProtoMessage ¶
func (*MakeHourAvailableRequest) ProtoMessage()
func (*MakeHourAvailableRequest) ProtoReflect ¶
func (x *MakeHourAvailableRequest) ProtoReflect() protoreflect.Message
func (*MakeHourAvailableRequest) Reset ¶
func (x *MakeHourAvailableRequest) Reset()
func (*MakeHourAvailableRequest) String ¶
func (x *MakeHourAvailableRequest) String() string
type MakeHourUnavailableRequest ¶
type MakeHourUnavailableRequest struct {
// contains filtered or unexported fields
}
func (*MakeHourUnavailableRequest) Descriptor
deprecated
func (*MakeHourUnavailableRequest) Descriptor() ([]byte, []int)
Deprecated: Use MakeHourUnavailableRequest.ProtoReflect.Descriptor instead.
func (*MakeHourUnavailableRequest) GetTime ¶
func (x *MakeHourUnavailableRequest) GetTime() []*timestamppb.Timestamp
func (*MakeHourUnavailableRequest) ProtoMessage ¶
func (*MakeHourUnavailableRequest) ProtoMessage()
func (*MakeHourUnavailableRequest) ProtoReflect ¶
func (x *MakeHourUnavailableRequest) ProtoReflect() protoreflect.Message
func (*MakeHourUnavailableRequest) Reset ¶
func (x *MakeHourUnavailableRequest) Reset()
func (*MakeHourUnavailableRequest) String ¶
func (x *MakeHourUnavailableRequest) String() string
type TrainerErrorReason ¶
type TrainerErrorReason int32
const ( TrainerErrorReason_USER_NOT_FOUND TrainerErrorReason = 0 TrainerErrorReason_USER_AUTH_FAIL TrainerErrorReason = 1 TrainerErrorReason_INCORRECT_INPUT TrainerErrorReason = 2 TrainerErrorReason_QUERY_FAIL TrainerErrorReason = 3 TrainerErrorReason_CANCEL_TRAINING_FAIL TrainerErrorReason = 4 TrainerErrorReason_UPDATE_AVAILABILITY_FAIL TrainerErrorReason = 5 )
func (TrainerErrorReason) Descriptor ¶
func (TrainerErrorReason) Descriptor() protoreflect.EnumDescriptor
func (TrainerErrorReason) Enum ¶
func (x TrainerErrorReason) Enum() *TrainerErrorReason
func (TrainerErrorReason) EnumDescriptor
deprecated
func (TrainerErrorReason) EnumDescriptor() ([]byte, []int)
Deprecated: Use TrainerErrorReason.Descriptor instead.
func (TrainerErrorReason) Number ¶
func (x TrainerErrorReason) Number() protoreflect.EnumNumber
func (TrainerErrorReason) String ¶
func (x TrainerErrorReason) String() string
func (TrainerErrorReason) Type ¶
func (TrainerErrorReason) Type() protoreflect.EnumType
type TrainerServiceClient ¶
type TrainerServiceClient interface {
IsHourAvailable(ctx context.Context, in *IsHourAvailableRequest, opts ...grpc.CallOption) (*IsHourAvailableResponse, error)
ScheduleTraining(ctx context.Context, in *UpdateHourRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
CancelTraining(ctx context.Context, in *UpdateHourRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
GetTrainerAvailableHours(ctx context.Context, in *GetTrainerAvailableHoursRequest, opts ...grpc.CallOption) (*GetTrainerAvailableHoursRespone, error)
MakeHourAvailable(ctx context.Context, in *MakeHourAvailableRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
}
TrainerServiceClient is the client API for TrainerService 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.
func NewTrainerServiceClient ¶
func NewTrainerServiceClient(cc grpc.ClientConnInterface) TrainerServiceClient
type TrainerServiceHTTPClient ¶
type TrainerServiceHTTPClient interface {
GetTrainerAvailableHours(ctx context.Context, req *GetTrainerAvailableHoursRequest, opts ...http.CallOption) (rsp *GetTrainerAvailableHoursRespone, err error)
MakeHourAvailable(ctx context.Context, req *MakeHourAvailableRequest, opts ...http.CallOption) (rsp *emptypb.Empty, err error)
}
func NewTrainerServiceHTTPClient ¶
func NewTrainerServiceHTTPClient(client *http.Client) TrainerServiceHTTPClient
type TrainerServiceHTTPClientImpl ¶
type TrainerServiceHTTPClientImpl struct {
// contains filtered or unexported fields
}
func (*TrainerServiceHTTPClientImpl) GetTrainerAvailableHours ¶
func (c *TrainerServiceHTTPClientImpl) GetTrainerAvailableHours(ctx context.Context, in *GetTrainerAvailableHoursRequest, opts ...http.CallOption) (*GetTrainerAvailableHoursRespone, error)
func (*TrainerServiceHTTPClientImpl) MakeHourAvailable ¶
func (c *TrainerServiceHTTPClientImpl) MakeHourAvailable(ctx context.Context, in *MakeHourAvailableRequest, opts ...http.CallOption) (*emptypb.Empty, error)
func (*TrainerServiceHTTPClientImpl) MakeHourUnavailable ¶
func (c *TrainerServiceHTTPClientImpl) MakeHourUnavailable(ctx context.Context, in *MakeHourUnavailableRequest, opts ...http.CallOption) (*emptypb.Empty, error)
type TrainerServiceHTTPServer ¶
type TrainerServiceHTTPServer interface {
GetTrainerAvailableHours(context.Context, *GetTrainerAvailableHoursRequest) (*GetTrainerAvailableHoursRespone, error)
MakeHourAvailable(context.Context, *MakeHourAvailableRequest) (*emptypb.Empty, error)
}
type TrainerServiceServer ¶
type TrainerServiceServer interface {
IsHourAvailable(context.Context, *IsHourAvailableRequest) (*IsHourAvailableResponse, error)
ScheduleTraining(context.Context, *UpdateHourRequest) (*emptypb.Empty, error)
CancelTraining(context.Context, *UpdateHourRequest) (*emptypb.Empty, error)
GetTrainerAvailableHours(context.Context, *GetTrainerAvailableHoursRequest) (*GetTrainerAvailableHoursRespone, error)
MakeHourAvailable(context.Context, *MakeHourAvailableRequest) (*emptypb.Empty, error)
// contains filtered or unexported methods
}
TrainerServiceServer is the server API for TrainerService service. All implementations must embed UnimplementedTrainerServiceServer for forward compatibility
type UnimplementedTrainerServiceServer ¶
type UnimplementedTrainerServiceServer struct {
}
UnimplementedTrainerServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedTrainerServiceServer) CancelTraining ¶
func (UnimplementedTrainerServiceServer) CancelTraining(context.Context, *UpdateHourRequest) (*emptypb.Empty, error)
func (UnimplementedTrainerServiceServer) GetTrainerAvailableHours ¶
func (UnimplementedTrainerServiceServer) GetTrainerAvailableHours(context.Context, *GetTrainerAvailableHoursRequest) (*GetTrainerAvailableHoursRespone, error)
func (UnimplementedTrainerServiceServer) IsHourAvailable ¶
func (UnimplementedTrainerServiceServer) IsHourAvailable(context.Context, *IsHourAvailableRequest) (*IsHourAvailableResponse, error)
func (UnimplementedTrainerServiceServer) MakeHourAvailable ¶
func (UnimplementedTrainerServiceServer) MakeHourAvailable(context.Context, *MakeHourAvailableRequest) (*emptypb.Empty, error)
func (UnimplementedTrainerServiceServer) MakeHourUnavailable ¶
func (UnimplementedTrainerServiceServer) MakeHourUnavailable(context.Context, *MakeHourUnavailableRequest) (*emptypb.Empty, error)
func (UnimplementedTrainerServiceServer) ScheduleTraining ¶
func (UnimplementedTrainerServiceServer) ScheduleTraining(context.Context, *UpdateHourRequest) (*emptypb.Empty, error)
type UnsafeTrainerServiceServer ¶
type UnsafeTrainerServiceServer interface {
// contains filtered or unexported methods
}
UnsafeTrainerServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TrainerServiceServer will result in compilation errors.
type UpdateHourRequest ¶
type UpdateHourRequest struct {
Time *timestamppb.Timestamp `protobuf:"bytes,1,opt,name=time,proto3" json:"time,omitempty"`
// contains filtered or unexported fields
}
func (*UpdateHourRequest) Descriptor
deprecated
func (*UpdateHourRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateHourRequest.ProtoReflect.Descriptor instead.
func (*UpdateHourRequest) GetTime ¶
func (x *UpdateHourRequest) GetTime() *timestamppb.Timestamp
func (*UpdateHourRequest) ProtoMessage ¶
func (*UpdateHourRequest) ProtoMessage()
func (*UpdateHourRequest) ProtoReflect ¶
func (x *UpdateHourRequest) ProtoReflect() protoreflect.Message
func (*UpdateHourRequest) Reset ¶
func (x *UpdateHourRequest) Reset()
func (*UpdateHourRequest) String ¶
func (x *UpdateHourRequest) String() string