Documentation ¶
Overview ¶
Code generated by protoc-gen-entgrpc. DO NOT EDIT.
Code generated by protoc-gen-entgrpc. DO NOT EDIT.
Index ¶
- Variables
- func RegisterEquipmentServiceServer(s grpc.ServiceRegistrar, srv EquipmentServiceServer)
- func RegisterVehicleServiceServer(s grpc.ServiceRegistrar, srv VehicleServiceServer)
- type CreateEquipmentRequest
- func (*CreateEquipmentRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateEquipmentRequest) GetEquipment() *Equipment
- func (*CreateEquipmentRequest) ProtoMessage()
- func (x *CreateEquipmentRequest) ProtoReflect() protoreflect.Message
- func (x *CreateEquipmentRequest) Reset()
- func (x *CreateEquipmentRequest) String() string
- type CreateVehicleRequest
- func (*CreateVehicleRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateVehicleRequest) GetVehicle() *Vehicle
- func (*CreateVehicleRequest) ProtoMessage()
- func (x *CreateVehicleRequest) ProtoReflect() protoreflect.Message
- func (x *CreateVehicleRequest) Reset()
- func (x *CreateVehicleRequest) String() string
- type DeleteEquipmentRequest
- func (*DeleteEquipmentRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteEquipmentRequest) GetId() int32
- func (*DeleteEquipmentRequest) ProtoMessage()
- func (x *DeleteEquipmentRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteEquipmentRequest) Reset()
- func (x *DeleteEquipmentRequest) String() string
- type DeleteVehicleRequest
- func (*DeleteVehicleRequest) Descriptor() ([]byte, []int)deprecated
- func (x *DeleteVehicleRequest) GetId() int32
- func (*DeleteVehicleRequest) ProtoMessage()
- func (x *DeleteVehicleRequest) ProtoReflect() protoreflect.Message
- func (x *DeleteVehicleRequest) Reset()
- func (x *DeleteVehicleRequest) String() string
- type Equipment
- func (*Equipment) Descriptor() ([]byte, []int)deprecated
- func (x *Equipment) GetCondition() string
- func (x *Equipment) GetCreateTime() *timestamppb.Timestamp
- func (x *Equipment) GetId() int32
- func (x *Equipment) GetName() string
- func (x *Equipment) GetUpdateTime() *timestamppb.Timestamp
- func (*Equipment) ProtoMessage()
- func (x *Equipment) ProtoReflect() protoreflect.Message
- func (x *Equipment) Reset()
- func (x *Equipment) String() string
- type EquipmentService
- func (svc *EquipmentService) Create(ctx context.Context, req *CreateEquipmentRequest) (*Equipment, error)
- func (svc *EquipmentService) Delete(ctx context.Context, req *DeleteEquipmentRequest) (*emptypb.Empty, error)
- func (svc *EquipmentService) Get(ctx context.Context, req *GetEquipmentRequest) (*Equipment, error)
- func (svc *EquipmentService) Update(ctx context.Context, req *UpdateEquipmentRequest) (*Equipment, error)
- type EquipmentServiceClient
- type EquipmentServiceServer
- type GetEquipmentRequest
- func (*GetEquipmentRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetEquipmentRequest) GetId() int32
- func (x *GetEquipmentRequest) GetView() GetEquipmentRequest_View
- func (*GetEquipmentRequest) ProtoMessage()
- func (x *GetEquipmentRequest) ProtoReflect() protoreflect.Message
- func (x *GetEquipmentRequest) Reset()
- func (x *GetEquipmentRequest) String() string
- type GetEquipmentRequest_View
- func (GetEquipmentRequest_View) Descriptor() protoreflect.EnumDescriptor
- func (x GetEquipmentRequest_View) Enum() *GetEquipmentRequest_View
- func (GetEquipmentRequest_View) EnumDescriptor() ([]byte, []int)deprecated
- func (x GetEquipmentRequest_View) Number() protoreflect.EnumNumber
- func (x GetEquipmentRequest_View) String() string
- func (GetEquipmentRequest_View) Type() protoreflect.EnumType
- type GetVehicleRequest
- func (*GetVehicleRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetVehicleRequest) GetId() int32
- func (x *GetVehicleRequest) GetView() GetVehicleRequest_View
- func (*GetVehicleRequest) ProtoMessage()
- func (x *GetVehicleRequest) ProtoReflect() protoreflect.Message
- func (x *GetVehicleRequest) Reset()
- func (x *GetVehicleRequest) String() string
- type GetVehicleRequest_View
- func (GetVehicleRequest_View) Descriptor() protoreflect.EnumDescriptor
- func (x GetVehicleRequest_View) Enum() *GetVehicleRequest_View
- func (GetVehicleRequest_View) EnumDescriptor() ([]byte, []int)deprecated
- func (x GetVehicleRequest_View) Number() protoreflect.EnumNumber
- func (x GetVehicleRequest_View) String() string
- func (GetVehicleRequest_View) Type() protoreflect.EnumType
- type UnimplementedEquipmentServiceServer
- func (UnimplementedEquipmentServiceServer) Create(context.Context, *CreateEquipmentRequest) (*Equipment, error)
- func (UnimplementedEquipmentServiceServer) Delete(context.Context, *DeleteEquipmentRequest) (*emptypb.Empty, error)
- func (UnimplementedEquipmentServiceServer) Get(context.Context, *GetEquipmentRequest) (*Equipment, error)
- func (UnimplementedEquipmentServiceServer) Update(context.Context, *UpdateEquipmentRequest) (*Equipment, error)
- type UnimplementedVehicleServiceServer
- func (UnimplementedVehicleServiceServer) Create(context.Context, *CreateVehicleRequest) (*Vehicle, error)
- func (UnimplementedVehicleServiceServer) Delete(context.Context, *DeleteVehicleRequest) (*emptypb.Empty, error)
- func (UnimplementedVehicleServiceServer) Get(context.Context, *GetVehicleRequest) (*Vehicle, error)
- func (UnimplementedVehicleServiceServer) Update(context.Context, *UpdateVehicleRequest) (*Vehicle, error)
- type UnsafeEquipmentServiceServer
- type UnsafeVehicleServiceServer
- type UpdateEquipmentRequest
- func (*UpdateEquipmentRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateEquipmentRequest) GetEquipment() *Equipment
- func (*UpdateEquipmentRequest) ProtoMessage()
- func (x *UpdateEquipmentRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateEquipmentRequest) Reset()
- func (x *UpdateEquipmentRequest) String() string
- type UpdateVehicleRequest
- func (*UpdateVehicleRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateVehicleRequest) GetVehicle() *Vehicle
- func (*UpdateVehicleRequest) ProtoMessage()
- func (x *UpdateVehicleRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateVehicleRequest) Reset()
- func (x *UpdateVehicleRequest) String() string
- type Vehicle
- func (*Vehicle) Descriptor() ([]byte, []int)deprecated
- func (x *Vehicle) GetActive() *wrapperspb.BoolValue
- func (x *Vehicle) GetCondition() *wrapperspb.StringValue
- func (x *Vehicle) GetCreateTime() *timestamppb.Timestamp
- func (x *Vehicle) GetId() int32
- func (x *Vehicle) GetMake() string
- func (x *Vehicle) GetMiles() *wrapperspb.Int64Value
- func (x *Vehicle) GetModel() string
- func (x *Vehicle) GetMpg() *wrapperspb.Int64Value
- func (x *Vehicle) GetOwner() *wrapperspb.StringValue
- func (x *Vehicle) GetUpdateTime() *timestamppb.Timestamp
- func (x *Vehicle) GetYear() *wrapperspb.StringValue
- func (*Vehicle) ProtoMessage()
- func (x *Vehicle) ProtoReflect() protoreflect.Message
- func (x *Vehicle) Reset()
- func (x *Vehicle) String() string
- type VehicleService
- func (svc *VehicleService) Create(ctx context.Context, req *CreateVehicleRequest) (*Vehicle, error)
- func (svc *VehicleService) Delete(ctx context.Context, req *DeleteVehicleRequest) (*emptypb.Empty, error)
- func (svc *VehicleService) Get(ctx context.Context, req *GetVehicleRequest) (*Vehicle, error)
- func (svc *VehicleService) Update(ctx context.Context, req *UpdateVehicleRequest) (*Vehicle, error)
- type VehicleServiceClient
- type VehicleServiceServer
Constants ¶
This section is empty.
Variables ¶
var ( GetEquipmentRequest_View_name = map[int32]string{ 0: "VIEW_UNSPECIFIED", 1: "BASIC", 2: "WITH_EDGE_IDS", } GetEquipmentRequest_View_value = map[string]int32{ "VIEW_UNSPECIFIED": 0, "BASIC": 1, "WITH_EDGE_IDS": 2, } )
Enum value maps for GetEquipmentRequest_View.
var ( GetVehicleRequest_View_name = map[int32]string{ 0: "VIEW_UNSPECIFIED", 1: "BASIC", 2: "WITH_EDGE_IDS", } GetVehicleRequest_View_value = map[string]int32{ "VIEW_UNSPECIFIED": 0, "BASIC": 1, "WITH_EDGE_IDS": 2, } )
Enum value maps for GetVehicleRequest_View.
var EquipmentService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "entpb.EquipmentService", HandlerType: (*EquipmentServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Create", Handler: _EquipmentService_Create_Handler, }, { MethodName: "Get", Handler: _EquipmentService_Get_Handler, }, { MethodName: "Update", Handler: _EquipmentService_Update_Handler, }, { MethodName: "Delete", Handler: _EquipmentService_Delete_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "entpb/entpb.proto", }
EquipmentService_ServiceDesc is the grpc.ServiceDesc for EquipmentService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_entpb_entpb_proto protoreflect.FileDescriptor
var VehicleService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "entpb.VehicleService", HandlerType: (*VehicleServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Create", Handler: _VehicleService_Create_Handler, }, { MethodName: "Get", Handler: _VehicleService_Get_Handler, }, { MethodName: "Update", Handler: _VehicleService_Update_Handler, }, { MethodName: "Delete", Handler: _VehicleService_Delete_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "entpb/entpb.proto", }
VehicleService_ServiceDesc is the grpc.ServiceDesc for VehicleService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterEquipmentServiceServer ¶
func RegisterEquipmentServiceServer(s grpc.ServiceRegistrar, srv EquipmentServiceServer)
func RegisterVehicleServiceServer ¶
func RegisterVehicleServiceServer(s grpc.ServiceRegistrar, srv VehicleServiceServer)
Types ¶
type CreateEquipmentRequest ¶
type CreateEquipmentRequest struct { Equipment *Equipment `protobuf:"bytes,1,opt,name=equipment,proto3" json:"equipment,omitempty"` // contains filtered or unexported fields }
func (*CreateEquipmentRequest) Descriptor
deprecated
func (*CreateEquipmentRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateEquipmentRequest.ProtoReflect.Descriptor instead.
func (*CreateEquipmentRequest) GetEquipment ¶
func (x *CreateEquipmentRequest) GetEquipment() *Equipment
func (*CreateEquipmentRequest) ProtoMessage ¶
func (*CreateEquipmentRequest) ProtoMessage()
func (*CreateEquipmentRequest) ProtoReflect ¶
func (x *CreateEquipmentRequest) ProtoReflect() protoreflect.Message
func (*CreateEquipmentRequest) Reset ¶
func (x *CreateEquipmentRequest) Reset()
func (*CreateEquipmentRequest) String ¶
func (x *CreateEquipmentRequest) String() string
type CreateVehicleRequest ¶
type CreateVehicleRequest struct { Vehicle *Vehicle `protobuf:"bytes,1,opt,name=vehicle,proto3" json:"vehicle,omitempty"` // contains filtered or unexported fields }
func (*CreateVehicleRequest) Descriptor
deprecated
func (*CreateVehicleRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateVehicleRequest.ProtoReflect.Descriptor instead.
func (*CreateVehicleRequest) GetVehicle ¶
func (x *CreateVehicleRequest) GetVehicle() *Vehicle
func (*CreateVehicleRequest) ProtoMessage ¶
func (*CreateVehicleRequest) ProtoMessage()
func (*CreateVehicleRequest) ProtoReflect ¶
func (x *CreateVehicleRequest) ProtoReflect() protoreflect.Message
func (*CreateVehicleRequest) Reset ¶
func (x *CreateVehicleRequest) Reset()
func (*CreateVehicleRequest) String ¶
func (x *CreateVehicleRequest) String() string
type DeleteEquipmentRequest ¶
type DeleteEquipmentRequest struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*DeleteEquipmentRequest) Descriptor
deprecated
func (*DeleteEquipmentRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteEquipmentRequest.ProtoReflect.Descriptor instead.
func (*DeleteEquipmentRequest) GetId ¶
func (x *DeleteEquipmentRequest) GetId() int32
func (*DeleteEquipmentRequest) ProtoMessage ¶
func (*DeleteEquipmentRequest) ProtoMessage()
func (*DeleteEquipmentRequest) ProtoReflect ¶
func (x *DeleteEquipmentRequest) ProtoReflect() protoreflect.Message
func (*DeleteEquipmentRequest) Reset ¶
func (x *DeleteEquipmentRequest) Reset()
func (*DeleteEquipmentRequest) String ¶
func (x *DeleteEquipmentRequest) String() string
type DeleteVehicleRequest ¶
type DeleteVehicleRequest struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*DeleteVehicleRequest) Descriptor
deprecated
func (*DeleteVehicleRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteVehicleRequest.ProtoReflect.Descriptor instead.
func (*DeleteVehicleRequest) GetId ¶
func (x *DeleteVehicleRequest) GetId() int32
func (*DeleteVehicleRequest) ProtoMessage ¶
func (*DeleteVehicleRequest) ProtoMessage()
func (*DeleteVehicleRequest) ProtoReflect ¶
func (x *DeleteVehicleRequest) ProtoReflect() protoreflect.Message
func (*DeleteVehicleRequest) Reset ¶
func (x *DeleteVehicleRequest) Reset()
func (*DeleteVehicleRequest) String ¶
func (x *DeleteVehicleRequest) String() string
type Equipment ¶
type Equipment struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` CreateTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` UpdateTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"` Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` Condition string `protobuf:"bytes,5,opt,name=condition,proto3" json:"condition,omitempty"` // contains filtered or unexported fields }
func (*Equipment) Descriptor
deprecated
func (*Equipment) GetCondition ¶
func (*Equipment) GetCreateTime ¶
func (x *Equipment) GetCreateTime() *timestamppb.Timestamp
func (*Equipment) GetUpdateTime ¶
func (x *Equipment) GetUpdateTime() *timestamppb.Timestamp
func (*Equipment) ProtoMessage ¶
func (*Equipment) ProtoMessage()
func (*Equipment) ProtoReflect ¶
func (x *Equipment) ProtoReflect() protoreflect.Message
type EquipmentService ¶
type EquipmentService struct { UnimplementedEquipmentServiceServer // contains filtered or unexported fields }
EquipmentService implements EquipmentServiceServer
func NewEquipmentService ¶
func NewEquipmentService(client *ent.Client) *EquipmentService
NewEquipmentService returns a new EquipmentService
func (*EquipmentService) Create ¶
func (svc *EquipmentService) Create(ctx context.Context, req *CreateEquipmentRequest) (*Equipment, error)
Create implements EquipmentServiceServer.Create
func (*EquipmentService) Delete ¶
func (svc *EquipmentService) Delete(ctx context.Context, req *DeleteEquipmentRequest) (*emptypb.Empty, error)
Delete implements EquipmentServiceServer.Delete
func (*EquipmentService) Get ¶
func (svc *EquipmentService) Get(ctx context.Context, req *GetEquipmentRequest) (*Equipment, error)
Get implements EquipmentServiceServer.Get
func (*EquipmentService) Update ¶
func (svc *EquipmentService) Update(ctx context.Context, req *UpdateEquipmentRequest) (*Equipment, error)
Update implements EquipmentServiceServer.Update
type EquipmentServiceClient ¶
type EquipmentServiceClient interface { Create(ctx context.Context, in *CreateEquipmentRequest, opts ...grpc.CallOption) (*Equipment, error) Get(ctx context.Context, in *GetEquipmentRequest, opts ...grpc.CallOption) (*Equipment, error) Update(ctx context.Context, in *UpdateEquipmentRequest, opts ...grpc.CallOption) (*Equipment, error) Delete(ctx context.Context, in *DeleteEquipmentRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) }
EquipmentServiceClient is the client API for EquipmentService 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 NewEquipmentServiceClient ¶
func NewEquipmentServiceClient(cc grpc.ClientConnInterface) EquipmentServiceClient
type EquipmentServiceServer ¶
type EquipmentServiceServer interface { Create(context.Context, *CreateEquipmentRequest) (*Equipment, error) Get(context.Context, *GetEquipmentRequest) (*Equipment, error) Update(context.Context, *UpdateEquipmentRequest) (*Equipment, error) Delete(context.Context, *DeleteEquipmentRequest) (*emptypb.Empty, error) // contains filtered or unexported methods }
EquipmentServiceServer is the server API for EquipmentService service. All implementations must embed UnimplementedEquipmentServiceServer for forward compatibility
type GetEquipmentRequest ¶
type GetEquipmentRequest struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` View GetEquipmentRequest_View `protobuf:"varint,2,opt,name=view,proto3,enum=entpb.GetEquipmentRequest_View" json:"view,omitempty"` // contains filtered or unexported fields }
func (*GetEquipmentRequest) Descriptor
deprecated
func (*GetEquipmentRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetEquipmentRequest.ProtoReflect.Descriptor instead.
func (*GetEquipmentRequest) GetId ¶
func (x *GetEquipmentRequest) GetId() int32
func (*GetEquipmentRequest) GetView ¶
func (x *GetEquipmentRequest) GetView() GetEquipmentRequest_View
func (*GetEquipmentRequest) ProtoMessage ¶
func (*GetEquipmentRequest) ProtoMessage()
func (*GetEquipmentRequest) ProtoReflect ¶
func (x *GetEquipmentRequest) ProtoReflect() protoreflect.Message
func (*GetEquipmentRequest) Reset ¶
func (x *GetEquipmentRequest) Reset()
func (*GetEquipmentRequest) String ¶
func (x *GetEquipmentRequest) String() string
type GetEquipmentRequest_View ¶
type GetEquipmentRequest_View int32
const ( GetEquipmentRequest_VIEW_UNSPECIFIED GetEquipmentRequest_View = 0 GetEquipmentRequest_BASIC GetEquipmentRequest_View = 1 GetEquipmentRequest_WITH_EDGE_IDS GetEquipmentRequest_View = 2 )
func (GetEquipmentRequest_View) Descriptor ¶
func (GetEquipmentRequest_View) Descriptor() protoreflect.EnumDescriptor
func (GetEquipmentRequest_View) Enum ¶
func (x GetEquipmentRequest_View) Enum() *GetEquipmentRequest_View
func (GetEquipmentRequest_View) EnumDescriptor
deprecated
func (GetEquipmentRequest_View) EnumDescriptor() ([]byte, []int)
Deprecated: Use GetEquipmentRequest_View.Descriptor instead.
func (GetEquipmentRequest_View) Number ¶
func (x GetEquipmentRequest_View) Number() protoreflect.EnumNumber
func (GetEquipmentRequest_View) String ¶
func (x GetEquipmentRequest_View) String() string
func (GetEquipmentRequest_View) Type ¶
func (GetEquipmentRequest_View) Type() protoreflect.EnumType
type GetVehicleRequest ¶
type GetVehicleRequest struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` View GetVehicleRequest_View `protobuf:"varint,2,opt,name=view,proto3,enum=entpb.GetVehicleRequest_View" json:"view,omitempty"` // contains filtered or unexported fields }
func (*GetVehicleRequest) Descriptor
deprecated
func (*GetVehicleRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetVehicleRequest.ProtoReflect.Descriptor instead.
func (*GetVehicleRequest) GetId ¶
func (x *GetVehicleRequest) GetId() int32
func (*GetVehicleRequest) GetView ¶
func (x *GetVehicleRequest) GetView() GetVehicleRequest_View
func (*GetVehicleRequest) ProtoMessage ¶
func (*GetVehicleRequest) ProtoMessage()
func (*GetVehicleRequest) ProtoReflect ¶
func (x *GetVehicleRequest) ProtoReflect() protoreflect.Message
func (*GetVehicleRequest) Reset ¶
func (x *GetVehicleRequest) Reset()
func (*GetVehicleRequest) String ¶
func (x *GetVehicleRequest) String() string
type GetVehicleRequest_View ¶
type GetVehicleRequest_View int32
const ( GetVehicleRequest_VIEW_UNSPECIFIED GetVehicleRequest_View = 0 GetVehicleRequest_BASIC GetVehicleRequest_View = 1 GetVehicleRequest_WITH_EDGE_IDS GetVehicleRequest_View = 2 )
func (GetVehicleRequest_View) Descriptor ¶
func (GetVehicleRequest_View) Descriptor() protoreflect.EnumDescriptor
func (GetVehicleRequest_View) Enum ¶
func (x GetVehicleRequest_View) Enum() *GetVehicleRequest_View
func (GetVehicleRequest_View) EnumDescriptor
deprecated
func (GetVehicleRequest_View) EnumDescriptor() ([]byte, []int)
Deprecated: Use GetVehicleRequest_View.Descriptor instead.
func (GetVehicleRequest_View) Number ¶
func (x GetVehicleRequest_View) Number() protoreflect.EnumNumber
func (GetVehicleRequest_View) String ¶
func (x GetVehicleRequest_View) String() string
func (GetVehicleRequest_View) Type ¶
func (GetVehicleRequest_View) Type() protoreflect.EnumType
type UnimplementedEquipmentServiceServer ¶
type UnimplementedEquipmentServiceServer struct { }
UnimplementedEquipmentServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedEquipmentServiceServer) Create ¶
func (UnimplementedEquipmentServiceServer) Create(context.Context, *CreateEquipmentRequest) (*Equipment, error)
func (UnimplementedEquipmentServiceServer) Delete ¶
func (UnimplementedEquipmentServiceServer) Delete(context.Context, *DeleteEquipmentRequest) (*emptypb.Empty, error)
func (UnimplementedEquipmentServiceServer) Get ¶
func (UnimplementedEquipmentServiceServer) Get(context.Context, *GetEquipmentRequest) (*Equipment, error)
func (UnimplementedEquipmentServiceServer) Update ¶
func (UnimplementedEquipmentServiceServer) Update(context.Context, *UpdateEquipmentRequest) (*Equipment, error)
type UnimplementedVehicleServiceServer ¶
type UnimplementedVehicleServiceServer struct { }
UnimplementedVehicleServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedVehicleServiceServer) Create ¶
func (UnimplementedVehicleServiceServer) Create(context.Context, *CreateVehicleRequest) (*Vehicle, error)
func (UnimplementedVehicleServiceServer) Delete ¶
func (UnimplementedVehicleServiceServer) Delete(context.Context, *DeleteVehicleRequest) (*emptypb.Empty, error)
func (UnimplementedVehicleServiceServer) Get ¶
func (UnimplementedVehicleServiceServer) Get(context.Context, *GetVehicleRequest) (*Vehicle, error)
func (UnimplementedVehicleServiceServer) Update ¶
func (UnimplementedVehicleServiceServer) Update(context.Context, *UpdateVehicleRequest) (*Vehicle, error)
type UnsafeEquipmentServiceServer ¶
type UnsafeEquipmentServiceServer interface {
// contains filtered or unexported methods
}
UnsafeEquipmentServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EquipmentServiceServer will result in compilation errors.
type UnsafeVehicleServiceServer ¶
type UnsafeVehicleServiceServer interface {
// contains filtered or unexported methods
}
UnsafeVehicleServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to VehicleServiceServer will result in compilation errors.
type UpdateEquipmentRequest ¶
type UpdateEquipmentRequest struct { Equipment *Equipment `protobuf:"bytes,1,opt,name=equipment,proto3" json:"equipment,omitempty"` // contains filtered or unexported fields }
func (*UpdateEquipmentRequest) Descriptor
deprecated
func (*UpdateEquipmentRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateEquipmentRequest.ProtoReflect.Descriptor instead.
func (*UpdateEquipmentRequest) GetEquipment ¶
func (x *UpdateEquipmentRequest) GetEquipment() *Equipment
func (*UpdateEquipmentRequest) ProtoMessage ¶
func (*UpdateEquipmentRequest) ProtoMessage()
func (*UpdateEquipmentRequest) ProtoReflect ¶
func (x *UpdateEquipmentRequest) ProtoReflect() protoreflect.Message
func (*UpdateEquipmentRequest) Reset ¶
func (x *UpdateEquipmentRequest) Reset()
func (*UpdateEquipmentRequest) String ¶
func (x *UpdateEquipmentRequest) String() string
type UpdateVehicleRequest ¶
type UpdateVehicleRequest struct { Vehicle *Vehicle `protobuf:"bytes,1,opt,name=vehicle,proto3" json:"vehicle,omitempty"` // contains filtered or unexported fields }
func (*UpdateVehicleRequest) Descriptor
deprecated
func (*UpdateVehicleRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateVehicleRequest.ProtoReflect.Descriptor instead.
func (*UpdateVehicleRequest) GetVehicle ¶
func (x *UpdateVehicleRequest) GetVehicle() *Vehicle
func (*UpdateVehicleRequest) ProtoMessage ¶
func (*UpdateVehicleRequest) ProtoMessage()
func (*UpdateVehicleRequest) ProtoReflect ¶
func (x *UpdateVehicleRequest) ProtoReflect() protoreflect.Message
func (*UpdateVehicleRequest) Reset ¶
func (x *UpdateVehicleRequest) Reset()
func (*UpdateVehicleRequest) String ¶
func (x *UpdateVehicleRequest) String() string
type Vehicle ¶
type Vehicle struct { Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` CreateTime *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"` UpdateTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=update_time,json=updateTime,proto3" json:"update_time,omitempty"` Make string `protobuf:"bytes,4,opt,name=make,proto3" json:"make,omitempty"` Model string `protobuf:"bytes,5,opt,name=model,proto3" json:"model,omitempty"` Miles *wrapperspb.Int64Value `protobuf:"bytes,6,opt,name=miles,proto3" json:"miles,omitempty"` Mpg *wrapperspb.Int64Value `protobuf:"bytes,7,opt,name=mpg,proto3" json:"mpg,omitempty"` Owner *wrapperspb.StringValue `protobuf:"bytes,8,opt,name=owner,proto3" json:"owner,omitempty"` Year *wrapperspb.StringValue `protobuf:"bytes,9,opt,name=year,proto3" json:"year,omitempty"` Active *wrapperspb.BoolValue `protobuf:"bytes,10,opt,name=active,proto3" json:"active,omitempty"` Condition *wrapperspb.StringValue `protobuf:"bytes,11,opt,name=condition,proto3" json:"condition,omitempty"` // contains filtered or unexported fields }
func (*Vehicle) Descriptor
deprecated
func (*Vehicle) GetActive ¶
func (x *Vehicle) GetActive() *wrapperspb.BoolValue
func (*Vehicle) GetCondition ¶
func (x *Vehicle) GetCondition() *wrapperspb.StringValue
func (*Vehicle) GetCreateTime ¶
func (x *Vehicle) GetCreateTime() *timestamppb.Timestamp
func (*Vehicle) GetMiles ¶
func (x *Vehicle) GetMiles() *wrapperspb.Int64Value
func (*Vehicle) GetMpg ¶
func (x *Vehicle) GetMpg() *wrapperspb.Int64Value
func (*Vehicle) GetOwner ¶
func (x *Vehicle) GetOwner() *wrapperspb.StringValue
func (*Vehicle) GetUpdateTime ¶
func (x *Vehicle) GetUpdateTime() *timestamppb.Timestamp
func (*Vehicle) GetYear ¶
func (x *Vehicle) GetYear() *wrapperspb.StringValue
func (*Vehicle) ProtoMessage ¶
func (*Vehicle) ProtoMessage()
func (*Vehicle) ProtoReflect ¶
func (x *Vehicle) ProtoReflect() protoreflect.Message
type VehicleService ¶
type VehicleService struct { UnimplementedVehicleServiceServer // contains filtered or unexported fields }
VehicleService implements VehicleServiceServer
func NewVehicleService ¶
func NewVehicleService(client *ent.Client) *VehicleService
NewVehicleService returns a new VehicleService
func (*VehicleService) Create ¶
func (svc *VehicleService) Create(ctx context.Context, req *CreateVehicleRequest) (*Vehicle, error)
Create implements VehicleServiceServer.Create
func (*VehicleService) Delete ¶
func (svc *VehicleService) Delete(ctx context.Context, req *DeleteVehicleRequest) (*emptypb.Empty, error)
Delete implements VehicleServiceServer.Delete
func (*VehicleService) Get ¶
func (svc *VehicleService) Get(ctx context.Context, req *GetVehicleRequest) (*Vehicle, error)
Get implements VehicleServiceServer.Get
func (*VehicleService) Update ¶
func (svc *VehicleService) Update(ctx context.Context, req *UpdateVehicleRequest) (*Vehicle, error)
Update implements VehicleServiceServer.Update
type VehicleServiceClient ¶
type VehicleServiceClient interface { Create(ctx context.Context, in *CreateVehicleRequest, opts ...grpc.CallOption) (*Vehicle, error) Get(ctx context.Context, in *GetVehicleRequest, opts ...grpc.CallOption) (*Vehicle, error) Update(ctx context.Context, in *UpdateVehicleRequest, opts ...grpc.CallOption) (*Vehicle, error) Delete(ctx context.Context, in *DeleteVehicleRequest, opts ...grpc.CallOption) (*emptypb.Empty, error) }
VehicleServiceClient is the client API for VehicleService 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 NewVehicleServiceClient ¶
func NewVehicleServiceClient(cc grpc.ClientConnInterface) VehicleServiceClient
type VehicleServiceServer ¶
type VehicleServiceServer interface { Create(context.Context, *CreateVehicleRequest) (*Vehicle, error) Get(context.Context, *GetVehicleRequest) (*Vehicle, error) Update(context.Context, *UpdateVehicleRequest) (*Vehicle, error) Delete(context.Context, *DeleteVehicleRequest) (*emptypb.Empty, error) // contains filtered or unexported methods }
VehicleServiceServer is the server API for VehicleService service. All implementations must embed UnimplementedVehicleServiceServer for forward compatibility