Documentation ¶
Index ¶
- Variables
- func NewRepo(db *sqlx.DB) scheduleRepo
- func NewScheduleHandlerGPRC(svc service) scheduleHandlerGrpc
- func NewService(repo repo) service
- func RegisterRouteGRPC(server *grpc.Server, db *sqlx.DB)
- func RegisterScheduleServer(s grpc.ServiceRegistrar, srv ScheduleServer)
- type FindAll
- type FindAvailable
- type FindBooked
- type FindScheduleProto
- func (*FindScheduleProto) Descriptor() ([]byte, []int)deprecated
- func (x *FindScheduleProto) GetHealthcareid() string
- func (x *FindScheduleProto) GetParamedicid() string
- func (x *FindScheduleProto) GetScheduledate() *timestamppb.Timestamp
- func (*FindScheduleProto) ProtoMessage()
- func (x *FindScheduleProto) ProtoReflect() protoreflect.Message
- func (x *FindScheduleProto) Reset()
- func (x *FindScheduleProto) String() string
- type ListscheduledetailProto
- func (*ListscheduledetailProto) Descriptor() ([]byte, []int)deprecated
- func (x *ListscheduledetailProto) GetSchedules() []*ScheduledetailProto
- func (*ListscheduledetailProto) ProtoMessage()
- func (x *ListscheduledetailProto) ProtoReflect() protoreflect.Message
- func (x *ListscheduledetailProto) Reset()
- func (x *ListscheduledetailProto) String() string
- type ScheduleClient
- type ScheduleCreateProto
- func (*ScheduleCreateProto) Descriptor() ([]byte, []int)deprecated
- func (x *ScheduleCreateProto) GetDuration() int32
- func (x *ScheduleCreateProto) GetHealthcareid() string
- func (x *ScheduleCreateProto) GetParamedicid() string
- func (x *ScheduleCreateProto) GetScheduleend() *timestamppb.Timestamp
- func (x *ScheduleCreateProto) GetSchedulestart() *timestamppb.Timestamp
- func (x *ScheduleCreateProto) GetUsercreate() string
- func (*ScheduleCreateProto) ProtoMessage()
- func (x *ScheduleCreateProto) ProtoReflect() protoreflect.Message
- func (x *ScheduleCreateProto) Reset()
- func (x *ScheduleCreateProto) String() string
- type ScheduleProto
- func (*ScheduleProto) Descriptor() ([]byte, []int)deprecated
- func (x *ScheduleProto) GetDuration() int32
- func (x *ScheduleProto) GetHealthcareid() string
- func (x *ScheduleProto) GetParamedicid() string
- func (x *ScheduleProto) GetScheduleend() string
- func (x *ScheduleProto) GetScheduleid() string
- func (x *ScheduleProto) GetSchedulestart() string
- func (*ScheduleProto) ProtoMessage()
- func (x *ScheduleProto) ProtoReflect() protoreflect.Message
- func (x *ScheduleProto) Reset()
- func (x *ScheduleProto) String() string
- type ScheduleServer
- type ScheduledetailProto
- func (*ScheduledetailProto) Descriptor() ([]byte, []int)deprecated
- func (x *ScheduledetailProto) GetIsbooked() bool
- func (x *ScheduledetailProto) GetScheduleslotid() int32
- func (x *ScheduledetailProto) GetSlottime() *timestamppb.Timestamp
- func (*ScheduledetailProto) ProtoMessage()
- func (x *ScheduledetailProto) ProtoReflect() protoreflect.Message
- func (x *ScheduledetailProto) Reset()
- func (x *ScheduledetailProto) String() string
- type SetScheduleProto
- type UnimplementedScheduleServer
- func (UnimplementedScheduleServer) BookSlot(context.Context, *SetScheduleProto) (*ScheduledetailProto, error)
- func (UnimplementedScheduleServer) CreateSchedule(context.Context, *ScheduleCreateProto) (*ScheduleProto, error)
- func (UnimplementedScheduleServer) FindScheduleAll(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error)
- func (UnimplementedScheduleServer) FindScheduleAvailable(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error)
- func (UnimplementedScheduleServer) FindScheduleBooked(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error)
- type UnsafeScheduleServer
Constants ¶
This section is empty.
Variables ¶
var File_domain_schedules_proto_schedules_dto_proto protoreflect.FileDescriptor
var Schedule_ServiceDesc = grpc.ServiceDesc{ ServiceName: "schedules.Schedule", HandlerType: (*ScheduleServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreateSchedule", Handler: _Schedule_CreateSchedule_Handler, }, { MethodName: "FindScheduleAll", Handler: _Schedule_FindScheduleAll_Handler, }, { MethodName: "FindScheduleAvailable", Handler: _Schedule_FindScheduleAvailable_Handler, }, { MethodName: "FindScheduleBooked", Handler: _Schedule_FindScheduleBooked_Handler, }, { MethodName: "BookSlot", Handler: _Schedule_BookSlot_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "domain/schedules/proto/schedules_dto.proto", }
Schedule_ServiceDesc is the grpc.ServiceDesc for Schedule service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func NewScheduleHandlerGPRC ¶
func NewScheduleHandlerGPRC(svc service) scheduleHandlerGrpc
func NewService ¶
func NewService(repo repo) service
func RegisterScheduleServer ¶
func RegisterScheduleServer(s grpc.ServiceRegistrar, srv ScheduleServer)
Types ¶
type FindAvailable ¶
type FindBooked ¶
type FindScheduleProto ¶
type FindScheduleProto struct { Healthcareid string `protobuf:"bytes,1,opt,name=healthcareid,proto3" json:"healthcareid,omitempty"` Paramedicid string `protobuf:"bytes,2,opt,name=paramedicid,proto3" json:"paramedicid,omitempty"` Scheduledate *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=scheduledate,proto3" json:"scheduledate,omitempty"` // contains filtered or unexported fields }
func (*FindScheduleProto) Descriptor
deprecated
func (*FindScheduleProto) Descriptor() ([]byte, []int)
Deprecated: Use FindScheduleProto.ProtoReflect.Descriptor instead.
func (*FindScheduleProto) GetHealthcareid ¶
func (x *FindScheduleProto) GetHealthcareid() string
func (*FindScheduleProto) GetParamedicid ¶
func (x *FindScheduleProto) GetParamedicid() string
func (*FindScheduleProto) GetScheduledate ¶
func (x *FindScheduleProto) GetScheduledate() *timestamppb.Timestamp
func (*FindScheduleProto) ProtoMessage ¶
func (*FindScheduleProto) ProtoMessage()
func (*FindScheduleProto) ProtoReflect ¶
func (x *FindScheduleProto) ProtoReflect() protoreflect.Message
func (*FindScheduleProto) Reset ¶
func (x *FindScheduleProto) Reset()
func (*FindScheduleProto) String ¶
func (x *FindScheduleProto) String() string
type ListscheduledetailProto ¶
type ListscheduledetailProto struct { Schedules []*ScheduledetailProto `protobuf:"bytes,1,rep,name=schedules,proto3" json:"schedules,omitempty"` // contains filtered or unexported fields }
func (*ListscheduledetailProto) Descriptor
deprecated
func (*ListscheduledetailProto) Descriptor() ([]byte, []int)
Deprecated: Use ListscheduledetailProto.ProtoReflect.Descriptor instead.
func (*ListscheduledetailProto) GetSchedules ¶
func (x *ListscheduledetailProto) GetSchedules() []*ScheduledetailProto
func (*ListscheduledetailProto) ProtoMessage ¶
func (*ListscheduledetailProto) ProtoMessage()
func (*ListscheduledetailProto) ProtoReflect ¶
func (x *ListscheduledetailProto) ProtoReflect() protoreflect.Message
func (*ListscheduledetailProto) Reset ¶
func (x *ListscheduledetailProto) Reset()
func (*ListscheduledetailProto) String ¶
func (x *ListscheduledetailProto) String() string
type ScheduleClient ¶
type ScheduleClient interface { CreateSchedule(ctx context.Context, in *ScheduleCreateProto, opts ...grpc.CallOption) (*ScheduleProto, error) FindScheduleAll(ctx context.Context, in *FindScheduleProto, opts ...grpc.CallOption) (*ListscheduledetailProto, error) FindScheduleAvailable(ctx context.Context, in *FindScheduleProto, opts ...grpc.CallOption) (*ListscheduledetailProto, error) FindScheduleBooked(ctx context.Context, in *FindScheduleProto, opts ...grpc.CallOption) (*ListscheduledetailProto, error) BookSlot(ctx context.Context, in *SetScheduleProto, opts ...grpc.CallOption) (*ScheduledetailProto, error) }
ScheduleClient is the client API for Schedule 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 NewScheduleClient ¶
func NewScheduleClient(cc grpc.ClientConnInterface) ScheduleClient
type ScheduleCreateProto ¶
type ScheduleCreateProto struct { Healthcareid string `protobuf:"bytes,1,opt,name=healthcareid,proto3" json:"healthcareid,omitempty"` Paramedicid string `protobuf:"bytes,2,opt,name=paramedicid,proto3" json:"paramedicid,omitempty"` Schedulestart *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=schedulestart,proto3" json:"schedulestart,omitempty"` Scheduleend *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=scheduleend,proto3" json:"scheduleend,omitempty"` Duration int32 `protobuf:"varint,5,opt,name=duration,proto3" json:"duration,omitempty"` Usercreate string `protobuf:"bytes,6,opt,name=usercreate,proto3" json:"usercreate,omitempty"` // contains filtered or unexported fields }
func (*ScheduleCreateProto) Descriptor
deprecated
func (*ScheduleCreateProto) Descriptor() ([]byte, []int)
Deprecated: Use ScheduleCreateProto.ProtoReflect.Descriptor instead.
func (*ScheduleCreateProto) GetDuration ¶
func (x *ScheduleCreateProto) GetDuration() int32
func (*ScheduleCreateProto) GetHealthcareid ¶
func (x *ScheduleCreateProto) GetHealthcareid() string
func (*ScheduleCreateProto) GetParamedicid ¶
func (x *ScheduleCreateProto) GetParamedicid() string
func (*ScheduleCreateProto) GetScheduleend ¶
func (x *ScheduleCreateProto) GetScheduleend() *timestamppb.Timestamp
func (*ScheduleCreateProto) GetSchedulestart ¶
func (x *ScheduleCreateProto) GetSchedulestart() *timestamppb.Timestamp
func (*ScheduleCreateProto) GetUsercreate ¶
func (x *ScheduleCreateProto) GetUsercreate() string
func (*ScheduleCreateProto) ProtoMessage ¶
func (*ScheduleCreateProto) ProtoMessage()
func (*ScheduleCreateProto) ProtoReflect ¶
func (x *ScheduleCreateProto) ProtoReflect() protoreflect.Message
func (*ScheduleCreateProto) Reset ¶
func (x *ScheduleCreateProto) Reset()
func (*ScheduleCreateProto) String ¶
func (x *ScheduleCreateProto) String() string
type ScheduleProto ¶
type ScheduleProto struct { Scheduleid string `protobuf:"bytes,1,opt,name=scheduleid,proto3" json:"scheduleid,omitempty"` Healthcareid string `protobuf:"bytes,2,opt,name=healthcareid,proto3" json:"healthcareid,omitempty"` Paramedicid string `protobuf:"bytes,3,opt,name=paramedicid,proto3" json:"paramedicid,omitempty"` Schedulestart string `protobuf:"bytes,4,opt,name=schedulestart,proto3" json:"schedulestart,omitempty"` Scheduleend string `protobuf:"bytes,5,opt,name=scheduleend,proto3" json:"scheduleend,omitempty"` Duration int32 `protobuf:"varint,6,opt,name=duration,proto3" json:"duration,omitempty"` // contains filtered or unexported fields }
func (*ScheduleProto) Descriptor
deprecated
func (*ScheduleProto) Descriptor() ([]byte, []int)
Deprecated: Use ScheduleProto.ProtoReflect.Descriptor instead.
func (*ScheduleProto) GetDuration ¶
func (x *ScheduleProto) GetDuration() int32
func (*ScheduleProto) GetHealthcareid ¶
func (x *ScheduleProto) GetHealthcareid() string
func (*ScheduleProto) GetParamedicid ¶
func (x *ScheduleProto) GetParamedicid() string
func (*ScheduleProto) GetScheduleend ¶
func (x *ScheduleProto) GetScheduleend() string
func (*ScheduleProto) GetScheduleid ¶
func (x *ScheduleProto) GetScheduleid() string
func (*ScheduleProto) GetSchedulestart ¶
func (x *ScheduleProto) GetSchedulestart() string
func (*ScheduleProto) ProtoMessage ¶
func (*ScheduleProto) ProtoMessage()
func (*ScheduleProto) ProtoReflect ¶
func (x *ScheduleProto) ProtoReflect() protoreflect.Message
func (*ScheduleProto) Reset ¶
func (x *ScheduleProto) Reset()
func (*ScheduleProto) String ¶
func (x *ScheduleProto) String() string
type ScheduleServer ¶
type ScheduleServer interface { CreateSchedule(context.Context, *ScheduleCreateProto) (*ScheduleProto, error) FindScheduleAll(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error) FindScheduleAvailable(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error) FindScheduleBooked(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error) BookSlot(context.Context, *SetScheduleProto) (*ScheduledetailProto, error) // contains filtered or unexported methods }
ScheduleServer is the server API for Schedule service. All implementations must embed UnimplementedScheduleServer for forward compatibility
type ScheduledetailProto ¶
type ScheduledetailProto struct { Scheduleslotid int32 `protobuf:"varint,1,opt,name=scheduleslotid,proto3" json:"scheduleslotid,omitempty"` Slottime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=slottime,proto3" json:"slottime,omitempty"` Isbooked bool `protobuf:"varint,3,opt,name=isbooked,proto3" json:"isbooked,omitempty"` // contains filtered or unexported fields }
func (*ScheduledetailProto) Descriptor
deprecated
func (*ScheduledetailProto) Descriptor() ([]byte, []int)
Deprecated: Use ScheduledetailProto.ProtoReflect.Descriptor instead.
func (*ScheduledetailProto) GetIsbooked ¶
func (x *ScheduledetailProto) GetIsbooked() bool
func (*ScheduledetailProto) GetScheduleslotid ¶
func (x *ScheduledetailProto) GetScheduleslotid() int32
func (*ScheduledetailProto) GetSlottime ¶
func (x *ScheduledetailProto) GetSlottime() *timestamppb.Timestamp
func (*ScheduledetailProto) ProtoMessage ¶
func (*ScheduledetailProto) ProtoMessage()
func (*ScheduledetailProto) ProtoReflect ¶
func (x *ScheduledetailProto) ProtoReflect() protoreflect.Message
func (*ScheduledetailProto) Reset ¶
func (x *ScheduledetailProto) Reset()
func (*ScheduledetailProto) String ¶
func (x *ScheduledetailProto) String() string
type SetScheduleProto ¶
type SetScheduleProto struct { Scheduleslotid int32 `protobuf:"varint,1,opt,name=scheduleslotid,proto3" json:"scheduleslotid,omitempty"` // contains filtered or unexported fields }
func (*SetScheduleProto) Descriptor
deprecated
func (*SetScheduleProto) Descriptor() ([]byte, []int)
Deprecated: Use SetScheduleProto.ProtoReflect.Descriptor instead.
func (*SetScheduleProto) GetScheduleslotid ¶
func (x *SetScheduleProto) GetScheduleslotid() int32
func (*SetScheduleProto) ProtoMessage ¶
func (*SetScheduleProto) ProtoMessage()
func (*SetScheduleProto) ProtoReflect ¶
func (x *SetScheduleProto) ProtoReflect() protoreflect.Message
func (*SetScheduleProto) Reset ¶
func (x *SetScheduleProto) Reset()
func (*SetScheduleProto) String ¶
func (x *SetScheduleProto) String() string
type UnimplementedScheduleServer ¶
type UnimplementedScheduleServer struct { }
UnimplementedScheduleServer must be embedded to have forward compatible implementations.
func (UnimplementedScheduleServer) BookSlot ¶
func (UnimplementedScheduleServer) BookSlot(context.Context, *SetScheduleProto) (*ScheduledetailProto, error)
func (UnimplementedScheduleServer) CreateSchedule ¶
func (UnimplementedScheduleServer) CreateSchedule(context.Context, *ScheduleCreateProto) (*ScheduleProto, error)
func (UnimplementedScheduleServer) FindScheduleAll ¶
func (UnimplementedScheduleServer) FindScheduleAll(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error)
func (UnimplementedScheduleServer) FindScheduleAvailable ¶
func (UnimplementedScheduleServer) FindScheduleAvailable(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error)
func (UnimplementedScheduleServer) FindScheduleBooked ¶
func (UnimplementedScheduleServer) FindScheduleBooked(context.Context, *FindScheduleProto) (*ListscheduledetailProto, error)
type UnsafeScheduleServer ¶
type UnsafeScheduleServer interface {
// contains filtered or unexported methods
}
UnsafeScheduleServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ScheduleServer will result in compilation errors.