deleted bookings management
Some checks failed
Build and Push Docker Image / build_and_push (push) Has been cancelled
Some checks failed
Build and Push Docker Image / build_and_push (push) Has been cancelled
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
//COOPGO Groups Management gRPC service definition
|
||||
|
||||
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
|
||||
// versions:
|
||||
// - protoc-gen-go-grpc v1.2.0
|
||||
// - protoc v3.19.4
|
||||
// - protoc-gen-go-grpc v1.5.1
|
||||
// - protoc v6.31.1
|
||||
// source: fleets.proto
|
||||
|
||||
package grpcapi
|
||||
@@ -15,8 +17,22 @@ import (
|
||||
|
||||
// This is a compile-time assertion to ensure that this generated file
|
||||
// is compatible with the grpc package it is being compiled against.
|
||||
// Requires gRPC-Go v1.32.0 or later.
|
||||
const _ = grpc.SupportPackageIsVersion7
|
||||
// Requires gRPC-Go v1.64.0 or later.
|
||||
const _ = grpc.SupportPackageIsVersion9
|
||||
|
||||
const (
|
||||
Fleets_AddVehicle_FullMethodName = "/Fleets/AddVehicle"
|
||||
Fleets_GetVehicle_FullMethodName = "/Fleets/GetVehicle"
|
||||
Fleets_GetVehicles_FullMethodName = "/Fleets/GetVehicles"
|
||||
Fleets_UpdateVehicle_FullMethodName = "/Fleets/UpdateVehicle"
|
||||
Fleets_CreateBooking_FullMethodName = "/Fleets/CreateBooking"
|
||||
Fleets_GetBooking_FullMethodName = "/Fleets/GetBooking"
|
||||
Fleets_GetBookings_FullMethodName = "/Fleets/GetBookings"
|
||||
Fleets_GetDriverBookings_FullMethodName = "/Fleets/GetDriverBookings"
|
||||
Fleets_UpdateBooking_FullMethodName = "/Fleets/UpdateBooking"
|
||||
Fleets_DeleteBooking_FullMethodName = "/Fleets/DeleteBooking"
|
||||
Fleets_FindVehicle_FullMethodName = "/Fleets/FindVehicle"
|
||||
)
|
||||
|
||||
// FleetsClient is the client API for Fleets service.
|
||||
//
|
||||
@@ -27,14 +43,14 @@ type FleetsClient interface {
|
||||
GetVehicle(ctx context.Context, in *GetVehicleRequest, opts ...grpc.CallOption) (*GetVehicleResponse, error)
|
||||
GetVehicles(ctx context.Context, in *GetVehiclesRequest, opts ...grpc.CallOption) (*GetVehiclesResponse, error)
|
||||
UpdateVehicle(ctx context.Context, in *UpdateVehicleRequest, opts ...grpc.CallOption) (*UpdateVehicleResponse, error)
|
||||
//Bookings
|
||||
// Bookings
|
||||
CreateBooking(ctx context.Context, in *CreateBookingRequest, opts ...grpc.CallOption) (*CreateBookingResponse, error)
|
||||
GetBooking(ctx context.Context, in *GetBookingRequest, opts ...grpc.CallOption) (*GetBookingResponse, error)
|
||||
GetBookings(ctx context.Context, in *GetBookingsRequest, opts ...grpc.CallOption) (*GetBookingsResponse, error)
|
||||
GetDriverBookings(ctx context.Context, in *GetDriverBookingsRequest, opts ...grpc.CallOption) (*GetDriverBookingsResponse, error)
|
||||
UpdateBooking(ctx context.Context, in *UpdateBookingRequest, opts ...grpc.CallOption) (*UpdateBookingResponse, error)
|
||||
DeleteBooking(ctx context.Context, in *DeleteBookingRequest, opts ...grpc.CallOption) (*DeleteBookingResponse, error)
|
||||
//Search / Availabilities
|
||||
// Search / Availabilities
|
||||
FindVehicle(ctx context.Context, in *FindVehicleRequest, opts ...grpc.CallOption) (*FindVehicleResponse, error)
|
||||
}
|
||||
|
||||
@@ -47,8 +63,9 @@ func NewFleetsClient(cc grpc.ClientConnInterface) FleetsClient {
|
||||
}
|
||||
|
||||
func (c *fleetsClient) AddVehicle(ctx context.Context, in *AddVehicleRequest, opts ...grpc.CallOption) (*AddVehicleResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(AddVehicleResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/AddVehicle", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_AddVehicle_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -56,8 +73,9 @@ func (c *fleetsClient) AddVehicle(ctx context.Context, in *AddVehicleRequest, op
|
||||
}
|
||||
|
||||
func (c *fleetsClient) GetVehicle(ctx context.Context, in *GetVehicleRequest, opts ...grpc.CallOption) (*GetVehicleResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(GetVehicleResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/GetVehicle", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_GetVehicle_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -65,8 +83,9 @@ func (c *fleetsClient) GetVehicle(ctx context.Context, in *GetVehicleRequest, op
|
||||
}
|
||||
|
||||
func (c *fleetsClient) GetVehicles(ctx context.Context, in *GetVehiclesRequest, opts ...grpc.CallOption) (*GetVehiclesResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(GetVehiclesResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/GetVehicles", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_GetVehicles_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -74,8 +93,9 @@ func (c *fleetsClient) GetVehicles(ctx context.Context, in *GetVehiclesRequest,
|
||||
}
|
||||
|
||||
func (c *fleetsClient) UpdateVehicle(ctx context.Context, in *UpdateVehicleRequest, opts ...grpc.CallOption) (*UpdateVehicleResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(UpdateVehicleResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/UpdateVehicle", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_UpdateVehicle_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -83,8 +103,9 @@ func (c *fleetsClient) UpdateVehicle(ctx context.Context, in *UpdateVehicleReque
|
||||
}
|
||||
|
||||
func (c *fleetsClient) CreateBooking(ctx context.Context, in *CreateBookingRequest, opts ...grpc.CallOption) (*CreateBookingResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(CreateBookingResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/CreateBooking", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_CreateBooking_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -92,8 +113,9 @@ func (c *fleetsClient) CreateBooking(ctx context.Context, in *CreateBookingReque
|
||||
}
|
||||
|
||||
func (c *fleetsClient) GetBooking(ctx context.Context, in *GetBookingRequest, opts ...grpc.CallOption) (*GetBookingResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(GetBookingResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/GetBooking", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_GetBooking_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -101,8 +123,9 @@ func (c *fleetsClient) GetBooking(ctx context.Context, in *GetBookingRequest, op
|
||||
}
|
||||
|
||||
func (c *fleetsClient) GetBookings(ctx context.Context, in *GetBookingsRequest, opts ...grpc.CallOption) (*GetBookingsResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(GetBookingsResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/GetBookings", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_GetBookings_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -110,8 +133,9 @@ func (c *fleetsClient) GetBookings(ctx context.Context, in *GetBookingsRequest,
|
||||
}
|
||||
|
||||
func (c *fleetsClient) GetDriverBookings(ctx context.Context, in *GetDriverBookingsRequest, opts ...grpc.CallOption) (*GetDriverBookingsResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(GetDriverBookingsResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/GetDriverBookings", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_GetDriverBookings_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -119,8 +143,9 @@ func (c *fleetsClient) GetDriverBookings(ctx context.Context, in *GetDriverBooki
|
||||
}
|
||||
|
||||
func (c *fleetsClient) UpdateBooking(ctx context.Context, in *UpdateBookingRequest, opts ...grpc.CallOption) (*UpdateBookingResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(UpdateBookingResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/UpdateBooking", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_UpdateBooking_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -128,8 +153,9 @@ func (c *fleetsClient) UpdateBooking(ctx context.Context, in *UpdateBookingReque
|
||||
}
|
||||
|
||||
func (c *fleetsClient) DeleteBooking(ctx context.Context, in *DeleteBookingRequest, opts ...grpc.CallOption) (*DeleteBookingResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(DeleteBookingResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/DeleteBooking", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_DeleteBooking_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -137,8 +163,9 @@ func (c *fleetsClient) DeleteBooking(ctx context.Context, in *DeleteBookingReque
|
||||
}
|
||||
|
||||
func (c *fleetsClient) FindVehicle(ctx context.Context, in *FindVehicleRequest, opts ...grpc.CallOption) (*FindVehicleResponse, error) {
|
||||
cOpts := append([]grpc.CallOption{grpc.StaticMethod()}, opts...)
|
||||
out := new(FindVehicleResponse)
|
||||
err := c.cc.Invoke(ctx, "/Fleets/FindVehicle", in, out, opts...)
|
||||
err := c.cc.Invoke(ctx, Fleets_FindVehicle_FullMethodName, in, out, cOpts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -147,28 +174,31 @@ func (c *fleetsClient) FindVehicle(ctx context.Context, in *FindVehicleRequest,
|
||||
|
||||
// FleetsServer is the server API for Fleets service.
|
||||
// All implementations must embed UnimplementedFleetsServer
|
||||
// for forward compatibility
|
||||
// for forward compatibility.
|
||||
type FleetsServer interface {
|
||||
// Vehicles management
|
||||
AddVehicle(context.Context, *AddVehicleRequest) (*AddVehicleResponse, error)
|
||||
GetVehicle(context.Context, *GetVehicleRequest) (*GetVehicleResponse, error)
|
||||
GetVehicles(context.Context, *GetVehiclesRequest) (*GetVehiclesResponse, error)
|
||||
UpdateVehicle(context.Context, *UpdateVehicleRequest) (*UpdateVehicleResponse, error)
|
||||
//Bookings
|
||||
// Bookings
|
||||
CreateBooking(context.Context, *CreateBookingRequest) (*CreateBookingResponse, error)
|
||||
GetBooking(context.Context, *GetBookingRequest) (*GetBookingResponse, error)
|
||||
GetBookings(context.Context, *GetBookingsRequest) (*GetBookingsResponse, error)
|
||||
GetDriverBookings(context.Context, *GetDriverBookingsRequest) (*GetDriverBookingsResponse, error)
|
||||
UpdateBooking(context.Context, *UpdateBookingRequest) (*UpdateBookingResponse, error)
|
||||
DeleteBooking(context.Context, *DeleteBookingRequest) (*DeleteBookingResponse, error)
|
||||
//Search / Availabilities
|
||||
// Search / Availabilities
|
||||
FindVehicle(context.Context, *FindVehicleRequest) (*FindVehicleResponse, error)
|
||||
mustEmbedUnimplementedFleetsServer()
|
||||
}
|
||||
|
||||
// UnimplementedFleetsServer must be embedded to have forward compatible implementations.
|
||||
type UnimplementedFleetsServer struct {
|
||||
}
|
||||
// UnimplementedFleetsServer must be embedded to have
|
||||
// forward compatible implementations.
|
||||
//
|
||||
// NOTE: this should be embedded by value instead of pointer to avoid a nil
|
||||
// pointer dereference when methods are called.
|
||||
type UnimplementedFleetsServer struct{}
|
||||
|
||||
func (UnimplementedFleetsServer) AddVehicle(context.Context, *AddVehicleRequest) (*AddVehicleResponse, error) {
|
||||
return nil, status.Errorf(codes.Unimplemented, "method AddVehicle not implemented")
|
||||
@@ -204,6 +234,7 @@ func (UnimplementedFleetsServer) FindVehicle(context.Context, *FindVehicleReques
|
||||
return nil, status.Errorf(codes.Unimplemented, "method FindVehicle not implemented")
|
||||
}
|
||||
func (UnimplementedFleetsServer) mustEmbedUnimplementedFleetsServer() {}
|
||||
func (UnimplementedFleetsServer) testEmbeddedByValue() {}
|
||||
|
||||
// UnsafeFleetsServer may be embedded to opt out of forward compatibility for this service.
|
||||
// Use of this interface is not recommended, as added methods to FleetsServer will
|
||||
@@ -213,6 +244,13 @@ type UnsafeFleetsServer interface {
|
||||
}
|
||||
|
||||
func RegisterFleetsServer(s grpc.ServiceRegistrar, srv FleetsServer) {
|
||||
// If the following call pancis, it indicates UnimplementedFleetsServer was
|
||||
// embedded by pointer and is nil. This will cause panics if an
|
||||
// unimplemented method is ever invoked, so we test this at initialization
|
||||
// time to prevent it from happening at runtime later due to I/O.
|
||||
if t, ok := srv.(interface{ testEmbeddedByValue() }); ok {
|
||||
t.testEmbeddedByValue()
|
||||
}
|
||||
s.RegisterService(&Fleets_ServiceDesc, srv)
|
||||
}
|
||||
|
||||
@@ -226,7 +264,7 @@ func _Fleets_AddVehicle_Handler(srv interface{}, ctx context.Context, dec func(i
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/AddVehicle",
|
||||
FullMethod: Fleets_AddVehicle_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).AddVehicle(ctx, req.(*AddVehicleRequest))
|
||||
@@ -244,7 +282,7 @@ func _Fleets_GetVehicle_Handler(srv interface{}, ctx context.Context, dec func(i
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/GetVehicle",
|
||||
FullMethod: Fleets_GetVehicle_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).GetVehicle(ctx, req.(*GetVehicleRequest))
|
||||
@@ -262,7 +300,7 @@ func _Fleets_GetVehicles_Handler(srv interface{}, ctx context.Context, dec func(
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/GetVehicles",
|
||||
FullMethod: Fleets_GetVehicles_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).GetVehicles(ctx, req.(*GetVehiclesRequest))
|
||||
@@ -280,7 +318,7 @@ func _Fleets_UpdateVehicle_Handler(srv interface{}, ctx context.Context, dec fun
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/UpdateVehicle",
|
||||
FullMethod: Fleets_UpdateVehicle_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).UpdateVehicle(ctx, req.(*UpdateVehicleRequest))
|
||||
@@ -298,7 +336,7 @@ func _Fleets_CreateBooking_Handler(srv interface{}, ctx context.Context, dec fun
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/CreateBooking",
|
||||
FullMethod: Fleets_CreateBooking_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).CreateBooking(ctx, req.(*CreateBookingRequest))
|
||||
@@ -316,7 +354,7 @@ func _Fleets_GetBooking_Handler(srv interface{}, ctx context.Context, dec func(i
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/GetBooking",
|
||||
FullMethod: Fleets_GetBooking_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).GetBooking(ctx, req.(*GetBookingRequest))
|
||||
@@ -334,7 +372,7 @@ func _Fleets_GetBookings_Handler(srv interface{}, ctx context.Context, dec func(
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/GetBookings",
|
||||
FullMethod: Fleets_GetBookings_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).GetBookings(ctx, req.(*GetBookingsRequest))
|
||||
@@ -352,7 +390,7 @@ func _Fleets_GetDriverBookings_Handler(srv interface{}, ctx context.Context, dec
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/GetDriverBookings",
|
||||
FullMethod: Fleets_GetDriverBookings_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).GetDriverBookings(ctx, req.(*GetDriverBookingsRequest))
|
||||
@@ -370,7 +408,7 @@ func _Fleets_UpdateBooking_Handler(srv interface{}, ctx context.Context, dec fun
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/UpdateBooking",
|
||||
FullMethod: Fleets_UpdateBooking_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).UpdateBooking(ctx, req.(*UpdateBookingRequest))
|
||||
@@ -388,7 +426,7 @@ func _Fleets_DeleteBooking_Handler(srv interface{}, ctx context.Context, dec fun
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/DeleteBooking",
|
||||
FullMethod: Fleets_DeleteBooking_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).DeleteBooking(ctx, req.(*DeleteBookingRequest))
|
||||
@@ -406,7 +444,7 @@ func _Fleets_FindVehicle_Handler(srv interface{}, ctx context.Context, dec func(
|
||||
}
|
||||
info := &grpc.UnaryServerInfo{
|
||||
Server: srv,
|
||||
FullMethod: "/Fleets/FindVehicle",
|
||||
FullMethod: Fleets_FindVehicle_FullMethodName,
|
||||
}
|
||||
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
||||
return srv.(FleetsServer).FindVehicle(ctx, req.(*FindVehicleRequest))
|
||||
|
||||
Reference in New Issue
Block a user