diff --git a/Sources/action/action.go b/Sources/action/action.go index 31d773b..e8ae50c 100644 --- a/Sources/action/action.go +++ b/Sources/action/action.go @@ -9,16 +9,15 @@ type ServiceImpl struct { } /* - Send command to arm the drone. - - Arming a drone normally causes motors to spin at idle. - Before arming take all safety precautions and stand clear of the drone! - +Arm Send command to arm the drone. + Arming a drone normally causes motors to spin at idle. + Before arming take all safety precautions and stand clear of the drone! */ +func (s *ServiceImpl) Arm( + ctx context.Context, -func (s *ServiceImpl) Arm(ctx context.Context) (*ArmResponse, error) { - +) (*ArmResponse, error) { request := &ArmRequest{} response, err := s.Client.Arm(ctx, request) if err != nil { @@ -28,18 +27,17 @@ func (s *ServiceImpl) Arm(ctx context.Context) (*ArmResponse, error) { } /* - Send command to force-arm the drone without any checks. - - Attention: this is not to be used for normal flying but only bench tests! - - Arming a drone normally causes motors to spin at idle. - Before arming take all safety precautions and stand clear of the drone! +ArmForce Send command to force-arm the drone without any checks. + Attention: this is not to be used for normal flying but only bench tests! + Arming a drone normally causes motors to spin at idle. + Before arming take all safety precautions and stand clear of the drone! */ +func (s *ServiceImpl) ArmForce( + ctx context.Context, -func (s *ServiceImpl) ArmForce(ctx context.Context) (*ArmForceResponse, error) { - +) (*ArmForceResponse, error) { request := &ArmForceRequest{} response, err := s.Client.ArmForce(ctx, request) if err != nil { @@ -49,16 +47,15 @@ func (s *ServiceImpl) ArmForce(ctx context.Context) (*ArmForceResponse, error) { } /* - Send command to disarm the drone. - - This will disarm a drone that considers itself landed. If flying, the drone should - reject the disarm command. Disarming means that all motors will stop. - +Disarm Send command to disarm the drone. + This will disarm a drone that considers itself landed. If flying, the drone should + reject the disarm command. Disarming means that all motors will stop. */ +func (s *ServiceImpl) Disarm( + ctx context.Context, -func (s *ServiceImpl) Disarm(ctx context.Context) (*DisarmResponse, error) { - +) (*DisarmResponse, error) { request := &DisarmRequest{} response, err := s.Client.Disarm(ctx, request) if err != nil { @@ -68,18 +65,17 @@ func (s *ServiceImpl) Disarm(ctx context.Context) (*DisarmResponse, error) { } /* - Send command to take off and hover. - - This switches the drone into position control mode and commands - it to take off and hover at the takeoff altitude. - - Note that the vehicle must be armed before it can take off. +Takeoff Send command to take off and hover. + This switches the drone into position control mode and commands + it to take off and hover at the takeoff altitude. + Note that the vehicle must be armed before it can take off. */ +func (s *ServiceImpl) Takeoff( + ctx context.Context, -func (s *ServiceImpl) Takeoff(ctx context.Context) (*TakeoffResponse, error) { - +) (*TakeoffResponse, error) { request := &TakeoffRequest{} response, err := s.Client.Takeoff(ctx, request) if err != nil { @@ -89,15 +85,14 @@ func (s *ServiceImpl) Takeoff(ctx context.Context) (*TakeoffResponse, error) { } /* - Send command to land at the current position. - - This switches the drone to 'Land' flight mode. - +Land Send command to land at the current position. + This switches the drone to 'Land' flight mode. */ +func (s *ServiceImpl) Land( + ctx context.Context, -func (s *ServiceImpl) Land(ctx context.Context) (*LandResponse, error) { - +) (*LandResponse, error) { request := &LandRequest{} response, err := s.Client.Land(ctx, request) if err != nil { @@ -107,15 +102,14 @@ func (s *ServiceImpl) Land(ctx context.Context) (*LandResponse, error) { } /* - Send command to reboot the drone components. - - This will reboot the autopilot, companion computer, camera and gimbal. - +Reboot Send command to reboot the drone components. + This will reboot the autopilot, companion computer, camera and gimbal. */ +func (s *ServiceImpl) Reboot( + ctx context.Context, -func (s *ServiceImpl) Reboot(ctx context.Context) (*RebootResponse, error) { - +) (*RebootResponse, error) { request := &RebootRequest{} response, err := s.Client.Reboot(ctx, request) if err != nil { @@ -125,17 +119,16 @@ func (s *ServiceImpl) Reboot(ctx context.Context) (*RebootResponse, error) { } /* - Send command to shut down the drone components. - - This will shut down the autopilot, onboard computer, camera and gimbal. - This command should only be used when the autopilot is disarmed and autopilots commonly - reject it if they are not already ready to shut down. - +Shutdown Send command to shut down the drone components. + This will shut down the autopilot, onboard computer, camera and gimbal. + This command should only be used when the autopilot is disarmed and autopilots commonly + reject it if they are not already ready to shut down. */ +func (s *ServiceImpl) Shutdown( + ctx context.Context, -func (s *ServiceImpl) Shutdown(ctx context.Context) (*ShutdownResponse, error) { - +) (*ShutdownResponse, error) { request := &ShutdownRequest{} response, err := s.Client.Shutdown(ctx, request) if err != nil { @@ -145,15 +138,14 @@ func (s *ServiceImpl) Shutdown(ctx context.Context) (*ShutdownResponse, error) { } /* - Send command to terminate the drone. - - This will run the terminate routine as configured on the drone (e.g. disarm and open the parachute). - +Terminate Send command to terminate the drone. + This will run the terminate routine as configured on the drone (e.g. disarm and open the parachute). */ +func (s *ServiceImpl) Terminate( + ctx context.Context, -func (s *ServiceImpl) Terminate(ctx context.Context) (*TerminateResponse, error) { - +) (*TerminateResponse, error) { request := &TerminateRequest{} response, err := s.Client.Terminate(ctx, request) if err != nil { @@ -163,16 +155,15 @@ func (s *ServiceImpl) Terminate(ctx context.Context) (*TerminateResponse, error) } /* - Send command to kill the drone. - - This will disarm a drone irrespective of whether it is landed or flying. - Note that the drone will fall out of the sky if this command is used while flying. - +Kill Send command to kill the drone. + This will disarm a drone irrespective of whether it is landed or flying. + Note that the drone will fall out of the sky if this command is used while flying. */ +func (s *ServiceImpl) Kill( + ctx context.Context, -func (s *ServiceImpl) Kill(ctx context.Context) (*KillResponse, error) { - +) (*KillResponse, error) { request := &KillRequest{} response, err := s.Client.Kill(ctx, request) if err != nil { @@ -182,17 +173,16 @@ func (s *ServiceImpl) Kill(ctx context.Context) (*KillResponse, error) { } /* - Send command to return to the launch (takeoff) position and land. - - This switches the drone into [Return mode](https://docs.px4.io/master/en/flight_modes/return.html) which - generally means it will rise up to a certain altitude to clear any obstacles before heading - back to the launch (takeoff) position and land there. - +ReturnToLaunch Send command to return to the launch (takeoff) position and land. + This switches the drone into [Return mode](https://docs.px4.io/master/en/flight_modes/return.html) which + generally means it will rise up to a certain altitude to clear any obstacles before heading + back to the launch (takeoff) position and land there. */ +func (s *ServiceImpl) ReturnToLaunch( + ctx context.Context, -func (s *ServiceImpl) ReturnToLaunch(ctx context.Context) (*ReturnToLaunchResponse, error) { - +) (*ReturnToLaunchResponse, error) { request := &ReturnToLaunchRequest{} response, err := s.Client.ReturnToLaunch(ctx, request) if err != nil { @@ -202,33 +192,27 @@ func (s *ServiceImpl) ReturnToLaunch(ctx context.Context) (*ReturnToLaunchRespon } /* - Send command to move the vehicle to a specific global position. - - The latitude and longitude are given in degrees (WGS84 frame) and the altitude - in meters AMSL (above mean sea level). - - The yaw angle is in degrees (frame is NED, 0 is North, positive is clockwise). - - Parameters - ---------- - latitudeDeg float64 - - longitudeDeg float64 - - absoluteAltitudeM float32 - - yawDeg float32 +GotoLocation Send command to move the vehicle to a specific global position. + The latitude and longitude are given in degrees (WGS84 frame) and the altitude + in meters AMSL (above mean sea level). + The yaw angle is in degrees (frame is NED, 0 is North, positive is clockwise). */ - -func (s *ServiceImpl) GotoLocation(ctx context.Context, latitudeDeg float64, longitudeDeg float64, absoluteAltitudeM float32, yawDeg float32) (*GotoLocationResponse, error) { - - request := &GotoLocationRequest{} - request.LatitudeDeg = latitudeDeg - request.LongitudeDeg = longitudeDeg - request.AbsoluteAltitudeM = absoluteAltitudeM - request.YawDeg = yawDeg +func (s *ServiceImpl) GotoLocation( + ctx context.Context, + latitudeDeg float64, + longitudeDeg float64, + absoluteAltitudeM float32, + yawDeg float32, + +) (*GotoLocationResponse, error) { + request := &GotoLocationRequest{ + LatitudeDeg: latitudeDeg, + LongitudeDeg: longitudeDeg, + AbsoluteAltitudeM: absoluteAltitudeM, + YawDeg: yawDeg, + } response, err := s.Client.GotoLocation(ctx, request) if err != nil { return nil, err @@ -237,37 +221,29 @@ func (s *ServiceImpl) GotoLocation(ctx context.Context, latitudeDeg float64, lon } /* - Send command do orbit to the drone. - - This will run the orbit routine with the given parameters. - - Parameters - ---------- - radiusM float32 - - velocityMs float32 - - yawBehavior *OrbitYawBehavior - - - latitudeDeg float64 - - longitudeDeg float64 - - absoluteAltitudeM float64 - +DoOrbit Send command do orbit to the drone. + This will run the orbit routine with the given parameters. */ - -func (s *ServiceImpl) DoOrbit(ctx context.Context, radiusM float32, velocityMs float32, yawBehavior *OrbitYawBehavior, latitudeDeg float64, longitudeDeg float64, absoluteAltitudeM float64) (*DoOrbitResponse, error) { - - request := &DoOrbitRequest{} - request.RadiusM = radiusM - request.VelocityMs = velocityMs - request.YawBehavior = *yawBehavior - request.LatitudeDeg = latitudeDeg - request.LongitudeDeg = longitudeDeg - request.AbsoluteAltitudeM = absoluteAltitudeM +func (s *ServiceImpl) DoOrbit( + ctx context.Context, + radiusM float32, + velocityMs float32, + yawBehavior *OrbitYawBehavior, + + latitudeDeg float64, + longitudeDeg float64, + absoluteAltitudeM float64, + +) (*DoOrbitResponse, error) { + request := &DoOrbitRequest{ + RadiusM: radiusM, + VelocityMs: velocityMs, + YawBehavior: *yawBehavior, + LatitudeDeg: latitudeDeg, + LongitudeDeg: longitudeDeg, + AbsoluteAltitudeM: absoluteAltitudeM, + } response, err := s.Client.DoOrbit(ctx, request) if err != nil { return nil, err @@ -276,19 +252,18 @@ func (s *ServiceImpl) DoOrbit(ctx context.Context, radiusM float32, velocityMs f } /* - Send command to hold position (a.k.a. "Loiter"). - - Sends a command to drone to change to Hold flight mode, causing the - vehicle to stop and maintain its current GPS position and altitude. - - Note: this command is specific to the PX4 Autopilot flight stack as - it implies a change to a PX4-specific mode. +Hold Send command to hold position (a.k.a. "Loiter"). + Sends a command to drone to change to Hold flight mode, causing the + vehicle to stop and maintain its current GPS position and altitude. + Note: this command is specific to the PX4 Autopilot flight stack as + it implies a change to a PX4-specific mode. */ +func (s *ServiceImpl) Hold( + ctx context.Context, -func (s *ServiceImpl) Hold(ctx context.Context) (*HoldResponse, error) { - +) (*HoldResponse, error) { request := &HoldRequest{} response, err := s.Client.Hold(ctx, request) if err != nil { @@ -298,24 +273,20 @@ func (s *ServiceImpl) Hold(ctx context.Context) (*HoldResponse, error) { } /* - Send command to set the value of an actuator. - - Note that the index of the actuator starts at 1 and that the value goes from -1 to 1. - - Parameters - ---------- - index int32 - - value float32 - +SetActuator Send command to set the value of an actuator. + Note that the index of the actuator starts at 1 and that the value goes from -1 to 1. */ - -func (s *ServiceImpl) SetActuator(ctx context.Context, index int32, value float32) (*SetActuatorResponse, error) { - - request := &SetActuatorRequest{} - request.Index = index - request.Value = value +func (s *ServiceImpl) SetActuator( + ctx context.Context, + index int32, + value float32, + +) (*SetActuatorResponse, error) { + request := &SetActuatorRequest{ + Index: index, + Value: value, + } response, err := s.Client.SetActuator(ctx, request) if err != nil { return nil, err @@ -324,17 +295,16 @@ func (s *ServiceImpl) SetActuator(ctx context.Context, index int32, value float3 } /* - Send command to transition the drone to fixedwing. - - The associated action will only be executed for VTOL vehicles (on other vehicle types the - command will fail). The command will succeed if called when the vehicle - is already in fixedwing mode. - +TransitionToFixedwing Send command to transition the drone to fixedwing. + The associated action will only be executed for VTOL vehicles (on other vehicle types the + command will fail). The command will succeed if called when the vehicle + is already in fixedwing mode. */ +func (s *ServiceImpl) TransitionToFixedwing( + ctx context.Context, -func (s *ServiceImpl) TransitionToFixedwing(ctx context.Context) (*TransitionToFixedwingResponse, error) { - +) (*TransitionToFixedwingResponse, error) { request := &TransitionToFixedwingRequest{} response, err := s.Client.TransitionToFixedwing(ctx, request) if err != nil { @@ -344,17 +314,16 @@ func (s *ServiceImpl) TransitionToFixedwing(ctx context.Context) (*TransitionToF } /* - Send command to transition the drone to multicopter. - - The associated action will only be executed for VTOL vehicles (on other vehicle types the - command will fail). The command will succeed if called when the vehicle - is already in multicopter mode. - +TransitionToMulticopter Send command to transition the drone to multicopter. + The associated action will only be executed for VTOL vehicles (on other vehicle types the + command will fail). The command will succeed if called when the vehicle + is already in multicopter mode. */ +func (s *ServiceImpl) TransitionToMulticopter( + ctx context.Context, -func (s *ServiceImpl) TransitionToMulticopter(ctx context.Context) (*TransitionToMulticopterResponse, error) { - +) (*TransitionToMulticopterResponse, error) { request := &TransitionToMulticopterRequest{} response, err := s.Client.TransitionToMulticopter(ctx, request) if err != nil { @@ -364,43 +333,31 @@ func (s *ServiceImpl) TransitionToMulticopter(ctx context.Context) (*TransitionT } /* - Get the takeoff altitude (in meters above ground). - - - - Returns - ------- - False - Altitude : float32 - Takeoff altitude relative to ground/takeoff location (in meters) - - +GetTakeoffAltitude Get the takeoff altitude (in meters above ground). */ +func (s *ServiceImpl) GetTakeoffAltitude( + ctx context.Context, -func (s *ServiceImpl) GetTakeoffAltitude(ctx context.Context) (*GetTakeoffAltitudeResponse, error) { +) (*GetTakeoffAltitudeResponse, error) { request := &GetTakeoffAltitudeRequest{} response, err := s.Client.GetTakeoffAltitude(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set takeoff altitude (in meters above ground). - - Parameters - ---------- - altitude float32 - - +SetTakeoffAltitude Set takeoff altitude (in meters above ground). */ +func (s *ServiceImpl) SetTakeoffAltitude( + ctx context.Context, + altitude float32, -func (s *ServiceImpl) SetTakeoffAltitude(ctx context.Context, altitude float32) (*SetTakeoffAltitudeResponse, error) { - - request := &SetTakeoffAltitudeRequest{} - request.Altitude = altitude +) (*SetTakeoffAltitudeResponse, error) { + request := &SetTakeoffAltitudeRequest{ + Altitude: altitude, + } response, err := s.Client.SetTakeoffAltitude(ctx, request) if err != nil { return nil, err @@ -409,43 +366,31 @@ func (s *ServiceImpl) SetTakeoffAltitude(ctx context.Context, altitude float32) } /* - Get the vehicle maximum speed (in metres/second). - - - - Returns - ------- - False - Speed : float32 - Maximum speed (in metres/second) - - +GetMaximumSpeed Get the vehicle maximum speed (in metres/second). */ +func (s *ServiceImpl) GetMaximumSpeed( + ctx context.Context, -func (s *ServiceImpl) GetMaximumSpeed(ctx context.Context) (*GetMaximumSpeedResponse, error) { +) (*GetMaximumSpeedResponse, error) { request := &GetMaximumSpeedRequest{} response, err := s.Client.GetMaximumSpeed(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set vehicle maximum speed (in metres/second). - - Parameters - ---------- - speed float32 - - +SetMaximumSpeed Set vehicle maximum speed (in metres/second). */ +func (s *ServiceImpl) SetMaximumSpeed( + ctx context.Context, + speed float32, -func (s *ServiceImpl) SetMaximumSpeed(ctx context.Context, speed float32) (*SetMaximumSpeedResponse, error) { - - request := &SetMaximumSpeedRequest{} - request.Speed = speed +) (*SetMaximumSpeedResponse, error) { + request := &SetMaximumSpeedRequest{ + Speed: speed, + } response, err := s.Client.SetMaximumSpeed(ctx, request) if err != nil { return nil, err @@ -454,43 +399,31 @@ func (s *ServiceImpl) SetMaximumSpeed(ctx context.Context, speed float32) (*SetM } /* - Get the return to launch minimum return altitude (in meters). - - - - Returns - ------- - False - RelativeAltitudeM : float32 - Return altitude relative to takeoff location (in meters) - - +GetReturnToLaunchAltitude Get the return to launch minimum return altitude (in meters). */ +func (s *ServiceImpl) GetReturnToLaunchAltitude( + ctx context.Context, -func (s *ServiceImpl) GetReturnToLaunchAltitude(ctx context.Context) (*GetReturnToLaunchAltitudeResponse, error) { +) (*GetReturnToLaunchAltitudeResponse, error) { request := &GetReturnToLaunchAltitudeRequest{} response, err := s.Client.GetReturnToLaunchAltitude(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set the return to launch minimum return altitude (in meters). - - Parameters - ---------- - relativeAltitudeM float32 - - +SetReturnToLaunchAltitude Set the return to launch minimum return altitude (in meters). */ +func (s *ServiceImpl) SetReturnToLaunchAltitude( + ctx context.Context, + relativeAltitudeM float32, -func (s *ServiceImpl) SetReturnToLaunchAltitude(ctx context.Context, relativeAltitudeM float32) (*SetReturnToLaunchAltitudeResponse, error) { - - request := &SetReturnToLaunchAltitudeRequest{} - request.RelativeAltitudeM = relativeAltitudeM +) (*SetReturnToLaunchAltitudeResponse, error) { + request := &SetReturnToLaunchAltitudeRequest{ + RelativeAltitudeM: relativeAltitudeM, + } response, err := s.Client.SetReturnToLaunchAltitude(ctx, request) if err != nil { return nil, err @@ -499,22 +432,19 @@ func (s *ServiceImpl) SetReturnToLaunchAltitude(ctx context.Context, relativeAlt } /* - Set current speed. - - This will set the speed during a mission, reposition, and similar. - It is ephemeral, so not stored on the drone and does not survive a reboot. - - Parameters - ---------- - speedMS float32 - +SetCurrentSpeed Set current speed. + This will set the speed during a mission, reposition, and similar. + It is ephemeral, so not stored on the drone and does not survive a reboot. */ +func (s *ServiceImpl) SetCurrentSpeed( + ctx context.Context, + speedMS float32, -func (s *ServiceImpl) SetCurrentSpeed(ctx context.Context, speedMS float32) (*SetCurrentSpeedResponse, error) { - - request := &SetCurrentSpeedRequest{} - request.SpeedMS = speedMS +) (*SetCurrentSpeedResponse, error) { + request := &SetCurrentSpeedRequest{ + SpeedMS: speedMS, + } response, err := s.Client.SetCurrentSpeed(ctx, request) if err != nil { return nil, err diff --git a/Sources/action/action.pb.go b/Sources/action/action.pb.go index 22b1aca..8b4ba27 100644 --- a/Sources/action/action.pb.go +++ b/Sources/action/action.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: action.proto package action import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -170,11 +171,9 @@ type ArmRequest struct { func (x *ArmRequest) Reset() { *x = ArmRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmRequest) String() string { @@ -185,7 +184,7 @@ func (*ArmRequest) ProtoMessage() {} func (x *ArmRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -210,11 +209,9 @@ type ArmResponse struct { func (x *ArmResponse) Reset() { *x = ArmResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmResponse) String() string { @@ -225,7 +222,7 @@ func (*ArmResponse) ProtoMessage() {} func (x *ArmResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -255,11 +252,9 @@ type ArmForceRequest struct { func (x *ArmForceRequest) Reset() { *x = ArmForceRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmForceRequest) String() string { @@ -270,7 +265,7 @@ func (*ArmForceRequest) ProtoMessage() {} func (x *ArmForceRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -295,11 +290,9 @@ type ArmForceResponse struct { func (x *ArmForceResponse) Reset() { *x = ArmForceResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmForceResponse) String() string { @@ -310,7 +303,7 @@ func (*ArmForceResponse) ProtoMessage() {} func (x *ArmForceResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -340,11 +333,9 @@ type DisarmRequest struct { func (x *DisarmRequest) Reset() { *x = DisarmRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DisarmRequest) String() string { @@ -355,7 +346,7 @@ func (*DisarmRequest) ProtoMessage() {} func (x *DisarmRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -380,11 +371,9 @@ type DisarmResponse struct { func (x *DisarmResponse) Reset() { *x = DisarmResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DisarmResponse) String() string { @@ -395,7 +384,7 @@ func (*DisarmResponse) ProtoMessage() {} func (x *DisarmResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -425,11 +414,9 @@ type TakeoffRequest struct { func (x *TakeoffRequest) Reset() { *x = TakeoffRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakeoffRequest) String() string { @@ -440,7 +427,7 @@ func (*TakeoffRequest) ProtoMessage() {} func (x *TakeoffRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -465,11 +452,9 @@ type TakeoffResponse struct { func (x *TakeoffResponse) Reset() { *x = TakeoffResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakeoffResponse) String() string { @@ -480,7 +465,7 @@ func (*TakeoffResponse) ProtoMessage() {} func (x *TakeoffResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -510,11 +495,9 @@ type LandRequest struct { func (x *LandRequest) Reset() { *x = LandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LandRequest) String() string { @@ -525,7 +508,7 @@ func (*LandRequest) ProtoMessage() {} func (x *LandRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -550,11 +533,9 @@ type LandResponse struct { func (x *LandResponse) Reset() { *x = LandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LandResponse) String() string { @@ -565,7 +546,7 @@ func (*LandResponse) ProtoMessage() {} func (x *LandResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -595,11 +576,9 @@ type RebootRequest struct { func (x *RebootRequest) Reset() { *x = RebootRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RebootRequest) String() string { @@ -610,7 +589,7 @@ func (*RebootRequest) ProtoMessage() {} func (x *RebootRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -635,11 +614,9 @@ type RebootResponse struct { func (x *RebootResponse) Reset() { *x = RebootResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RebootResponse) String() string { @@ -650,7 +627,7 @@ func (*RebootResponse) ProtoMessage() {} func (x *RebootResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -680,11 +657,9 @@ type ShutdownRequest struct { func (x *ShutdownRequest) Reset() { *x = ShutdownRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ShutdownRequest) String() string { @@ -695,7 +670,7 @@ func (*ShutdownRequest) ProtoMessage() {} func (x *ShutdownRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -720,11 +695,9 @@ type ShutdownResponse struct { func (x *ShutdownResponse) Reset() { *x = ShutdownResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ShutdownResponse) String() string { @@ -735,7 +708,7 @@ func (*ShutdownResponse) ProtoMessage() {} func (x *ShutdownResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -765,11 +738,9 @@ type TerminateRequest struct { func (x *TerminateRequest) Reset() { *x = TerminateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TerminateRequest) String() string { @@ -780,7 +751,7 @@ func (*TerminateRequest) ProtoMessage() {} func (x *TerminateRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -805,11 +776,9 @@ type TerminateResponse struct { func (x *TerminateResponse) Reset() { *x = TerminateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TerminateResponse) String() string { @@ -820,7 +789,7 @@ func (*TerminateResponse) ProtoMessage() {} func (x *TerminateResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -850,11 +819,9 @@ type KillRequest struct { func (x *KillRequest) Reset() { *x = KillRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *KillRequest) String() string { @@ -865,7 +832,7 @@ func (*KillRequest) ProtoMessage() {} func (x *KillRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -890,11 +857,9 @@ type KillResponse struct { func (x *KillResponse) Reset() { *x = KillResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *KillResponse) String() string { @@ -905,7 +870,7 @@ func (*KillResponse) ProtoMessage() {} func (x *KillResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -935,11 +900,9 @@ type ReturnToLaunchRequest struct { func (x *ReturnToLaunchRequest) Reset() { *x = ReturnToLaunchRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReturnToLaunchRequest) String() string { @@ -950,7 +913,7 @@ func (*ReturnToLaunchRequest) ProtoMessage() {} func (x *ReturnToLaunchRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -975,11 +938,9 @@ type ReturnToLaunchResponse struct { func (x *ReturnToLaunchResponse) Reset() { *x = ReturnToLaunchResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReturnToLaunchResponse) String() string { @@ -990,7 +951,7 @@ func (*ReturnToLaunchResponse) ProtoMessage() {} func (x *ReturnToLaunchResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1025,11 +986,9 @@ type GotoLocationRequest struct { func (x *GotoLocationRequest) Reset() { *x = GotoLocationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GotoLocationRequest) String() string { @@ -1040,7 +999,7 @@ func (*GotoLocationRequest) ProtoMessage() {} func (x *GotoLocationRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1093,11 +1052,9 @@ type GotoLocationResponse struct { func (x *GotoLocationResponse) Reset() { *x = GotoLocationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GotoLocationResponse) String() string { @@ -1108,7 +1065,7 @@ func (*GotoLocationResponse) ProtoMessage() {} func (x *GotoLocationResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1145,11 +1102,9 @@ type DoOrbitRequest struct { func (x *DoOrbitRequest) Reset() { *x = DoOrbitRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DoOrbitRequest) String() string { @@ -1160,7 +1115,7 @@ func (*DoOrbitRequest) ProtoMessage() {} func (x *DoOrbitRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1227,11 +1182,9 @@ type DoOrbitResponse struct { func (x *DoOrbitResponse) Reset() { *x = DoOrbitResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DoOrbitResponse) String() string { @@ -1242,7 +1195,7 @@ func (*DoOrbitResponse) ProtoMessage() {} func (x *DoOrbitResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1272,11 +1225,9 @@ type HoldRequest struct { func (x *HoldRequest) Reset() { *x = HoldRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HoldRequest) String() string { @@ -1287,7 +1238,7 @@ func (*HoldRequest) ProtoMessage() {} func (x *HoldRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1312,11 +1263,9 @@ type HoldResponse struct { func (x *HoldResponse) Reset() { *x = HoldResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HoldResponse) String() string { @@ -1327,7 +1276,7 @@ func (*HoldResponse) ProtoMessage() {} func (x *HoldResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1360,11 +1309,9 @@ type SetActuatorRequest struct { func (x *SetActuatorRequest) Reset() { *x = SetActuatorRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetActuatorRequest) String() string { @@ -1375,7 +1322,7 @@ func (*SetActuatorRequest) ProtoMessage() {} func (x *SetActuatorRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1414,11 +1361,9 @@ type SetActuatorResponse struct { func (x *SetActuatorResponse) Reset() { *x = SetActuatorResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetActuatorResponse) String() string { @@ -1429,7 +1374,7 @@ func (*SetActuatorResponse) ProtoMessage() {} func (x *SetActuatorResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1459,11 +1404,9 @@ type TransitionToFixedwingRequest struct { func (x *TransitionToFixedwingRequest) Reset() { *x = TransitionToFixedwingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TransitionToFixedwingRequest) String() string { @@ -1474,7 +1417,7 @@ func (*TransitionToFixedwingRequest) ProtoMessage() {} func (x *TransitionToFixedwingRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1499,11 +1442,9 @@ type TransitionToFixedwingResponse struct { func (x *TransitionToFixedwingResponse) Reset() { *x = TransitionToFixedwingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TransitionToFixedwingResponse) String() string { @@ -1514,7 +1455,7 @@ func (*TransitionToFixedwingResponse) ProtoMessage() {} func (x *TransitionToFixedwingResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1544,11 +1485,9 @@ type TransitionToMulticopterRequest struct { func (x *TransitionToMulticopterRequest) Reset() { *x = TransitionToMulticopterRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TransitionToMulticopterRequest) String() string { @@ -1559,7 +1498,7 @@ func (*TransitionToMulticopterRequest) ProtoMessage() {} func (x *TransitionToMulticopterRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1584,11 +1523,9 @@ type TransitionToMulticopterResponse struct { func (x *TransitionToMulticopterResponse) Reset() { *x = TransitionToMulticopterResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TransitionToMulticopterResponse) String() string { @@ -1599,7 +1536,7 @@ func (*TransitionToMulticopterResponse) ProtoMessage() {} func (x *TransitionToMulticopterResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1629,11 +1566,9 @@ type GetTakeoffAltitudeRequest struct { func (x *GetTakeoffAltitudeRequest) Reset() { *x = GetTakeoffAltitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetTakeoffAltitudeRequest) String() string { @@ -1644,7 +1579,7 @@ func (*GetTakeoffAltitudeRequest) ProtoMessage() {} func (x *GetTakeoffAltitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1670,11 +1605,9 @@ type GetTakeoffAltitudeResponse struct { func (x *GetTakeoffAltitudeResponse) Reset() { *x = GetTakeoffAltitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetTakeoffAltitudeResponse) String() string { @@ -1685,7 +1618,7 @@ func (*GetTakeoffAltitudeResponse) ProtoMessage() {} func (x *GetTakeoffAltitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1724,11 +1657,9 @@ type SetTakeoffAltitudeRequest struct { func (x *SetTakeoffAltitudeRequest) Reset() { *x = SetTakeoffAltitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[34] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTakeoffAltitudeRequest) String() string { @@ -1739,7 +1670,7 @@ func (*SetTakeoffAltitudeRequest) ProtoMessage() {} func (x *SetTakeoffAltitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[34] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1771,11 +1702,9 @@ type SetTakeoffAltitudeResponse struct { func (x *SetTakeoffAltitudeResponse) Reset() { *x = SetTakeoffAltitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTakeoffAltitudeResponse) String() string { @@ -1786,7 +1715,7 @@ func (*SetTakeoffAltitudeResponse) ProtoMessage() {} func (x *SetTakeoffAltitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[35] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1816,11 +1745,9 @@ type GetMaximumSpeedRequest struct { func (x *GetMaximumSpeedRequest) Reset() { *x = GetMaximumSpeedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[36] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetMaximumSpeedRequest) String() string { @@ -1831,7 +1758,7 @@ func (*GetMaximumSpeedRequest) ProtoMessage() {} func (x *GetMaximumSpeedRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[36] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1857,11 +1784,9 @@ type GetMaximumSpeedResponse struct { func (x *GetMaximumSpeedResponse) Reset() { *x = GetMaximumSpeedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[37] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetMaximumSpeedResponse) String() string { @@ -1872,7 +1797,7 @@ func (*GetMaximumSpeedResponse) ProtoMessage() {} func (x *GetMaximumSpeedResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[37] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1911,11 +1836,9 @@ type SetMaximumSpeedRequest struct { func (x *SetMaximumSpeedRequest) Reset() { *x = SetMaximumSpeedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[38] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetMaximumSpeedRequest) String() string { @@ -1926,7 +1849,7 @@ func (*SetMaximumSpeedRequest) ProtoMessage() {} func (x *SetMaximumSpeedRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[38] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1958,11 +1881,9 @@ type SetMaximumSpeedResponse struct { func (x *SetMaximumSpeedResponse) Reset() { *x = SetMaximumSpeedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[39] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetMaximumSpeedResponse) String() string { @@ -1973,7 +1894,7 @@ func (*SetMaximumSpeedResponse) ProtoMessage() {} func (x *SetMaximumSpeedResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[39] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2003,11 +1924,9 @@ type GetReturnToLaunchAltitudeRequest struct { func (x *GetReturnToLaunchAltitudeRequest) Reset() { *x = GetReturnToLaunchAltitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[40] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetReturnToLaunchAltitudeRequest) String() string { @@ -2018,7 +1937,7 @@ func (*GetReturnToLaunchAltitudeRequest) ProtoMessage() {} func (x *GetReturnToLaunchAltitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[40] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2044,11 +1963,9 @@ type GetReturnToLaunchAltitudeResponse struct { func (x *GetReturnToLaunchAltitudeResponse) Reset() { *x = GetReturnToLaunchAltitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[41] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetReturnToLaunchAltitudeResponse) String() string { @@ -2059,7 +1976,7 @@ func (*GetReturnToLaunchAltitudeResponse) ProtoMessage() {} func (x *GetReturnToLaunchAltitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[41] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2098,11 +2015,9 @@ type SetReturnToLaunchAltitudeRequest struct { func (x *SetReturnToLaunchAltitudeRequest) Reset() { *x = SetReturnToLaunchAltitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[42] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetReturnToLaunchAltitudeRequest) String() string { @@ -2113,7 +2028,7 @@ func (*SetReturnToLaunchAltitudeRequest) ProtoMessage() {} func (x *SetReturnToLaunchAltitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[42] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2145,11 +2060,9 @@ type SetReturnToLaunchAltitudeResponse struct { func (x *SetReturnToLaunchAltitudeResponse) Reset() { *x = SetReturnToLaunchAltitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[43] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetReturnToLaunchAltitudeResponse) String() string { @@ -2160,7 +2073,7 @@ func (*SetReturnToLaunchAltitudeResponse) ProtoMessage() {} func (x *SetReturnToLaunchAltitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[43] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2192,11 +2105,9 @@ type SetCurrentSpeedRequest struct { func (x *SetCurrentSpeedRequest) Reset() { *x = SetCurrentSpeedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[44] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentSpeedRequest) String() string { @@ -2207,7 +2118,7 @@ func (*SetCurrentSpeedRequest) ProtoMessage() {} func (x *SetCurrentSpeedRequest) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[44] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2239,11 +2150,9 @@ type SetCurrentSpeedResponse struct { func (x *SetCurrentSpeedResponse) Reset() { *x = SetCurrentSpeedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[45] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[45] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentSpeedResponse) String() string { @@ -2254,7 +2163,7 @@ func (*SetCurrentSpeedResponse) ProtoMessage() {} func (x *SetCurrentSpeedResponse) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[45] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2288,11 +2197,9 @@ type ActionResult struct { func (x *ActionResult) Reset() { *x = ActionResult{} - if protoimpl.UnsafeEnabled { - mi := &file_action_proto_msgTypes[46] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_proto_msgTypes[46] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActionResult) String() string { @@ -2303,7 +2210,7 @@ func (*ActionResult) ProtoMessage() {} func (x *ActionResult) ProtoReflect() protoreflect.Message { mi := &file_action_proto_msgTypes[46] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2897,573 +2804,6 @@ func file_action_proto_init() { if File_action_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_action_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*ArmRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*ArmResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*ArmForceRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*ArmForceResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*DisarmRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*DisarmResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*TakeoffRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*TakeoffResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*LandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*LandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*RebootRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*RebootResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*ShutdownRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*ShutdownResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*TerminateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*TerminateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*KillRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*KillResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*ReturnToLaunchRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*ReturnToLaunchResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*GotoLocationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*GotoLocationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*DoOrbitRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*DoOrbitResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*HoldRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*HoldResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*SetActuatorRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*SetActuatorResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*TransitionToFixedwingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*TransitionToFixedwingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*TransitionToMulticopterRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*TransitionToMulticopterResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*GetTakeoffAltitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*GetTakeoffAltitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[34].Exporter = func(v any, i int) any { - switch v := v.(*SetTakeoffAltitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[35].Exporter = func(v any, i int) any { - switch v := v.(*SetTakeoffAltitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[36].Exporter = func(v any, i int) any { - switch v := v.(*GetMaximumSpeedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[37].Exporter = func(v any, i int) any { - switch v := v.(*GetMaximumSpeedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[38].Exporter = func(v any, i int) any { - switch v := v.(*SetMaximumSpeedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[39].Exporter = func(v any, i int) any { - switch v := v.(*SetMaximumSpeedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[40].Exporter = func(v any, i int) any { - switch v := v.(*GetReturnToLaunchAltitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[41].Exporter = func(v any, i int) any { - switch v := v.(*GetReturnToLaunchAltitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[42].Exporter = func(v any, i int) any { - switch v := v.(*SetReturnToLaunchAltitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[43].Exporter = func(v any, i int) any { - switch v := v.(*SetReturnToLaunchAltitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[44].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentSpeedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[45].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentSpeedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_proto_msgTypes[46].Exporter = func(v any, i int) any { - switch v := v.(*ActionResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/action/action_grpc.pb.go b/Sources/action/action_grpc.pb.go index bd69661..8ea735e 100644 --- a/Sources/action/action_grpc.pb.go +++ b/Sources/action/action_grpc.pb.go @@ -8,6 +8,7 @@ package action import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/action_server/action_server.go b/Sources/action_server/action_server.go index f360494..e0d0b72 100644 --- a/Sources/action_server/action_server.go +++ b/Sources/action_server/action_server.go @@ -2,11 +2,11 @@ package action_server import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to ARM/DISARM commands - - +ArmDisarm Subscribe to ARM/DISARM commands */ +func (a *ServiceImpl) ArmDisarm( + ctx context.Context, -func (a *ServiceImpl) ArmDisarm(ctx context.Context) (<-chan *ArmDisarm, error) { +) (<-chan *ArmDisarm, error) { ch := make(chan *ArmDisarm) request := &SubscribeArmDisarmRequest{} stream, err := a.Client.SubscribeArmDisarm(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) ArmDisarm(ctx context.Context) (<-chan *ArmDisarm, error) if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ArmDisarm messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ArmDisarm messages, err: %v", err) } ch <- m.GetArm() } @@ -48,12 +47,12 @@ func (a *ServiceImpl) ArmDisarm(ctx context.Context) (<-chan *ArmDisarm, error) } /* - Subscribe to DO_SET_MODE - - +FlightModeChange Subscribe to DO_SET_MODE */ +func (a *ServiceImpl) FlightModeChange( + ctx context.Context, -func (a *ServiceImpl) FlightModeChange(ctx context.Context) (<-chan FlightMode, error) { +) (<-chan FlightMode, error) { ch := make(chan FlightMode) request := &SubscribeFlightModeChangeRequest{} stream, err := a.Client.SubscribeFlightModeChange(ctx, request) @@ -72,8 +71,7 @@ func (a *ServiceImpl) FlightModeChange(ctx context.Context) (<-chan FlightMode, if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive FlightModeChange messages, err: %v\n", err) - break + log.Fatalf("Unable to receive FlightModeChange messages, err: %v", err) } ch <- m.GetFlightMode() } @@ -82,12 +80,12 @@ func (a *ServiceImpl) FlightModeChange(ctx context.Context) (<-chan FlightMode, } /* - Subscribe to takeoff command - - +Takeoff Subscribe to takeoff command */ +func (a *ServiceImpl) Takeoff( + ctx context.Context, -func (a *ServiceImpl) Takeoff(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeTakeoffRequest{} stream, err := a.Client.SubscribeTakeoff(ctx, request) @@ -106,8 +104,7 @@ func (a *ServiceImpl) Takeoff(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Takeoff messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Takeoff messages, err: %v", err) } ch <- m.GetTakeoff() } @@ -116,12 +113,12 @@ func (a *ServiceImpl) Takeoff(ctx context.Context) (<-chan bool, error) { } /* - Subscribe to land command - - +Land Subscribe to land command */ +func (a *ServiceImpl) Land( + ctx context.Context, -func (a *ServiceImpl) Land(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeLandRequest{} stream, err := a.Client.SubscribeLand(ctx, request) @@ -140,8 +137,7 @@ func (a *ServiceImpl) Land(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Land messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Land messages, err: %v", err) } ch <- m.GetLand() } @@ -150,12 +146,12 @@ func (a *ServiceImpl) Land(ctx context.Context) (<-chan bool, error) { } /* - Subscribe to reboot command - - +Reboot Subscribe to reboot command */ +func (a *ServiceImpl) Reboot( + ctx context.Context, -func (a *ServiceImpl) Reboot(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeRebootRequest{} stream, err := a.Client.SubscribeReboot(ctx, request) @@ -174,8 +170,7 @@ func (a *ServiceImpl) Reboot(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Reboot messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Reboot messages, err: %v", err) } ch <- m.GetReboot() } @@ -184,12 +179,12 @@ func (a *ServiceImpl) Reboot(ctx context.Context) (<-chan bool, error) { } /* - Subscribe to shutdown command - - +Shutdown Subscribe to shutdown command */ +func (a *ServiceImpl) Shutdown( + ctx context.Context, -func (a *ServiceImpl) Shutdown(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeShutdownRequest{} stream, err := a.Client.SubscribeShutdown(ctx, request) @@ -208,8 +203,7 @@ func (a *ServiceImpl) Shutdown(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Shutdown messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Shutdown messages, err: %v", err) } ch <- m.GetShutdown() } @@ -218,12 +212,12 @@ func (a *ServiceImpl) Shutdown(ctx context.Context) (<-chan bool, error) { } /* - Subscribe to terminate command - - +Terminate Subscribe to terminate command */ +func (a *ServiceImpl) Terminate( + ctx context.Context, -func (a *ServiceImpl) Terminate(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeTerminateRequest{} stream, err := a.Client.SubscribeTerminate(ctx, request) @@ -242,8 +236,7 @@ func (a *ServiceImpl) Terminate(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Terminate messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Terminate messages, err: %v", err) } ch <- m.GetTerminate() } @@ -252,19 +245,16 @@ func (a *ServiceImpl) Terminate(ctx context.Context) (<-chan bool, error) { } /* - Can the vehicle takeoff - - Parameters - ---------- - allowTakeoff bool - - +SetAllowTakeoff Can the vehicle takeoff */ +func (s *ServiceImpl) SetAllowTakeoff( + ctx context.Context, + allowTakeoff bool, -func (s *ServiceImpl) SetAllowTakeoff(ctx context.Context, allowTakeoff bool) (*SetAllowTakeoffResponse, error) { - - request := &SetAllowTakeoffRequest{} - request.AllowTakeoff = allowTakeoff +) (*SetAllowTakeoffResponse, error) { + request := &SetAllowTakeoffRequest{ + AllowTakeoff: allowTakeoff, + } response, err := s.Client.SetAllowTakeoff(ctx, request) if err != nil { return nil, err @@ -273,22 +263,18 @@ func (s *ServiceImpl) SetAllowTakeoff(ctx context.Context, allowTakeoff bool) (* } /* - Can the vehicle arm when requested - - Parameters - ---------- - armable bool - - forceArmable bool - - +SetArmable Can the vehicle arm when requested */ - -func (s *ServiceImpl) SetArmable(ctx context.Context, armable bool, forceArmable bool) (*SetArmableResponse, error) { - - request := &SetArmableRequest{} - request.Armable = armable - request.ForceArmable = forceArmable +func (s *ServiceImpl) SetArmable( + ctx context.Context, + armable bool, + forceArmable bool, + +) (*SetArmableResponse, error) { + request := &SetArmableRequest{ + Armable: armable, + ForceArmable: forceArmable, + } response, err := s.Client.SetArmable(ctx, request) if err != nil { return nil, err @@ -297,22 +283,18 @@ func (s *ServiceImpl) SetArmable(ctx context.Context, armable bool, forceArmable } /* - Can the vehicle disarm when requested - - Parameters - ---------- - disarmable bool - - forceDisarmable bool - - +SetDisarmable Can the vehicle disarm when requested */ - -func (s *ServiceImpl) SetDisarmable(ctx context.Context, disarmable bool, forceDisarmable bool) (*SetDisarmableResponse, error) { - - request := &SetDisarmableRequest{} - request.Disarmable = disarmable - request.ForceDisarmable = forceDisarmable +func (s *ServiceImpl) SetDisarmable( + ctx context.Context, + disarmable bool, + forceDisarmable bool, + +) (*SetDisarmableResponse, error) { + request := &SetDisarmableRequest{ + Disarmable: disarmable, + ForceDisarmable: forceDisarmable, + } response, err := s.Client.SetDisarmable(ctx, request) if err != nil { return nil, err @@ -321,21 +303,16 @@ func (s *ServiceImpl) SetDisarmable(ctx context.Context, disarmable bool, forceD } /* - Set which modes the vehicle can transition to (Manual always allowed) - - Parameters - ---------- - flightModes *AllowableFlightModes - - - +SetAllowableFlightModes Set which modes the vehicle can transition to (Manual always allowed) */ +func (s *ServiceImpl) SetAllowableFlightModes( + ctx context.Context, + flightModes *AllowableFlightModes, -func (s *ServiceImpl) SetAllowableFlightModes(ctx context.Context, flightModes *AllowableFlightModes) (*SetAllowableFlightModesResponse, error) { - - request := &SetAllowableFlightModesRequest{} - request.FlightModes = flightModes - +) (*SetAllowableFlightModesResponse, error) { + request := &SetAllowableFlightModesRequest{ + FlightModes: flightModes, + } response, err := s.Client.SetAllowableFlightModes(ctx, request) if err != nil { return nil, err @@ -344,24 +321,16 @@ func (s *ServiceImpl) SetAllowableFlightModes(ctx context.Context, flightModes * } /* - Get which modes the vehicle can transition to (Manual always allowed) - - - - Returns - ------- - False - FlightModes : AllowableFlightModes - - +GetAllowableFlightModes Get which modes the vehicle can transition to (Manual always allowed) */ +func (s *ServiceImpl) GetAllowableFlightModes( + ctx context.Context, -func (s *ServiceImpl) GetAllowableFlightModes(ctx context.Context) (*GetAllowableFlightModesResponse, error) { +) (*GetAllowableFlightModesResponse, error) { request := &GetAllowableFlightModesRequest{} response, err := s.Client.GetAllowableFlightModes(ctx, request) if err != nil { return nil, err } return response, nil - } diff --git a/Sources/action_server/action_server.pb.go b/Sources/action_server/action_server.pb.go index 23db974..8ea3ae4 100644 --- a/Sources/action_server/action_server.pb.go +++ b/Sources/action_server/action_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: action_server.proto package action_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -196,11 +197,9 @@ type SetAllowTakeoffRequest struct { func (x *SetAllowTakeoffRequest) Reset() { *x = SetAllowTakeoffRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAllowTakeoffRequest) String() string { @@ -211,7 +210,7 @@ func (*SetAllowTakeoffRequest) ProtoMessage() {} func (x *SetAllowTakeoffRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -244,11 +243,9 @@ type SetArmableRequest struct { func (x *SetArmableRequest) Reset() { *x = SetArmableRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetArmableRequest) String() string { @@ -259,7 +256,7 @@ func (*SetArmableRequest) ProtoMessage() {} func (x *SetArmableRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -299,11 +296,9 @@ type SetDisarmableRequest struct { func (x *SetDisarmableRequest) Reset() { *x = SetDisarmableRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetDisarmableRequest) String() string { @@ -314,7 +309,7 @@ func (*SetDisarmableRequest) ProtoMessage() {} func (x *SetDisarmableRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -353,11 +348,9 @@ type SetAllowableFlightModesRequest struct { func (x *SetAllowableFlightModesRequest) Reset() { *x = SetAllowableFlightModesRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAllowableFlightModesRequest) String() string { @@ -368,7 +361,7 @@ func (*SetAllowableFlightModesRequest) ProtoMessage() {} func (x *SetAllowableFlightModesRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -398,11 +391,9 @@ type GetAllowableFlightModesRequest struct { func (x *GetAllowableFlightModesRequest) Reset() { *x = GetAllowableFlightModesRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetAllowableFlightModesRequest) String() string { @@ -413,7 +404,7 @@ func (*GetAllowableFlightModesRequest) ProtoMessage() {} func (x *GetAllowableFlightModesRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -436,11 +427,9 @@ type SubscribeArmDisarmRequest struct { func (x *SubscribeArmDisarmRequest) Reset() { *x = SubscribeArmDisarmRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeArmDisarmRequest) String() string { @@ -451,7 +440,7 @@ func (*SubscribeArmDisarmRequest) ProtoMessage() {} func (x *SubscribeArmDisarmRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -474,11 +463,9 @@ type SubscribeFlightModeChangeRequest struct { func (x *SubscribeFlightModeChangeRequest) Reset() { *x = SubscribeFlightModeChangeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeFlightModeChangeRequest) String() string { @@ -489,7 +476,7 @@ func (*SubscribeFlightModeChangeRequest) ProtoMessage() {} func (x *SubscribeFlightModeChangeRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -512,11 +499,9 @@ type SubscribeTakeoffRequest struct { func (x *SubscribeTakeoffRequest) Reset() { *x = SubscribeTakeoffRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTakeoffRequest) String() string { @@ -527,7 +512,7 @@ func (*SubscribeTakeoffRequest) ProtoMessage() {} func (x *SubscribeTakeoffRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -550,11 +535,9 @@ type SubscribeLandRequest struct { func (x *SubscribeLandRequest) Reset() { *x = SubscribeLandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeLandRequest) String() string { @@ -565,7 +548,7 @@ func (*SubscribeLandRequest) ProtoMessage() {} func (x *SubscribeLandRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -588,11 +571,9 @@ type SubscribeRebootRequest struct { func (x *SubscribeRebootRequest) Reset() { *x = SubscribeRebootRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeRebootRequest) String() string { @@ -603,7 +584,7 @@ func (*SubscribeRebootRequest) ProtoMessage() {} func (x *SubscribeRebootRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -626,11 +607,9 @@ type SubscribeShutdownRequest struct { func (x *SubscribeShutdownRequest) Reset() { *x = SubscribeShutdownRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeShutdownRequest) String() string { @@ -641,7 +620,7 @@ func (*SubscribeShutdownRequest) ProtoMessage() {} func (x *SubscribeShutdownRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -664,11 +643,9 @@ type SubscribeTerminateRequest struct { func (x *SubscribeTerminateRequest) Reset() { *x = SubscribeTerminateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTerminateRequest) String() string { @@ -679,7 +656,7 @@ func (*SubscribeTerminateRequest) ProtoMessage() {} func (x *SubscribeTerminateRequest) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -705,11 +682,9 @@ type ArmDisarmResponse struct { func (x *ArmDisarmResponse) Reset() { *x = ArmDisarmResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmDisarmResponse) String() string { @@ -720,7 +695,7 @@ func (*ArmDisarmResponse) ProtoMessage() {} func (x *ArmDisarmResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -760,11 +735,9 @@ type FlightModeChangeResponse struct { func (x *FlightModeChangeResponse) Reset() { *x = FlightModeChangeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FlightModeChangeResponse) String() string { @@ -775,7 +748,7 @@ func (*FlightModeChangeResponse) ProtoMessage() {} func (x *FlightModeChangeResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -815,11 +788,9 @@ type TakeoffResponse struct { func (x *TakeoffResponse) Reset() { *x = TakeoffResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakeoffResponse) String() string { @@ -830,7 +801,7 @@ func (*TakeoffResponse) ProtoMessage() {} func (x *TakeoffResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -870,11 +841,9 @@ type LandResponse struct { func (x *LandResponse) Reset() { *x = LandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LandResponse) String() string { @@ -885,7 +854,7 @@ func (*LandResponse) ProtoMessage() {} func (x *LandResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -925,11 +894,9 @@ type RebootResponse struct { func (x *RebootResponse) Reset() { *x = RebootResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RebootResponse) String() string { @@ -940,7 +907,7 @@ func (*RebootResponse) ProtoMessage() {} func (x *RebootResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -980,11 +947,9 @@ type ShutdownResponse struct { func (x *ShutdownResponse) Reset() { *x = ShutdownResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ShutdownResponse) String() string { @@ -995,7 +960,7 @@ func (*ShutdownResponse) ProtoMessage() {} func (x *ShutdownResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1035,11 +1000,9 @@ type TerminateResponse struct { func (x *TerminateResponse) Reset() { *x = TerminateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TerminateResponse) String() string { @@ -1050,7 +1013,7 @@ func (*TerminateResponse) ProtoMessage() {} func (x *TerminateResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1089,11 +1052,9 @@ type SetArmableResponse struct { func (x *SetArmableResponse) Reset() { *x = SetArmableResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetArmableResponse) String() string { @@ -1104,7 +1065,7 @@ func (*SetArmableResponse) ProtoMessage() {} func (x *SetArmableResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1136,11 +1097,9 @@ type SetDisarmableResponse struct { func (x *SetDisarmableResponse) Reset() { *x = SetDisarmableResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetDisarmableResponse) String() string { @@ -1151,7 +1110,7 @@ func (*SetDisarmableResponse) ProtoMessage() {} func (x *SetDisarmableResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1183,11 +1142,9 @@ type SetAllowableFlightModesResponse struct { func (x *SetAllowableFlightModesResponse) Reset() { *x = SetAllowableFlightModesResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAllowableFlightModesResponse) String() string { @@ -1198,7 +1155,7 @@ func (*SetAllowableFlightModesResponse) ProtoMessage() {} func (x *SetAllowableFlightModesResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1230,11 +1187,9 @@ type SetAllowTakeoffResponse struct { func (x *SetAllowTakeoffResponse) Reset() { *x = SetAllowTakeoffResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAllowTakeoffResponse) String() string { @@ -1245,7 +1200,7 @@ func (*SetAllowTakeoffResponse) ProtoMessage() {} func (x *SetAllowTakeoffResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1277,11 +1232,9 @@ type GetAllowableFlightModesResponse struct { func (x *GetAllowableFlightModesResponse) Reset() { *x = GetAllowableFlightModesResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetAllowableFlightModesResponse) String() string { @@ -1292,7 +1245,7 @@ func (*GetAllowableFlightModesResponse) ProtoMessage() {} func (x *GetAllowableFlightModesResponse) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1328,11 +1281,9 @@ type AllowableFlightModes struct { func (x *AllowableFlightModes) Reset() { *x = AllowableFlightModes{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AllowableFlightModes) String() string { @@ -1343,7 +1294,7 @@ func (*AllowableFlightModes) ProtoMessage() {} func (x *AllowableFlightModes) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1391,11 +1342,9 @@ type ArmDisarm struct { func (x *ArmDisarm) Reset() { *x = ArmDisarm{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmDisarm) String() string { @@ -1406,7 +1355,7 @@ func (*ArmDisarm) ProtoMessage() {} func (x *ArmDisarm) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1447,11 +1396,9 @@ type ActionServerResult struct { func (x *ActionServerResult) Reset() { *x = ActionServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_action_server_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_action_server_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActionServerResult) String() string { @@ -1462,7 +1409,7 @@ func (*ActionServerResult) ProtoMessage() {} func (x *ActionServerResult) ProtoReflect() protoreflect.Message { mi := &file_action_server_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1910,333 +1857,6 @@ func file_action_server_proto_init() { if File_action_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_action_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SetAllowTakeoffRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SetArmableRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetDisarmableRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetAllowableFlightModesRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*GetAllowableFlightModesRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeArmDisarmRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeFlightModeChangeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTakeoffRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeLandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeRebootRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeShutdownRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTerminateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*ArmDisarmResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*FlightModeChangeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*TakeoffResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*LandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*RebootResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*ShutdownResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*TerminateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*SetArmableResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*SetDisarmableResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*SetAllowableFlightModesResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SetAllowTakeoffResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*GetAllowableFlightModesResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*AllowableFlightModes); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*ArmDisarm); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_action_server_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*ActionServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/action_server/action_server_grpc.pb.go b/Sources/action_server/action_server_grpc.pb.go index f601043..1008805 100644 --- a/Sources/action_server/action_server_grpc.pb.go +++ b/Sources/action_server/action_server_grpc.pb.go @@ -8,6 +8,7 @@ package action_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/arm_authorizer_server/arm_authorizer_server.go b/Sources/arm_authorizer_server/arm_authorizer_server.go index 9dc14c1..9ce0d5d 100644 --- a/Sources/arm_authorizer_server/arm_authorizer_server.go +++ b/Sources/arm_authorizer_server/arm_authorizer_server.go @@ -2,11 +2,11 @@ package arm_authorizer_server import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to arm authorization request messages. Each request received should respond to using RespondArmAuthorization - - +ArmAuthorization Subscribe to arm authorization request messages. Each request received should respond to using RespondArmAuthorization */ +func (a *ServiceImpl) ArmAuthorization( + ctx context.Context, -func (a *ServiceImpl) ArmAuthorization(ctx context.Context) (<-chan uint32, error) { +) (<-chan uint32, error) { ch := make(chan uint32) request := &SubscribeArmAuthorizationRequest{} stream, err := a.Client.SubscribeArmAuthorization(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) ArmAuthorization(ctx context.Context) (<-chan uint32, erro if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ArmAuthorization messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ArmAuthorization messages, err: %v", err) } ch <- m.GetSystemId() } @@ -48,19 +47,16 @@ func (a *ServiceImpl) ArmAuthorization(ctx context.Context) (<-chan uint32, erro } /* - Authorize arm for the specific time - - Parameters - ---------- - validTimeS int32 - - +AcceptArmAuthorization Authorize arm for the specific time */ +func (s *ServiceImpl) AcceptArmAuthorization( + ctx context.Context, + validTimeS int32, -func (s *ServiceImpl) AcceptArmAuthorization(ctx context.Context, validTimeS int32) (*AcceptArmAuthorizationResponse, error) { - - request := &AcceptArmAuthorizationRequest{} - request.ValidTimeS = validTimeS +) (*AcceptArmAuthorizationResponse, error) { + request := &AcceptArmAuthorizationRequest{ + ValidTimeS: validTimeS, + } response, err := s.Client.AcceptArmAuthorization(ctx, request) if err != nil { return nil, err @@ -69,26 +65,21 @@ func (s *ServiceImpl) AcceptArmAuthorization(ctx context.Context, validTimeS int } /* - Reject arm authorization request - - Parameters - ---------- - temporarily bool - - reason *RejectionReason - - - extraInfo int32 - - +RejectArmAuthorization Reject arm authorization request */ - -func (s *ServiceImpl) RejectArmAuthorization(ctx context.Context, temporarily bool, reason *RejectionReason, extraInfo int32) (*RejectArmAuthorizationResponse, error) { - - request := &RejectArmAuthorizationRequest{} - request.Temporarily = temporarily - request.Reason = *reason - request.ExtraInfo = extraInfo +func (s *ServiceImpl) RejectArmAuthorization( + ctx context.Context, + temporarily bool, + reason *RejectionReason, + + extraInfo int32, + +) (*RejectArmAuthorizationResponse, error) { + request := &RejectArmAuthorizationRequest{ + Temporarily: temporarily, + Reason: *reason, + ExtraInfo: extraInfo, + } response, err := s.Client.RejectArmAuthorization(ctx, request) if err != nil { return nil, err diff --git a/Sources/arm_authorizer_server/arm_authorizer_server.pb.go b/Sources/arm_authorizer_server/arm_authorizer_server.pb.go index 73beb65..dab6d5a 100644 --- a/Sources/arm_authorizer_server/arm_authorizer_server.pb.go +++ b/Sources/arm_authorizer_server/arm_authorizer_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: arm_authorizer_server.proto package arm_authorizer_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -136,11 +137,9 @@ type SubscribeArmAuthorizationRequest struct { func (x *SubscribeArmAuthorizationRequest) Reset() { *x = SubscribeArmAuthorizationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeArmAuthorizationRequest) String() string { @@ -151,7 +150,7 @@ func (*SubscribeArmAuthorizationRequest) ProtoMessage() {} func (x *SubscribeArmAuthorizationRequest) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -176,11 +175,9 @@ type ArmAuthorizationResponse struct { func (x *ArmAuthorizationResponse) Reset() { *x = ArmAuthorizationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmAuthorizationResponse) String() string { @@ -191,7 +188,7 @@ func (*ArmAuthorizationResponse) ProtoMessage() {} func (x *ArmAuthorizationResponse) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -224,11 +221,9 @@ type AcceptArmAuthorizationRequest struct { func (x *AcceptArmAuthorizationRequest) Reset() { *x = AcceptArmAuthorizationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AcceptArmAuthorizationRequest) String() string { @@ -239,7 +234,7 @@ func (*AcceptArmAuthorizationRequest) ProtoMessage() {} func (x *AcceptArmAuthorizationRequest) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -272,11 +267,9 @@ type AcceptArmAuthorizationResponse struct { func (x *AcceptArmAuthorizationResponse) Reset() { *x = AcceptArmAuthorizationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AcceptArmAuthorizationResponse) String() string { @@ -287,7 +280,7 @@ func (*AcceptArmAuthorizationResponse) ProtoMessage() {} func (x *AcceptArmAuthorizationResponse) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -322,11 +315,9 @@ type RejectArmAuthorizationRequest struct { func (x *RejectArmAuthorizationRequest) Reset() { *x = RejectArmAuthorizationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RejectArmAuthorizationRequest) String() string { @@ -337,7 +328,7 @@ func (*RejectArmAuthorizationRequest) ProtoMessage() {} func (x *RejectArmAuthorizationRequest) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -384,11 +375,9 @@ type RejectArmAuthorizationResponse struct { func (x *RejectArmAuthorizationResponse) Reset() { *x = RejectArmAuthorizationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RejectArmAuthorizationResponse) String() string { @@ -399,7 +388,7 @@ func (*RejectArmAuthorizationResponse) ProtoMessage() {} func (x *RejectArmAuthorizationResponse) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -432,11 +421,9 @@ type ArmAuthorizerServerResult struct { func (x *ArmAuthorizerServerResult) Reset() { *x = ArmAuthorizerServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_arm_authorizer_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_arm_authorizer_server_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmAuthorizerServerResult) String() string { @@ -447,7 +434,7 @@ func (*ArmAuthorizerServerResult) ProtoMessage() {} func (x *ArmAuthorizerServerResult) ProtoReflect() protoreflect.Message { mi := &file_arm_authorizer_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -640,93 +627,6 @@ func file_arm_authorizer_server_proto_init() { if File_arm_authorizer_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_arm_authorizer_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeArmAuthorizationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_arm_authorizer_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*ArmAuthorizationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_arm_authorizer_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*AcceptArmAuthorizationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_arm_authorizer_server_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*AcceptArmAuthorizationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_arm_authorizer_server_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*RejectArmAuthorizationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_arm_authorizer_server_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*RejectArmAuthorizationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_arm_authorizer_server_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*ArmAuthorizerServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/arm_authorizer_server/arm_authorizer_server_grpc.pb.go b/Sources/arm_authorizer_server/arm_authorizer_server_grpc.pb.go index bbdba65..dd2da9b 100644 --- a/Sources/arm_authorizer_server/arm_authorizer_server_grpc.pb.go +++ b/Sources/arm_authorizer_server/arm_authorizer_server_grpc.pb.go @@ -8,6 +8,7 @@ package arm_authorizer_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/calibration/calibration.go b/Sources/calibration/calibration.go index 3faca0f..0b80437 100644 --- a/Sources/calibration/calibration.go +++ b/Sources/calibration/calibration.go @@ -2,11 +2,11 @@ package calibration import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Perform gyro calibration. - - +CalibrateGyro Perform gyro calibration. */ +func (a *ServiceImpl) CalibrateGyro( + ctx context.Context, -func (a *ServiceImpl) CalibrateGyro(ctx context.Context) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) request := &SubscribeCalibrateGyroRequest{} stream, err := a.Client.SubscribeCalibrateGyro(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) CalibrateGyro(ctx context.Context) (<-chan *ProgressData, if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CalibrateGyro messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CalibrateGyro messages, err: %v", err) } ch <- m.GetProgressData() } @@ -48,12 +47,12 @@ func (a *ServiceImpl) CalibrateGyro(ctx context.Context) (<-chan *ProgressData, } /* - Perform accelerometer calibration. - - +CalibrateAccelerometer Perform accelerometer calibration. */ +func (a *ServiceImpl) CalibrateAccelerometer( + ctx context.Context, -func (a *ServiceImpl) CalibrateAccelerometer(ctx context.Context) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) request := &SubscribeCalibrateAccelerometerRequest{} stream, err := a.Client.SubscribeCalibrateAccelerometer(ctx, request) @@ -72,8 +71,7 @@ func (a *ServiceImpl) CalibrateAccelerometer(ctx context.Context) (<-chan *Progr if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CalibrateAccelerometer messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CalibrateAccelerometer messages, err: %v", err) } ch <- m.GetProgressData() } @@ -82,12 +80,12 @@ func (a *ServiceImpl) CalibrateAccelerometer(ctx context.Context) (<-chan *Progr } /* - Perform magnetometer calibration. - - +CalibrateMagnetometer Perform magnetometer calibration. */ +func (a *ServiceImpl) CalibrateMagnetometer( + ctx context.Context, -func (a *ServiceImpl) CalibrateMagnetometer(ctx context.Context) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) request := &SubscribeCalibrateMagnetometerRequest{} stream, err := a.Client.SubscribeCalibrateMagnetometer(ctx, request) @@ -106,8 +104,7 @@ func (a *ServiceImpl) CalibrateMagnetometer(ctx context.Context) (<-chan *Progre if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CalibrateMagnetometer messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CalibrateMagnetometer messages, err: %v", err) } ch <- m.GetProgressData() } @@ -116,12 +113,12 @@ func (a *ServiceImpl) CalibrateMagnetometer(ctx context.Context) (<-chan *Progre } /* - Perform board level horizon calibration. - - +CalibrateLevelHorizon Perform board level horizon calibration. */ +func (a *ServiceImpl) CalibrateLevelHorizon( + ctx context.Context, -func (a *ServiceImpl) CalibrateLevelHorizon(ctx context.Context) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) request := &SubscribeCalibrateLevelHorizonRequest{} stream, err := a.Client.SubscribeCalibrateLevelHorizon(ctx, request) @@ -140,8 +137,7 @@ func (a *ServiceImpl) CalibrateLevelHorizon(ctx context.Context) (<-chan *Progre if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CalibrateLevelHorizon messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CalibrateLevelHorizon messages, err: %v", err) } ch <- m.GetProgressData() } @@ -150,12 +146,12 @@ func (a *ServiceImpl) CalibrateLevelHorizon(ctx context.Context) (<-chan *Progre } /* - Perform gimbal accelerometer calibration. - - +CalibrateGimbalAccelerometer Perform gimbal accelerometer calibration. */ +func (a *ServiceImpl) CalibrateGimbalAccelerometer( + ctx context.Context, -func (a *ServiceImpl) CalibrateGimbalAccelerometer(ctx context.Context) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) request := &SubscribeCalibrateGimbalAccelerometerRequest{} stream, err := a.Client.SubscribeCalibrateGimbalAccelerometer(ctx, request) @@ -174,8 +170,7 @@ func (a *ServiceImpl) CalibrateGimbalAccelerometer(ctx context.Context) (<-chan if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CalibrateGimbalAccelerometer messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CalibrateGimbalAccelerometer messages, err: %v", err) } ch <- m.GetProgressData() } @@ -184,13 +179,12 @@ func (a *ServiceImpl) CalibrateGimbalAccelerometer(ctx context.Context) (<-chan } /* - Cancel ongoing calibration process. - - +Cancel Cancel ongoing calibration process. */ +func (s *ServiceImpl) Cancel( + ctx context.Context, -func (s *ServiceImpl) Cancel(ctx context.Context) (*CancelResponse, error) { - +) (*CancelResponse, error) { request := &CancelRequest{} response, err := s.Client.Cancel(ctx, request) if err != nil { diff --git a/Sources/calibration/calibration.pb.go b/Sources/calibration/calibration.pb.go index eaa78f0..7ab23f6 100644 --- a/Sources/calibration/calibration.pb.go +++ b/Sources/calibration/calibration.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: calibration.proto package calibration import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -105,11 +106,9 @@ type SubscribeCalibrateGyroRequest struct { func (x *SubscribeCalibrateGyroRequest) Reset() { *x = SubscribeCalibrateGyroRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCalibrateGyroRequest) String() string { @@ -120,7 +119,7 @@ func (*SubscribeCalibrateGyroRequest) ProtoMessage() {} func (x *SubscribeCalibrateGyroRequest) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -146,11 +145,9 @@ type CalibrateGyroResponse struct { func (x *CalibrateGyroResponse) Reset() { *x = CalibrateGyroResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CalibrateGyroResponse) String() string { @@ -161,7 +158,7 @@ func (*CalibrateGyroResponse) ProtoMessage() {} func (x *CalibrateGyroResponse) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -198,11 +195,9 @@ type SubscribeCalibrateAccelerometerRequest struct { func (x *SubscribeCalibrateAccelerometerRequest) Reset() { *x = SubscribeCalibrateAccelerometerRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCalibrateAccelerometerRequest) String() string { @@ -213,7 +208,7 @@ func (*SubscribeCalibrateAccelerometerRequest) ProtoMessage() {} func (x *SubscribeCalibrateAccelerometerRequest) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -239,11 +234,9 @@ type CalibrateAccelerometerResponse struct { func (x *CalibrateAccelerometerResponse) Reset() { *x = CalibrateAccelerometerResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CalibrateAccelerometerResponse) String() string { @@ -254,7 +247,7 @@ func (*CalibrateAccelerometerResponse) ProtoMessage() {} func (x *CalibrateAccelerometerResponse) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -291,11 +284,9 @@ type SubscribeCalibrateMagnetometerRequest struct { func (x *SubscribeCalibrateMagnetometerRequest) Reset() { *x = SubscribeCalibrateMagnetometerRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCalibrateMagnetometerRequest) String() string { @@ -306,7 +297,7 @@ func (*SubscribeCalibrateMagnetometerRequest) ProtoMessage() {} func (x *SubscribeCalibrateMagnetometerRequest) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -332,11 +323,9 @@ type CalibrateMagnetometerResponse struct { func (x *CalibrateMagnetometerResponse) Reset() { *x = CalibrateMagnetometerResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CalibrateMagnetometerResponse) String() string { @@ -347,7 +336,7 @@ func (*CalibrateMagnetometerResponse) ProtoMessage() {} func (x *CalibrateMagnetometerResponse) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -384,11 +373,9 @@ type SubscribeCalibrateLevelHorizonRequest struct { func (x *SubscribeCalibrateLevelHorizonRequest) Reset() { *x = SubscribeCalibrateLevelHorizonRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCalibrateLevelHorizonRequest) String() string { @@ -399,7 +386,7 @@ func (*SubscribeCalibrateLevelHorizonRequest) ProtoMessage() {} func (x *SubscribeCalibrateLevelHorizonRequest) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -425,11 +412,9 @@ type CalibrateLevelHorizonResponse struct { func (x *CalibrateLevelHorizonResponse) Reset() { *x = CalibrateLevelHorizonResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CalibrateLevelHorizonResponse) String() string { @@ -440,7 +425,7 @@ func (*CalibrateLevelHorizonResponse) ProtoMessage() {} func (x *CalibrateLevelHorizonResponse) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -477,11 +462,9 @@ type SubscribeCalibrateGimbalAccelerometerRequest struct { func (x *SubscribeCalibrateGimbalAccelerometerRequest) Reset() { *x = SubscribeCalibrateGimbalAccelerometerRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCalibrateGimbalAccelerometerRequest) String() string { @@ -492,7 +475,7 @@ func (*SubscribeCalibrateGimbalAccelerometerRequest) ProtoMessage() {} func (x *SubscribeCalibrateGimbalAccelerometerRequest) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -518,11 +501,9 @@ type CalibrateGimbalAccelerometerResponse struct { func (x *CalibrateGimbalAccelerometerResponse) Reset() { *x = CalibrateGimbalAccelerometerResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CalibrateGimbalAccelerometerResponse) String() string { @@ -533,7 +514,7 @@ func (*CalibrateGimbalAccelerometerResponse) ProtoMessage() {} func (x *CalibrateGimbalAccelerometerResponse) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -570,11 +551,9 @@ type CancelRequest struct { func (x *CancelRequest) Reset() { *x = CancelRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelRequest) String() string { @@ -585,7 +564,7 @@ func (*CancelRequest) ProtoMessage() {} func (x *CancelRequest) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -610,11 +589,9 @@ type CancelResponse struct { func (x *CancelResponse) Reset() { *x = CancelResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelResponse) String() string { @@ -625,7 +602,7 @@ func (*CancelResponse) ProtoMessage() {} func (x *CancelResponse) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -659,11 +636,9 @@ type CalibrationResult struct { func (x *CalibrationResult) Reset() { *x = CalibrationResult{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CalibrationResult) String() string { @@ -674,7 +649,7 @@ func (*CalibrationResult) ProtoMessage() {} func (x *CalibrationResult) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -719,11 +694,9 @@ type ProgressData struct { func (x *ProgressData) Reset() { *x = ProgressData{} - if protoimpl.UnsafeEnabled { - mi := &file_calibration_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_calibration_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProgressData) String() string { @@ -734,7 +707,7 @@ func (*ProgressData) ProtoMessage() {} func (x *ProgressData) ProtoReflect() protoreflect.Message { mi := &file_calibration_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1035,177 +1008,6 @@ func file_calibration_proto_init() { if File_calibration_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_calibration_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCalibrateGyroRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*CalibrateGyroResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCalibrateAccelerometerRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*CalibrateAccelerometerResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCalibrateMagnetometerRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*CalibrateMagnetometerResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCalibrateLevelHorizonRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*CalibrateLevelHorizonResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCalibrateGimbalAccelerometerRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*CalibrateGimbalAccelerometerResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*CancelRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*CancelResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*CalibrationResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_calibration_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*ProgressData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/calibration/calibration_grpc.pb.go b/Sources/calibration/calibration_grpc.pb.go index ec8b0fc..f1234c3 100644 --- a/Sources/calibration/calibration_grpc.pb.go +++ b/Sources/calibration/calibration_grpc.pb.go @@ -8,6 +8,7 @@ package calibration import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/camera/camera.go b/Sources/camera/camera.go index 1362fc7..f4aed54 100644 --- a/Sources/camera/camera.go +++ b/Sources/camera/camera.go @@ -2,11 +2,11 @@ package camera import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,13 +14,12 @@ type ServiceImpl struct { } /* - Prepare the camera plugin (e.g. download the camera definition, etc). - - +Prepare Prepare the camera plugin (e.g. download the camera definition, etc). */ +func (s *ServiceImpl) Prepare( + ctx context.Context, -func (s *ServiceImpl) Prepare(ctx context.Context) (*PrepareResponse, error) { - +) (*PrepareResponse, error) { request := &PrepareRequest{} response, err := s.Client.Prepare(ctx, request) if err != nil { @@ -30,13 +29,12 @@ func (s *ServiceImpl) Prepare(ctx context.Context) (*PrepareResponse, error) { } /* - Take one photo. - - +TakePhoto Take one photo. */ +func (s *ServiceImpl) TakePhoto( + ctx context.Context, -func (s *ServiceImpl) TakePhoto(ctx context.Context) (*TakePhotoResponse, error) { - +) (*TakePhotoResponse, error) { request := &TakePhotoRequest{} response, err := s.Client.TakePhoto(ctx, request) if err != nil { @@ -46,19 +44,16 @@ func (s *ServiceImpl) TakePhoto(ctx context.Context) (*TakePhotoResponse, error) } /* - Start photo timelapse with a given interval. - - Parameters - ---------- - intervalS float32 - - +StartPhotoInterval Start photo timelapse with a given interval. */ +func (s *ServiceImpl) StartPhotoInterval( + ctx context.Context, + intervalS float32, -func (s *ServiceImpl) StartPhotoInterval(ctx context.Context, intervalS float32) (*StartPhotoIntervalResponse, error) { - - request := &StartPhotoIntervalRequest{} - request.IntervalS = intervalS +) (*StartPhotoIntervalResponse, error) { + request := &StartPhotoIntervalRequest{ + IntervalS: intervalS, + } response, err := s.Client.StartPhotoInterval(ctx, request) if err != nil { return nil, err @@ -67,13 +62,12 @@ func (s *ServiceImpl) StartPhotoInterval(ctx context.Context, intervalS float32) } /* - Stop a running photo timelapse. - - +StopPhotoInterval Stop a running photo timelapse. */ +func (s *ServiceImpl) StopPhotoInterval( + ctx context.Context, -func (s *ServiceImpl) StopPhotoInterval(ctx context.Context) (*StopPhotoIntervalResponse, error) { - +) (*StopPhotoIntervalResponse, error) { request := &StopPhotoIntervalRequest{} response, err := s.Client.StopPhotoInterval(ctx, request) if err != nil { @@ -83,13 +77,12 @@ func (s *ServiceImpl) StopPhotoInterval(ctx context.Context) (*StopPhotoInterval } /* - Start a video recording. - - +StartVideo Start a video recording. */ +func (s *ServiceImpl) StartVideo( + ctx context.Context, -func (s *ServiceImpl) StartVideo(ctx context.Context) (*StartVideoResponse, error) { - +) (*StartVideoResponse, error) { request := &StartVideoRequest{} response, err := s.Client.StartVideo(ctx, request) if err != nil { @@ -99,13 +92,12 @@ func (s *ServiceImpl) StartVideo(ctx context.Context) (*StartVideoResponse, erro } /* - Stop a running video recording. - - +StopVideo Stop a running video recording. */ +func (s *ServiceImpl) StopVideo( + ctx context.Context, -func (s *ServiceImpl) StopVideo(ctx context.Context) (*StopVideoResponse, error) { - +) (*StopVideoResponse, error) { request := &StopVideoRequest{} response, err := s.Client.StopVideo(ctx, request) if err != nil { @@ -115,19 +107,16 @@ func (s *ServiceImpl) StopVideo(ctx context.Context) (*StopVideoResponse, error) } /* - Start video streaming. - - Parameters - ---------- - streamId int32 - - +StartVideoStreaming Start video streaming. */ +func (s *ServiceImpl) StartVideoStreaming( + ctx context.Context, + streamId int32, -func (s *ServiceImpl) StartVideoStreaming(ctx context.Context, streamId int32) (*StartVideoStreamingResponse, error) { - - request := &StartVideoStreamingRequest{} - request.StreamId = streamId +) (*StartVideoStreamingResponse, error) { + request := &StartVideoStreamingRequest{ + StreamId: streamId, + } response, err := s.Client.StartVideoStreaming(ctx, request) if err != nil { return nil, err @@ -136,19 +125,16 @@ func (s *ServiceImpl) StartVideoStreaming(ctx context.Context, streamId int32) ( } /* - Stop current video streaming. - - Parameters - ---------- - streamId int32 - - +StopVideoStreaming Stop current video streaming. */ +func (s *ServiceImpl) StopVideoStreaming( + ctx context.Context, + streamId int32, -func (s *ServiceImpl) StopVideoStreaming(ctx context.Context, streamId int32) (*StopVideoStreamingResponse, error) { - - request := &StopVideoStreamingRequest{} - request.StreamId = streamId +) (*StopVideoStreamingResponse, error) { + request := &StopVideoStreamingRequest{ + StreamId: streamId, + } response, err := s.Client.StopVideoStreaming(ctx, request) if err != nil { return nil, err @@ -157,20 +143,16 @@ func (s *ServiceImpl) StopVideoStreaming(ctx context.Context, streamId int32) (* } /* - Set camera mode. - - Parameters - ---------- - mode *Mode - - - +SetMode Set camera mode. */ +func (s *ServiceImpl) SetMode( + ctx context.Context, + mode *Mode, -func (s *ServiceImpl) SetMode(ctx context.Context, mode *Mode) (*SetModeResponse, error) { - - request := &SetModeRequest{} - request.Mode = *mode +) (*SetModeResponse, error) { + request := &SetModeRequest{ + Mode: *mode, + } response, err := s.Client.SetMode(ctx, request) if err != nil { return nil, err @@ -179,40 +161,30 @@ func (s *ServiceImpl) SetMode(ctx context.Context, mode *Mode) (*SetModeResponse } /* - List photos available on the camera. - - Parameters - ---------- - photosRange *PhotosRange - - - Returns - ------- - True - CaptureInfos : []*CaptureInfo - List of capture infos (representing the photos) - - +ListPhotos List photos available on the camera. */ +func (s *ServiceImpl) ListPhotos( + ctx context.Context, + photosRange *PhotosRange, -func (s *ServiceImpl) ListPhotos(ctx context.Context, photosRange *PhotosRange) (*ListPhotosResponse, error) { - request := &ListPhotosRequest{} - request.PhotosRange = *photosRange +) (*ListPhotosResponse, error) { + request := &ListPhotosRequest{ + PhotosRange: *photosRange, + } response, err := s.Client.ListPhotos(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Subscribe to camera mode updates. - - +Mode Subscribe to camera mode updates. */ +func (a *ServiceImpl) Mode( + ctx context.Context, -func (a *ServiceImpl) Mode(ctx context.Context) (<-chan Mode, error) { +) (<-chan Mode, error) { ch := make(chan Mode) request := &SubscribeModeRequest{} stream, err := a.Client.SubscribeMode(ctx, request) @@ -231,8 +203,7 @@ func (a *ServiceImpl) Mode(ctx context.Context) (<-chan Mode, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Mode messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Mode messages, err: %v", err) } ch <- m.GetMode() } @@ -241,12 +212,12 @@ func (a *ServiceImpl) Mode(ctx context.Context) (<-chan Mode, error) { } /* - Subscribe to camera information updates. - - +Information Subscribe to camera information updates. */ +func (a *ServiceImpl) Information( + ctx context.Context, -func (a *ServiceImpl) Information(ctx context.Context) (<-chan *Information, error) { +) (<-chan *Information, error) { ch := make(chan *Information) request := &SubscribeInformationRequest{} stream, err := a.Client.SubscribeInformation(ctx, request) @@ -265,8 +236,7 @@ func (a *ServiceImpl) Information(ctx context.Context) (<-chan *Information, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Information messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Information messages, err: %v", err) } ch <- m.GetInformation() } @@ -275,12 +245,12 @@ func (a *ServiceImpl) Information(ctx context.Context) (<-chan *Information, err } /* - Subscribe to video stream info updates. - - +VideoStreamInfo Subscribe to video stream info updates. */ +func (a *ServiceImpl) VideoStreamInfo( + ctx context.Context, -func (a *ServiceImpl) VideoStreamInfo(ctx context.Context) (<-chan *VideoStreamInfo, error) { +) (<-chan *VideoStreamInfo, error) { ch := make(chan *VideoStreamInfo) request := &SubscribeVideoStreamInfoRequest{} stream, err := a.Client.SubscribeVideoStreamInfo(ctx, request) @@ -299,8 +269,7 @@ func (a *ServiceImpl) VideoStreamInfo(ctx context.Context) (<-chan *VideoStreamI if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive VideoStreamInfo messages, err: %v\n", err) - break + log.Fatalf("Unable to receive VideoStreamInfo messages, err: %v", err) } ch <- m.GetVideoStreamInfo() } @@ -309,12 +278,12 @@ func (a *ServiceImpl) VideoStreamInfo(ctx context.Context) (<-chan *VideoStreamI } /* - Subscribe to capture info updates. - - +CaptureInfo Subscribe to capture info updates. */ +func (a *ServiceImpl) CaptureInfo( + ctx context.Context, -func (a *ServiceImpl) CaptureInfo(ctx context.Context) (<-chan *CaptureInfo, error) { +) (<-chan *CaptureInfo, error) { ch := make(chan *CaptureInfo) request := &SubscribeCaptureInfoRequest{} stream, err := a.Client.SubscribeCaptureInfo(ctx, request) @@ -333,8 +302,7 @@ func (a *ServiceImpl) CaptureInfo(ctx context.Context) (<-chan *CaptureInfo, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CaptureInfo messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CaptureInfo messages, err: %v", err) } ch <- m.GetCaptureInfo() } @@ -343,12 +311,12 @@ func (a *ServiceImpl) CaptureInfo(ctx context.Context) (<-chan *CaptureInfo, err } /* - Subscribe to camera status updates. - - +Status Subscribe to camera status updates. */ +func (a *ServiceImpl) Status( + ctx context.Context, -func (a *ServiceImpl) Status(ctx context.Context) (<-chan *Status, error) { +) (<-chan *Status, error) { ch := make(chan *Status) request := &SubscribeStatusRequest{} stream, err := a.Client.SubscribeStatus(ctx, request) @@ -367,8 +335,7 @@ func (a *ServiceImpl) Status(ctx context.Context) (<-chan *Status, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Status messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Status messages, err: %v", err) } ch <- m.GetCameraStatus() } @@ -377,12 +344,12 @@ func (a *ServiceImpl) Status(ctx context.Context) (<-chan *Status, error) { } /* - Get the list of current camera settings. - - +CurrentSettings Get the list of current camera settings. */ +func (a *ServiceImpl) CurrentSettings( + ctx context.Context, -func (a *ServiceImpl) CurrentSettings(ctx context.Context) (<-chan []*Setting, error) { +) (<-chan []*Setting, error) { ch := make(chan []*Setting) request := &SubscribeCurrentSettingsRequest{} stream, err := a.Client.SubscribeCurrentSettings(ctx, request) @@ -401,8 +368,7 @@ func (a *ServiceImpl) CurrentSettings(ctx context.Context) (<-chan []*Setting, e if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CurrentSettings messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CurrentSettings messages, err: %v", err) } ch <- m.GetCurrentSettings() } @@ -411,12 +377,12 @@ func (a *ServiceImpl) CurrentSettings(ctx context.Context) (<-chan []*Setting, e } /* - Get the list of settings that can be changed. - - +PossibleSettingOptions Get the list of settings that can be changed. */ +func (a *ServiceImpl) PossibleSettingOptions( + ctx context.Context, -func (a *ServiceImpl) PossibleSettingOptions(ctx context.Context) (<-chan []*SettingOptions, error) { +) (<-chan []*SettingOptions, error) { ch := make(chan []*SettingOptions) request := &SubscribePossibleSettingOptionsRequest{} stream, err := a.Client.SubscribePossibleSettingOptions(ctx, request) @@ -435,8 +401,7 @@ func (a *ServiceImpl) PossibleSettingOptions(ctx context.Context) (<-chan []*Set if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive PossibleSettingOptions messages, err: %v\n", err) - break + log.Fatalf("Unable to receive PossibleSettingOptions messages, err: %v", err) } ch <- m.GetSettingOptions() } @@ -445,23 +410,18 @@ func (a *ServiceImpl) PossibleSettingOptions(ctx context.Context) (<-chan []*Set } /* - Set a setting to some value. - - Only setting_id of setting and option_id of option needs to be set. - - Parameters - ---------- - setting *Setting - - +SetSetting Set a setting to some value. + Only setting_id of setting and option_id of option needs to be set. */ +func (s *ServiceImpl) SetSetting( + ctx context.Context, + setting *Setting, -func (s *ServiceImpl) SetSetting(ctx context.Context, setting *Setting) (*SetSettingResponse, error) { - - request := &SetSettingRequest{} - request.Setting = setting - +) (*SetSettingResponse, error) { + request := &SetSettingRequest{ + Setting: setting, + } response, err := s.Client.SetSetting(ctx, request) if err != nil { return nil, err @@ -470,52 +430,38 @@ func (s *ServiceImpl) SetSetting(ctx context.Context, setting *Setting) (*SetSet } /* - Get a setting. - - Only setting_id of setting needs to be set. - - Parameters - ---------- - setting *Setting - - - Returns - ------- - False - Setting : Setting - Setting - +GetSetting Get a setting. + Only setting_id of setting needs to be set. */ +func (s *ServiceImpl) GetSetting( + ctx context.Context, + setting *Setting, -func (s *ServiceImpl) GetSetting(ctx context.Context, setting *Setting) (*GetSettingResponse, error) { - request := &GetSettingRequest{} - request.Setting = setting - +) (*GetSettingResponse, error) { + request := &GetSettingRequest{ + Setting: setting, + } response, err := s.Client.GetSetting(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Format storage (e.g. SD card) in camera. - - This will delete all content of the camera storage! - - Parameters - ---------- - storageId int32 - +FormatStorage Format storage (e.g. SD card) in camera. + This will delete all content of the camera storage! */ +func (s *ServiceImpl) FormatStorage( + ctx context.Context, + storageId int32, -func (s *ServiceImpl) FormatStorage(ctx context.Context, storageId int32) (*FormatStorageResponse, error) { - - request := &FormatStorageRequest{} - request.StorageId = storageId +) (*FormatStorageResponse, error) { + request := &FormatStorageRequest{ + StorageId: storageId, + } response, err := s.Client.FormatStorage(ctx, request) if err != nil { return nil, err @@ -524,21 +470,18 @@ func (s *ServiceImpl) FormatStorage(ctx context.Context, storageId int32) (*Form } /* - Select current camera . - - Bind the plugin instance to a specific camera_id - - Parameters - ---------- - cameraId int32 - +SelectCamera Select current camera . + Bind the plugin instance to a specific camera_id */ +func (s *ServiceImpl) SelectCamera( + ctx context.Context, + cameraId int32, -func (s *ServiceImpl) SelectCamera(ctx context.Context, cameraId int32) (*SelectCameraResponse, error) { - - request := &SelectCameraRequest{} - request.CameraId = cameraId +) (*SelectCameraResponse, error) { + request := &SelectCameraRequest{ + CameraId: cameraId, + } response, err := s.Client.SelectCamera(ctx, request) if err != nil { return nil, err @@ -547,15 +490,14 @@ func (s *ServiceImpl) SelectCamera(ctx context.Context, cameraId int32) (*Select } /* - Reset all settings in camera. - - This will reset all camera settings to default value - +ResetSettings Reset all settings in camera. + This will reset all camera settings to default value */ +func (s *ServiceImpl) ResetSettings( + ctx context.Context, -func (s *ServiceImpl) ResetSettings(ctx context.Context) (*ResetSettingsResponse, error) { - +) (*ResetSettingsResponse, error) { request := &ResetSettingsRequest{} response, err := s.Client.ResetSettings(ctx, request) if err != nil { @@ -565,13 +507,12 @@ func (s *ServiceImpl) ResetSettings(ctx context.Context) (*ResetSettingsResponse } /* - Start zooming in. - - +ZoomInStart Start zooming in. */ +func (s *ServiceImpl) ZoomInStart( + ctx context.Context, -func (s *ServiceImpl) ZoomInStart(ctx context.Context) (*ZoomInStartResponse, error) { - +) (*ZoomInStartResponse, error) { request := &ZoomInStartRequest{} response, err := s.Client.ZoomInStart(ctx, request) if err != nil { @@ -581,13 +522,12 @@ func (s *ServiceImpl) ZoomInStart(ctx context.Context) (*ZoomInStartResponse, er } /* - Start zooming out. - - +ZoomOutStart Start zooming out. */ +func (s *ServiceImpl) ZoomOutStart( + ctx context.Context, -func (s *ServiceImpl) ZoomOutStart(ctx context.Context) (*ZoomOutStartResponse, error) { - +) (*ZoomOutStartResponse, error) { request := &ZoomOutStartRequest{} response, err := s.Client.ZoomOutStart(ctx, request) if err != nil { @@ -597,13 +537,12 @@ func (s *ServiceImpl) ZoomOutStart(ctx context.Context) (*ZoomOutStartResponse, } /* - Stop zooming. - - +ZoomStop Stop zooming. */ +func (s *ServiceImpl) ZoomStop( + ctx context.Context, -func (s *ServiceImpl) ZoomStop(ctx context.Context) (*ZoomStopResponse, error) { - +) (*ZoomStopResponse, error) { request := &ZoomStopRequest{} response, err := s.Client.ZoomStop(ctx, request) if err != nil { @@ -613,19 +552,18 @@ func (s *ServiceImpl) ZoomStop(ctx context.Context) (*ZoomStopResponse, error) { } /* - Zoom to value as proportion of full camera range (percentage between 0.0 and 100.0). - - Parameters - ---------- - range float32 - - +ZoomRange Zoom to value as proportion of full camera range (percentage between 0.0 and 100.0). */ +func (s *ServiceImpl) ZoomRange( + ctx context.Context, -func (s *ServiceImpl) ZoomRange(ctx context.Context, zoomRange float32) (*ZoomRangeResponse, error) { + rangeVar float32, - request := &ZoomRangeRequest{} - request.Range = zoomRange +) (*ZoomRangeResponse, error) { + request := &ZoomRangeRequest{ + + Range: rangeVar, + } response, err := s.Client.ZoomRange(ctx, request) if err != nil { return nil, err @@ -634,25 +572,20 @@ func (s *ServiceImpl) ZoomRange(ctx context.Context, zoomRange float32) (*ZoomRa } /* - Track point. - - Parameters - ---------- - pointX float32 - - pointY float32 - - radius float32 - - +TrackPoint Track point. */ +func (s *ServiceImpl) TrackPoint( + ctx context.Context, + pointX float32, + pointY float32, + radius float32, -func (s *ServiceImpl) TrackPoint(ctx context.Context, pointX float32, pointY float32, radius float32) (*TrackPointResponse, error) { - - request := &TrackPointRequest{} - request.PointX = pointX - request.PointY = pointY - request.Radius = radius +) (*TrackPointResponse, error) { + request := &TrackPointRequest{ + PointX: pointX, + PointY: pointY, + Radius: radius, + } response, err := s.Client.TrackPoint(ctx, request) if err != nil { return nil, err @@ -661,28 +594,22 @@ func (s *ServiceImpl) TrackPoint(ctx context.Context, pointX float32, pointY flo } /* - Track rectangle. - - Parameters - ---------- - topLeftX float32 - - topLeftY float32 - - bottomRightX float32 - - bottomRightY float32 - - +TrackRectangle Track rectangle. */ +func (s *ServiceImpl) TrackRectangle( + ctx context.Context, + topLeftX float32, + topLeftY float32, + bottomRightX float32, + bottomRightY float32, -func (s *ServiceImpl) TrackRectangle(ctx context.Context, topLeftX float32, topLeftY float32, bottomRightX float32, bottomRightY float32) (*TrackRectangleResponse, error) { - - request := &TrackRectangleRequest{} - request.TopLeftX = topLeftX - request.TopLeftY = topLeftY - request.BottomRightX = bottomRightX - request.BottomRightY = bottomRightY +) (*TrackRectangleResponse, error) { + request := &TrackRectangleRequest{ + TopLeftX: topLeftX, + TopLeftY: topLeftY, + BottomRightX: bottomRightX, + BottomRightY: bottomRightY, + } response, err := s.Client.TrackRectangle(ctx, request) if err != nil { return nil, err @@ -691,13 +618,12 @@ func (s *ServiceImpl) TrackRectangle(ctx context.Context, topLeftX float32, topL } /* - Stop tracking. - - +TrackStop Stop tracking. */ +func (s *ServiceImpl) TrackStop( + ctx context.Context, -func (s *ServiceImpl) TrackStop(ctx context.Context) (*TrackStopResponse, error) { - +) (*TrackStopResponse, error) { request := &TrackStopRequest{} response, err := s.Client.TrackStop(ctx, request) if err != nil { @@ -707,13 +633,12 @@ func (s *ServiceImpl) TrackStop(ctx context.Context) (*TrackStopResponse, error) } /* - Start focusing in. - - +FocusInStart Start focusing in. */ +func (s *ServiceImpl) FocusInStart( + ctx context.Context, -func (s *ServiceImpl) FocusInStart(ctx context.Context) (*FocusInStartResponse, error) { - +) (*FocusInStartResponse, error) { request := &FocusInStartRequest{} response, err := s.Client.FocusInStart(ctx, request) if err != nil { @@ -723,13 +648,12 @@ func (s *ServiceImpl) FocusInStart(ctx context.Context) (*FocusInStartResponse, } /* - Start focusing out. - - +FocusOutStart Start focusing out. */ +func (s *ServiceImpl) FocusOutStart( + ctx context.Context, -func (s *ServiceImpl) FocusOutStart(ctx context.Context) (*FocusOutStartResponse, error) { - +) (*FocusOutStartResponse, error) { request := &FocusOutStartRequest{} response, err := s.Client.FocusOutStart(ctx, request) if err != nil { @@ -739,13 +663,12 @@ func (s *ServiceImpl) FocusOutStart(ctx context.Context) (*FocusOutStartResponse } /* - Stop focus. - - +FocusStop Stop focus. */ +func (s *ServiceImpl) FocusStop( + ctx context.Context, -func (s *ServiceImpl) FocusStop(ctx context.Context) (*FocusStopResponse, error) { - +) (*FocusStopResponse, error) { request := &FocusStopRequest{} response, err := s.Client.FocusStop(ctx, request) if err != nil { @@ -755,19 +678,18 @@ func (s *ServiceImpl) FocusStop(ctx context.Context) (*FocusStopResponse, error) } /* - Focus with range value of full range (value between 0.0 and 100.0). - - Parameters - ---------- - range float32 - - +FocusRange Focus with range value of full range (value between 0.0 and 100.0). */ +func (s *ServiceImpl) FocusRange( + ctx context.Context, -func (s *ServiceImpl) FocusRange(ctx context.Context, focusRange float32) (*FocusRangeResponse, error) { + rangeVar float32, - request := &FocusRangeRequest{} - request.Range = focusRange +) (*FocusRangeResponse, error) { + request := &FocusRangeRequest{ + + Range: rangeVar, + } response, err := s.Client.FocusRange(ctx, request) if err != nil { return nil, err diff --git a/Sources/camera/camera.pb.go b/Sources/camera/camera.pb.go index 14a897a..7de3271 100644 --- a/Sources/camera/camera.pb.go +++ b/Sources/camera/camera.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: camera.proto package camera import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -405,11 +406,9 @@ type PrepareRequest struct { func (x *PrepareRequest) Reset() { *x = PrepareRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PrepareRequest) String() string { @@ -420,7 +419,7 @@ func (*PrepareRequest) ProtoMessage() {} func (x *PrepareRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -445,11 +444,9 @@ type PrepareResponse struct { func (x *PrepareResponse) Reset() { *x = PrepareResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PrepareResponse) String() string { @@ -460,7 +457,7 @@ func (*PrepareResponse) ProtoMessage() {} func (x *PrepareResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -490,11 +487,9 @@ type TakePhotoRequest struct { func (x *TakePhotoRequest) Reset() { *x = TakePhotoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakePhotoRequest) String() string { @@ -505,7 +500,7 @@ func (*TakePhotoRequest) ProtoMessage() {} func (x *TakePhotoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -530,11 +525,9 @@ type TakePhotoResponse struct { func (x *TakePhotoResponse) Reset() { *x = TakePhotoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakePhotoResponse) String() string { @@ -545,7 +538,7 @@ func (*TakePhotoResponse) ProtoMessage() {} func (x *TakePhotoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -577,11 +570,9 @@ type StartPhotoIntervalRequest struct { func (x *StartPhotoIntervalRequest) Reset() { *x = StartPhotoIntervalRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartPhotoIntervalRequest) String() string { @@ -592,7 +583,7 @@ func (*StartPhotoIntervalRequest) ProtoMessage() {} func (x *StartPhotoIntervalRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -624,11 +615,9 @@ type StartPhotoIntervalResponse struct { func (x *StartPhotoIntervalResponse) Reset() { *x = StartPhotoIntervalResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartPhotoIntervalResponse) String() string { @@ -639,7 +628,7 @@ func (*StartPhotoIntervalResponse) ProtoMessage() {} func (x *StartPhotoIntervalResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -669,11 +658,9 @@ type StopPhotoIntervalRequest struct { func (x *StopPhotoIntervalRequest) Reset() { *x = StopPhotoIntervalRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopPhotoIntervalRequest) String() string { @@ -684,7 +671,7 @@ func (*StopPhotoIntervalRequest) ProtoMessage() {} func (x *StopPhotoIntervalRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -709,11 +696,9 @@ type StopPhotoIntervalResponse struct { func (x *StopPhotoIntervalResponse) Reset() { *x = StopPhotoIntervalResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopPhotoIntervalResponse) String() string { @@ -724,7 +709,7 @@ func (*StopPhotoIntervalResponse) ProtoMessage() {} func (x *StopPhotoIntervalResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -754,11 +739,9 @@ type StartVideoRequest struct { func (x *StartVideoRequest) Reset() { *x = StartVideoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartVideoRequest) String() string { @@ -769,7 +752,7 @@ func (*StartVideoRequest) ProtoMessage() {} func (x *StartVideoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -794,11 +777,9 @@ type StartVideoResponse struct { func (x *StartVideoResponse) Reset() { *x = StartVideoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartVideoResponse) String() string { @@ -809,7 +790,7 @@ func (*StartVideoResponse) ProtoMessage() {} func (x *StartVideoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -839,11 +820,9 @@ type StopVideoRequest struct { func (x *StopVideoRequest) Reset() { *x = StopVideoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopVideoRequest) String() string { @@ -854,7 +833,7 @@ func (*StopVideoRequest) ProtoMessage() {} func (x *StopVideoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -879,11 +858,9 @@ type StopVideoResponse struct { func (x *StopVideoResponse) Reset() { *x = StopVideoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopVideoResponse) String() string { @@ -894,7 +871,7 @@ func (*StopVideoResponse) ProtoMessage() {} func (x *StopVideoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -926,11 +903,9 @@ type StartVideoStreamingRequest struct { func (x *StartVideoStreamingRequest) Reset() { *x = StartVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartVideoStreamingRequest) String() string { @@ -941,7 +916,7 @@ func (*StartVideoStreamingRequest) ProtoMessage() {} func (x *StartVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -973,11 +948,9 @@ type StartVideoStreamingResponse struct { func (x *StartVideoStreamingResponse) Reset() { *x = StartVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartVideoStreamingResponse) String() string { @@ -988,7 +961,7 @@ func (*StartVideoStreamingResponse) ProtoMessage() {} func (x *StartVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1020,11 +993,9 @@ type StopVideoStreamingRequest struct { func (x *StopVideoStreamingRequest) Reset() { *x = StopVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopVideoStreamingRequest) String() string { @@ -1035,7 +1006,7 @@ func (*StopVideoStreamingRequest) ProtoMessage() {} func (x *StopVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1067,11 +1038,9 @@ type StopVideoStreamingResponse struct { func (x *StopVideoStreamingResponse) Reset() { *x = StopVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopVideoStreamingResponse) String() string { @@ -1082,7 +1051,7 @@ func (*StopVideoStreamingResponse) ProtoMessage() {} func (x *StopVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1114,11 +1083,9 @@ type SetModeRequest struct { func (x *SetModeRequest) Reset() { *x = SetModeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetModeRequest) String() string { @@ -1129,7 +1096,7 @@ func (*SetModeRequest) ProtoMessage() {} func (x *SetModeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1161,11 +1128,9 @@ type SetModeResponse struct { func (x *SetModeResponse) Reset() { *x = SetModeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetModeResponse) String() string { @@ -1176,7 +1141,7 @@ func (*SetModeResponse) ProtoMessage() {} func (x *SetModeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1208,11 +1173,9 @@ type ListPhotosRequest struct { func (x *ListPhotosRequest) Reset() { *x = ListPhotosRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ListPhotosRequest) String() string { @@ -1223,7 +1186,7 @@ func (*ListPhotosRequest) ProtoMessage() {} func (x *ListPhotosRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1256,11 +1219,9 @@ type ListPhotosResponse struct { func (x *ListPhotosResponse) Reset() { *x = ListPhotosResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ListPhotosResponse) String() string { @@ -1271,7 +1232,7 @@ func (*ListPhotosResponse) ProtoMessage() {} func (x *ListPhotosResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1308,11 +1269,9 @@ type SubscribeInformationRequest struct { func (x *SubscribeInformationRequest) Reset() { *x = SubscribeInformationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeInformationRequest) String() string { @@ -1323,7 +1282,7 @@ func (*SubscribeInformationRequest) ProtoMessage() {} func (x *SubscribeInformationRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1348,11 +1307,9 @@ type InformationResponse struct { func (x *InformationResponse) Reset() { *x = InformationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *InformationResponse) String() string { @@ -1363,7 +1320,7 @@ func (*InformationResponse) ProtoMessage() {} func (x *InformationResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1393,11 +1350,9 @@ type SubscribeModeRequest struct { func (x *SubscribeModeRequest) Reset() { *x = SubscribeModeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeModeRequest) String() string { @@ -1408,7 +1363,7 @@ func (*SubscribeModeRequest) ProtoMessage() {} func (x *SubscribeModeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1433,11 +1388,9 @@ type ModeResponse struct { func (x *ModeResponse) Reset() { *x = ModeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ModeResponse) String() string { @@ -1448,7 +1401,7 @@ func (*ModeResponse) ProtoMessage() {} func (x *ModeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1478,11 +1431,9 @@ type SubscribeVideoStreamInfoRequest struct { func (x *SubscribeVideoStreamInfoRequest) Reset() { *x = SubscribeVideoStreamInfoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeVideoStreamInfoRequest) String() string { @@ -1493,7 +1444,7 @@ func (*SubscribeVideoStreamInfoRequest) ProtoMessage() {} func (x *SubscribeVideoStreamInfoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1518,11 +1469,9 @@ type VideoStreamInfoResponse struct { func (x *VideoStreamInfoResponse) Reset() { *x = VideoStreamInfoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VideoStreamInfoResponse) String() string { @@ -1533,7 +1482,7 @@ func (*VideoStreamInfoResponse) ProtoMessage() {} func (x *VideoStreamInfoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1563,11 +1512,9 @@ type SubscribeCaptureInfoRequest struct { func (x *SubscribeCaptureInfoRequest) Reset() { *x = SubscribeCaptureInfoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCaptureInfoRequest) String() string { @@ -1578,7 +1525,7 @@ func (*SubscribeCaptureInfoRequest) ProtoMessage() {} func (x *SubscribeCaptureInfoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1603,11 +1550,9 @@ type CaptureInfoResponse struct { func (x *CaptureInfoResponse) Reset() { *x = CaptureInfoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CaptureInfoResponse) String() string { @@ -1618,7 +1563,7 @@ func (*CaptureInfoResponse) ProtoMessage() {} func (x *CaptureInfoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1648,11 +1593,9 @@ type SubscribeStatusRequest struct { func (x *SubscribeStatusRequest) Reset() { *x = SubscribeStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStatusRequest) String() string { @@ -1663,7 +1606,7 @@ func (*SubscribeStatusRequest) ProtoMessage() {} func (x *SubscribeStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1688,11 +1631,9 @@ type StatusResponse struct { func (x *StatusResponse) Reset() { *x = StatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StatusResponse) String() string { @@ -1703,7 +1644,7 @@ func (*StatusResponse) ProtoMessage() {} func (x *StatusResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1733,11 +1674,9 @@ type SubscribeCurrentSettingsRequest struct { func (x *SubscribeCurrentSettingsRequest) Reset() { *x = SubscribeCurrentSettingsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCurrentSettingsRequest) String() string { @@ -1748,7 +1687,7 @@ func (*SubscribeCurrentSettingsRequest) ProtoMessage() {} func (x *SubscribeCurrentSettingsRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1773,11 +1712,9 @@ type CurrentSettingsResponse struct { func (x *CurrentSettingsResponse) Reset() { *x = CurrentSettingsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CurrentSettingsResponse) String() string { @@ -1788,7 +1725,7 @@ func (*CurrentSettingsResponse) ProtoMessage() {} func (x *CurrentSettingsResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1818,11 +1755,9 @@ type SubscribePossibleSettingOptionsRequest struct { func (x *SubscribePossibleSettingOptionsRequest) Reset() { *x = SubscribePossibleSettingOptionsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribePossibleSettingOptionsRequest) String() string { @@ -1833,7 +1768,7 @@ func (*SubscribePossibleSettingOptionsRequest) ProtoMessage() {} func (x *SubscribePossibleSettingOptionsRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1858,11 +1793,9 @@ type PossibleSettingOptionsResponse struct { func (x *PossibleSettingOptionsResponse) Reset() { *x = PossibleSettingOptionsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PossibleSettingOptionsResponse) String() string { @@ -1873,7 +1806,7 @@ func (*PossibleSettingOptionsResponse) ProtoMessage() {} func (x *PossibleSettingOptionsResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1905,11 +1838,9 @@ type SetSettingRequest struct { func (x *SetSettingRequest) Reset() { *x = SetSettingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[34] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetSettingRequest) String() string { @@ -1920,7 +1851,7 @@ func (*SetSettingRequest) ProtoMessage() {} func (x *SetSettingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[34] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1952,11 +1883,9 @@ type SetSettingResponse struct { func (x *SetSettingResponse) Reset() { *x = SetSettingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetSettingResponse) String() string { @@ -1967,7 +1896,7 @@ func (*SetSettingResponse) ProtoMessage() {} func (x *SetSettingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[35] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1999,11 +1928,9 @@ type GetSettingRequest struct { func (x *GetSettingRequest) Reset() { *x = GetSettingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[36] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetSettingRequest) String() string { @@ -2014,7 +1941,7 @@ func (*GetSettingRequest) ProtoMessage() {} func (x *GetSettingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[36] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2047,11 +1974,9 @@ type GetSettingResponse struct { func (x *GetSettingResponse) Reset() { *x = GetSettingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[37] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetSettingResponse) String() string { @@ -2062,7 +1987,7 @@ func (*GetSettingResponse) ProtoMessage() {} func (x *GetSettingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[37] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2101,11 +2026,9 @@ type FormatStorageRequest struct { func (x *FormatStorageRequest) Reset() { *x = FormatStorageRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[38] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FormatStorageRequest) String() string { @@ -2116,7 +2039,7 @@ func (*FormatStorageRequest) ProtoMessage() {} func (x *FormatStorageRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[38] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2148,11 +2071,9 @@ type FormatStorageResponse struct { func (x *FormatStorageResponse) Reset() { *x = FormatStorageResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[39] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FormatStorageResponse) String() string { @@ -2163,7 +2084,7 @@ func (*FormatStorageResponse) ProtoMessage() {} func (x *FormatStorageResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[39] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2195,11 +2116,9 @@ type SelectCameraResponse struct { func (x *SelectCameraResponse) Reset() { *x = SelectCameraResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[40] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SelectCameraResponse) String() string { @@ -2210,7 +2129,7 @@ func (*SelectCameraResponse) ProtoMessage() {} func (x *SelectCameraResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[40] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2242,11 +2161,9 @@ type SelectCameraRequest struct { func (x *SelectCameraRequest) Reset() { *x = SelectCameraRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[41] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SelectCameraRequest) String() string { @@ -2257,7 +2174,7 @@ func (*SelectCameraRequest) ProtoMessage() {} func (x *SelectCameraRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[41] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2287,11 +2204,9 @@ type ResetSettingsRequest struct { func (x *ResetSettingsRequest) Reset() { *x = ResetSettingsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[42] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ResetSettingsRequest) String() string { @@ -2302,7 +2217,7 @@ func (*ResetSettingsRequest) ProtoMessage() {} func (x *ResetSettingsRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[42] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2327,11 +2242,9 @@ type ResetSettingsResponse struct { func (x *ResetSettingsResponse) Reset() { *x = ResetSettingsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[43] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ResetSettingsResponse) String() string { @@ -2342,7 +2255,7 @@ func (*ResetSettingsResponse) ProtoMessage() {} func (x *ResetSettingsResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[43] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2372,11 +2285,9 @@ type ZoomInStartRequest struct { func (x *ZoomInStartRequest) Reset() { *x = ZoomInStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[44] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomInStartRequest) String() string { @@ -2387,7 +2298,7 @@ func (*ZoomInStartRequest) ProtoMessage() {} func (x *ZoomInStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[44] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2412,11 +2323,9 @@ type ZoomInStartResponse struct { func (x *ZoomInStartResponse) Reset() { *x = ZoomInStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[45] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[45] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomInStartResponse) String() string { @@ -2427,7 +2336,7 @@ func (*ZoomInStartResponse) ProtoMessage() {} func (x *ZoomInStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[45] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2457,11 +2366,9 @@ type ZoomOutStartRequest struct { func (x *ZoomOutStartRequest) Reset() { *x = ZoomOutStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[46] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[46] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomOutStartRequest) String() string { @@ -2472,7 +2379,7 @@ func (*ZoomOutStartRequest) ProtoMessage() {} func (x *ZoomOutStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[46] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2497,11 +2404,9 @@ type ZoomOutStartResponse struct { func (x *ZoomOutStartResponse) Reset() { *x = ZoomOutStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[47] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[47] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomOutStartResponse) String() string { @@ -2512,7 +2417,7 @@ func (*ZoomOutStartResponse) ProtoMessage() {} func (x *ZoomOutStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[47] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2542,11 +2447,9 @@ type ZoomStopRequest struct { func (x *ZoomStopRequest) Reset() { *x = ZoomStopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[48] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[48] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomStopRequest) String() string { @@ -2557,7 +2460,7 @@ func (*ZoomStopRequest) ProtoMessage() {} func (x *ZoomStopRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[48] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2582,11 +2485,9 @@ type ZoomStopResponse struct { func (x *ZoomStopResponse) Reset() { *x = ZoomStopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[49] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[49] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomStopResponse) String() string { @@ -2597,7 +2498,7 @@ func (*ZoomStopResponse) ProtoMessage() {} func (x *ZoomStopResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[49] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2629,11 +2530,9 @@ type ZoomRangeRequest struct { func (x *ZoomRangeRequest) Reset() { *x = ZoomRangeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[50] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[50] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomRangeRequest) String() string { @@ -2644,7 +2543,7 @@ func (*ZoomRangeRequest) ProtoMessage() {} func (x *ZoomRangeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[50] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2676,11 +2575,9 @@ type ZoomRangeResponse struct { func (x *ZoomRangeResponse) Reset() { *x = ZoomRangeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[51] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[51] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomRangeResponse) String() string { @@ -2691,7 +2588,7 @@ func (*ZoomRangeResponse) ProtoMessage() {} func (x *ZoomRangeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[51] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2725,11 +2622,9 @@ type TrackPointRequest struct { func (x *TrackPointRequest) Reset() { *x = TrackPointRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[52] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[52] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackPointRequest) String() string { @@ -2740,7 +2635,7 @@ func (*TrackPointRequest) ProtoMessage() {} func (x *TrackPointRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[52] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2786,11 +2681,9 @@ type TrackPointResponse struct { func (x *TrackPointResponse) Reset() { *x = TrackPointResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[53] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[53] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackPointResponse) String() string { @@ -2801,7 +2694,7 @@ func (*TrackPointResponse) ProtoMessage() {} func (x *TrackPointResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[53] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2836,11 +2729,9 @@ type TrackRectangleRequest struct { func (x *TrackRectangleRequest) Reset() { *x = TrackRectangleRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[54] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[54] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackRectangleRequest) String() string { @@ -2851,7 +2742,7 @@ func (*TrackRectangleRequest) ProtoMessage() {} func (x *TrackRectangleRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[54] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2904,11 +2795,9 @@ type TrackRectangleResponse struct { func (x *TrackRectangleResponse) Reset() { *x = TrackRectangleResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[55] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[55] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackRectangleResponse) String() string { @@ -2919,7 +2808,7 @@ func (*TrackRectangleResponse) ProtoMessage() {} func (x *TrackRectangleResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[55] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2949,11 +2838,9 @@ type TrackStopRequest struct { func (x *TrackStopRequest) Reset() { *x = TrackStopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[56] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[56] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackStopRequest) String() string { @@ -2964,7 +2851,7 @@ func (*TrackStopRequest) ProtoMessage() {} func (x *TrackStopRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[56] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2989,11 +2876,9 @@ type TrackStopResponse struct { func (x *TrackStopResponse) Reset() { *x = TrackStopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[57] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[57] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackStopResponse) String() string { @@ -3004,7 +2889,7 @@ func (*TrackStopResponse) ProtoMessage() {} func (x *TrackStopResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[57] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3034,11 +2919,9 @@ type FocusInStartRequest struct { func (x *FocusInStartRequest) Reset() { *x = FocusInStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[58] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[58] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusInStartRequest) String() string { @@ -3049,7 +2932,7 @@ func (*FocusInStartRequest) ProtoMessage() {} func (x *FocusInStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[58] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3074,11 +2957,9 @@ type FocusInStartResponse struct { func (x *FocusInStartResponse) Reset() { *x = FocusInStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[59] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[59] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusInStartResponse) String() string { @@ -3089,7 +2970,7 @@ func (*FocusInStartResponse) ProtoMessage() {} func (x *FocusInStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[59] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3119,11 +3000,9 @@ type FocusOutStartRequest struct { func (x *FocusOutStartRequest) Reset() { *x = FocusOutStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[60] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[60] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusOutStartRequest) String() string { @@ -3134,7 +3013,7 @@ func (*FocusOutStartRequest) ProtoMessage() {} func (x *FocusOutStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[60] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3159,11 +3038,9 @@ type FocusOutStartResponse struct { func (x *FocusOutStartResponse) Reset() { *x = FocusOutStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[61] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[61] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusOutStartResponse) String() string { @@ -3174,7 +3051,7 @@ func (*FocusOutStartResponse) ProtoMessage() {} func (x *FocusOutStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[61] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3204,11 +3081,9 @@ type FocusStopRequest struct { func (x *FocusStopRequest) Reset() { *x = FocusStopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[62] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[62] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusStopRequest) String() string { @@ -3219,7 +3094,7 @@ func (*FocusStopRequest) ProtoMessage() {} func (x *FocusStopRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[62] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3244,11 +3119,9 @@ type FocusStopResponse struct { func (x *FocusStopResponse) Reset() { *x = FocusStopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[63] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[63] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusStopResponse) String() string { @@ -3259,7 +3132,7 @@ func (*FocusStopResponse) ProtoMessage() {} func (x *FocusStopResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[63] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3291,11 +3164,9 @@ type FocusRangeRequest struct { func (x *FocusRangeRequest) Reset() { *x = FocusRangeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[64] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[64] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusRangeRequest) String() string { @@ -3306,7 +3177,7 @@ func (*FocusRangeRequest) ProtoMessage() {} func (x *FocusRangeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[64] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3338,11 +3209,9 @@ type FocusRangeResponse struct { func (x *FocusRangeResponse) Reset() { *x = FocusRangeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[65] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[65] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FocusRangeResponse) String() string { @@ -3353,7 +3222,7 @@ func (*FocusRangeResponse) ProtoMessage() {} func (x *FocusRangeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[65] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3387,11 +3256,9 @@ type CameraResult struct { func (x *CameraResult) Reset() { *x = CameraResult{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[66] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[66] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CameraResult) String() string { @@ -3402,7 +3269,7 @@ func (*CameraResult) ProtoMessage() {} func (x *CameraResult) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[66] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3445,11 +3312,9 @@ type Position struct { func (x *Position) Reset() { *x = Position{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[67] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[67] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Position) String() string { @@ -3460,7 +3325,7 @@ func (*Position) ProtoMessage() {} func (x *Position) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[67] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3524,11 +3389,9 @@ type Quaternion struct { func (x *Quaternion) Reset() { *x = Quaternion{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[68] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[68] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Quaternion) String() string { @@ -3539,7 +3402,7 @@ func (*Quaternion) ProtoMessage() {} func (x *Quaternion) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[68] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3600,11 +3463,9 @@ type EulerAngle struct { func (x *EulerAngle) Reset() { *x = EulerAngle{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[69] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[69] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *EulerAngle) String() string { @@ -3615,7 +3476,7 @@ func (*EulerAngle) ProtoMessage() {} func (x *EulerAngle) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[69] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3668,11 +3529,9 @@ type CaptureInfo struct { func (x *CaptureInfo) Reset() { *x = CaptureInfo{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[70] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[70] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CaptureInfo) String() string { @@ -3683,7 +3542,7 @@ func (*CaptureInfo) ProtoMessage() {} func (x *CaptureInfo) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[70] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3764,11 +3623,9 @@ type VideoStreamSettings struct { func (x *VideoStreamSettings) Reset() { *x = VideoStreamSettings{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[71] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[71] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VideoStreamSettings) String() string { @@ -3779,7 +3636,7 @@ func (*VideoStreamSettings) ProtoMessage() {} func (x *VideoStreamSettings) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[71] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3856,11 +3713,9 @@ type VideoStreamInfo struct { func (x *VideoStreamInfo) Reset() { *x = VideoStreamInfo{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[72] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[72] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VideoStreamInfo) String() string { @@ -3871,7 +3726,7 @@ func (*VideoStreamInfo) ProtoMessage() {} func (x *VideoStreamInfo) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[72] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3927,11 +3782,9 @@ type Status struct { func (x *Status) Reset() { *x = Status{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[73] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[73] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Status) String() string { @@ -3942,7 +3795,7 @@ func (*Status) ProtoMessage() {} func (x *Status) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[73] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4039,11 +3892,9 @@ type Option struct { func (x *Option) Reset() { *x = Option{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[74] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[74] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Option) String() string { @@ -4054,7 +3905,7 @@ func (*Option) ProtoMessage() {} func (x *Option) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[74] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4097,11 +3948,9 @@ type Setting struct { func (x *Setting) Reset() { *x = Setting{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[75] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[75] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Setting) String() string { @@ -4112,7 +3961,7 @@ func (*Setting) ProtoMessage() {} func (x *Setting) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[75] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4169,11 +4018,9 @@ type SettingOptions struct { func (x *SettingOptions) Reset() { *x = SettingOptions{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[76] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[76] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SettingOptions) String() string { @@ -4184,7 +4031,7 @@ func (*SettingOptions) ProtoMessage() {} func (x *SettingOptions) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[76] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4244,11 +4091,9 @@ type Information struct { func (x *Information) Reset() { *x = Information{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_proto_msgTypes[77] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_proto_msgTypes[77] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Information) String() string { @@ -4259,7 +4104,7 @@ func (*Information) ProtoMessage() {} func (x *Information) ProtoReflect() protoreflect.Message { mi := &file_camera_proto_msgTypes[77] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5287,945 +5132,6 @@ func file_camera_proto_init() { if File_camera_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_camera_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*PrepareRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*PrepareResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*TakePhotoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*TakePhotoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*StartPhotoIntervalRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*StartPhotoIntervalResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*StopPhotoIntervalRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*StopPhotoIntervalResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*StartVideoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*StartVideoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*StopVideoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*StopVideoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*StartVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*StartVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*StopVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*StopVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*SetModeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*SetModeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*ListPhotosRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*ListPhotosResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeInformationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*InformationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeModeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*ModeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeVideoStreamInfoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*VideoStreamInfoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCaptureInfoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*CaptureInfoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*StatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCurrentSettingsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*CurrentSettingsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*SubscribePossibleSettingOptionsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*PossibleSettingOptionsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[34].Exporter = func(v any, i int) any { - switch v := v.(*SetSettingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[35].Exporter = func(v any, i int) any { - switch v := v.(*SetSettingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[36].Exporter = func(v any, i int) any { - switch v := v.(*GetSettingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[37].Exporter = func(v any, i int) any { - switch v := v.(*GetSettingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[38].Exporter = func(v any, i int) any { - switch v := v.(*FormatStorageRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[39].Exporter = func(v any, i int) any { - switch v := v.(*FormatStorageResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[40].Exporter = func(v any, i int) any { - switch v := v.(*SelectCameraResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[41].Exporter = func(v any, i int) any { - switch v := v.(*SelectCameraRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[42].Exporter = func(v any, i int) any { - switch v := v.(*ResetSettingsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[43].Exporter = func(v any, i int) any { - switch v := v.(*ResetSettingsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[44].Exporter = func(v any, i int) any { - switch v := v.(*ZoomInStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[45].Exporter = func(v any, i int) any { - switch v := v.(*ZoomInStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[46].Exporter = func(v any, i int) any { - switch v := v.(*ZoomOutStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[47].Exporter = func(v any, i int) any { - switch v := v.(*ZoomOutStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[48].Exporter = func(v any, i int) any { - switch v := v.(*ZoomStopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[49].Exporter = func(v any, i int) any { - switch v := v.(*ZoomStopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[50].Exporter = func(v any, i int) any { - switch v := v.(*ZoomRangeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[51].Exporter = func(v any, i int) any { - switch v := v.(*ZoomRangeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[52].Exporter = func(v any, i int) any { - switch v := v.(*TrackPointRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[53].Exporter = func(v any, i int) any { - switch v := v.(*TrackPointResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[54].Exporter = func(v any, i int) any { - switch v := v.(*TrackRectangleRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[55].Exporter = func(v any, i int) any { - switch v := v.(*TrackRectangleResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[56].Exporter = func(v any, i int) any { - switch v := v.(*TrackStopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[57].Exporter = func(v any, i int) any { - switch v := v.(*TrackStopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[58].Exporter = func(v any, i int) any { - switch v := v.(*FocusInStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[59].Exporter = func(v any, i int) any { - switch v := v.(*FocusInStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[60].Exporter = func(v any, i int) any { - switch v := v.(*FocusOutStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[61].Exporter = func(v any, i int) any { - switch v := v.(*FocusOutStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[62].Exporter = func(v any, i int) any { - switch v := v.(*FocusStopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[63].Exporter = func(v any, i int) any { - switch v := v.(*FocusStopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[64].Exporter = func(v any, i int) any { - switch v := v.(*FocusRangeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[65].Exporter = func(v any, i int) any { - switch v := v.(*FocusRangeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[66].Exporter = func(v any, i int) any { - switch v := v.(*CameraResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[67].Exporter = func(v any, i int) any { - switch v := v.(*Position); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[68].Exporter = func(v any, i int) any { - switch v := v.(*Quaternion); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[69].Exporter = func(v any, i int) any { - switch v := v.(*EulerAngle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[70].Exporter = func(v any, i int) any { - switch v := v.(*CaptureInfo); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[71].Exporter = func(v any, i int) any { - switch v := v.(*VideoStreamSettings); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[72].Exporter = func(v any, i int) any { - switch v := v.(*VideoStreamInfo); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[73].Exporter = func(v any, i int) any { - switch v := v.(*Status); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[74].Exporter = func(v any, i int) any { - switch v := v.(*Option); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[75].Exporter = func(v any, i int) any { - switch v := v.(*Setting); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[76].Exporter = func(v any, i int) any { - switch v := v.(*SettingOptions); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_proto_msgTypes[77].Exporter = func(v any, i int) any { - switch v := v.(*Information); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/camera/camera_grpc.pb.go b/Sources/camera/camera_grpc.pb.go index 98fe98c..d0ce485 100644 --- a/Sources/camera/camera_grpc.pb.go +++ b/Sources/camera/camera_grpc.pb.go @@ -8,6 +8,7 @@ package camera import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/camera_server/camera_server.go b/Sources/camera_server/camera_server.go index cb6b384..312f30c 100644 --- a/Sources/camera_server/camera_server.go +++ b/Sources/camera_server/camera_server.go @@ -2,11 +2,11 @@ package camera_server import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,21 +14,16 @@ type ServiceImpl struct { } /* - Sets the camera information. This must be called as soon as the camera server is created. - - Parameters - ---------- - information *Information - - - +SetInformation Sets the camera information. This must be called as soon as the camera server is created. */ +func (s *ServiceImpl) SetInformation( + ctx context.Context, + information *Information, -func (s *ServiceImpl) SetInformation(ctx context.Context, information *Information) (*SetInformationResponse, error) { - - request := &SetInformationRequest{} - request.Information = information - +) (*SetInformationResponse, error) { + request := &SetInformationRequest{ + Information: information, + } response, err := s.Client.SetInformation(ctx, request) if err != nil { return nil, err @@ -37,21 +32,16 @@ func (s *ServiceImpl) SetInformation(ctx context.Context, information *Informati } /* - Sets video streaming settings. - - Parameters - ---------- - videoStreaming *VideoStreaming - - - +SetVideoStreaming Sets video streaming settings. */ +func (s *ServiceImpl) SetVideoStreaming( + ctx context.Context, + videoStreaming *VideoStreaming, -func (s *ServiceImpl) SetVideoStreaming(ctx context.Context, videoStreaming *VideoStreaming) (*SetVideoStreamingResponse, error) { - - request := &SetVideoStreamingRequest{} - request.VideoStreaming = videoStreaming - +) (*SetVideoStreamingResponse, error) { + request := &SetVideoStreamingRequest{ + VideoStreaming: videoStreaming, + } response, err := s.Client.SetVideoStreaming(ctx, request) if err != nil { return nil, err @@ -60,19 +50,16 @@ func (s *ServiceImpl) SetVideoStreaming(ctx context.Context, videoStreaming *Vid } /* - Sets image capture in progress status flags. This should be set to true when the camera is busy taking a photo and false when it is done. - - Parameters - ---------- - inProgress bool - - +SetInProgress Sets image capture in progress status flags. This should be set to true when the camera is busy taking a photo and false when it is done. */ +func (s *ServiceImpl) SetInProgress( + ctx context.Context, + inProgress bool, -func (s *ServiceImpl) SetInProgress(ctx context.Context, inProgress bool) (*SetInProgressResponse, error) { - - request := &SetInProgressRequest{} - request.InProgress = inProgress +) (*SetInProgressResponse, error) { + request := &SetInProgressRequest{ + InProgress: inProgress, + } response, err := s.Client.SetInProgress(ctx, request) if err != nil { return nil, err @@ -81,12 +68,12 @@ func (s *ServiceImpl) SetInProgress(ctx context.Context, inProgress bool) (*SetI } /* - Subscribe to image capture requests. Each request received should respond to using RespondTakePhoto. - - +TakePhoto Subscribe to image capture requests. Each request received should respond to using RespondTakePhoto. */ +func (a *ServiceImpl) TakePhoto( + ctx context.Context, -func (a *ServiceImpl) TakePhoto(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeTakePhotoRequest{} stream, err := a.Client.SubscribeTakePhoto(ctx, request) @@ -105,8 +92,7 @@ func (a *ServiceImpl) TakePhoto(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive TakePhoto messages, err: %v\n", err) - break + log.Fatalf("Unable to receive TakePhoto messages, err: %v", err) } ch <- m.GetIndex() } @@ -115,25 +101,19 @@ func (a *ServiceImpl) TakePhoto(ctx context.Context) (<-chan int32, error) { } /* - Respond to an image capture request from SubscribeTakePhoto. - - Parameters - ---------- - takePhotoFeedback *CameraFeedback - - - captureInfo *CaptureInfo - - - +RespondTakePhoto Respond to an image capture request from SubscribeTakePhoto. */ +func (s *ServiceImpl) RespondTakePhoto( + ctx context.Context, + takePhotoFeedback *CameraFeedback, -func (s *ServiceImpl) RespondTakePhoto(ctx context.Context, takePhotoFeedback *CameraFeedback, captureInfo *CaptureInfo) (*RespondTakePhotoResponse, error) { - - request := &RespondTakePhotoRequest{} - request.TakePhotoFeedback = *takePhotoFeedback - request.CaptureInfo = captureInfo + captureInfo *CaptureInfo, +) (*RespondTakePhotoResponse, error) { + request := &RespondTakePhotoRequest{ + TakePhotoFeedback: *takePhotoFeedback, + CaptureInfo: captureInfo, + } response, err := s.Client.RespondTakePhoto(ctx, request) if err != nil { return nil, err @@ -142,12 +122,12 @@ func (s *ServiceImpl) RespondTakePhoto(ctx context.Context, takePhotoFeedback *C } /* - Subscribe to start video requests. Each request received should respond to using RespondStartVideo - - +StartVideo Subscribe to start video requests. Each request received should respond to using RespondStartVideo */ +func (a *ServiceImpl) StartVideo( + ctx context.Context, -func (a *ServiceImpl) StartVideo(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeStartVideoRequest{} stream, err := a.Client.SubscribeStartVideo(ctx, request) @@ -166,8 +146,7 @@ func (a *ServiceImpl) StartVideo(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive StartVideo messages, err: %v\n", err) - break + log.Fatalf("Unable to receive StartVideo messages, err: %v", err) } ch <- m.GetStreamId() } @@ -176,20 +155,16 @@ func (a *ServiceImpl) StartVideo(ctx context.Context) (<-chan int32, error) { } /* - Subscribe to stop video requests. Each request received should respond using StopVideoResponse - - Parameters - ---------- - startVideoFeedback *CameraFeedback - - - +RespondStartVideo Subscribe to stop video requests. Each request received should respond using StopVideoResponse */ +func (s *ServiceImpl) RespondStartVideo( + ctx context.Context, + startVideoFeedback *CameraFeedback, -func (s *ServiceImpl) RespondStartVideo(ctx context.Context, startVideoFeedback *CameraFeedback) (*RespondStartVideoResponse, error) { - - request := &RespondStartVideoRequest{} - request.StartVideoFeedback = *startVideoFeedback +) (*RespondStartVideoResponse, error) { + request := &RespondStartVideoRequest{ + StartVideoFeedback: *startVideoFeedback, + } response, err := s.Client.RespondStartVideo(ctx, request) if err != nil { return nil, err @@ -198,12 +173,12 @@ func (s *ServiceImpl) RespondStartVideo(ctx context.Context, startVideoFeedback } /* - Subscribe to stop video requests. Each request received should response to using RespondStopVideo - - +StopVideo Subscribe to stop video requests. Each request received should response to using RespondStopVideo */ +func (a *ServiceImpl) StopVideo( + ctx context.Context, -func (a *ServiceImpl) StopVideo(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeStopVideoRequest{} stream, err := a.Client.SubscribeStopVideo(ctx, request) @@ -222,8 +197,7 @@ func (a *ServiceImpl) StopVideo(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive StopVideo messages, err: %v\n", err) - break + log.Fatalf("Unable to receive StopVideo messages, err: %v", err) } ch <- m.GetStreamId() } @@ -232,20 +206,16 @@ func (a *ServiceImpl) StopVideo(ctx context.Context) (<-chan int32, error) { } /* - Respond to stop video request from SubscribeStopVideo. - - Parameters - ---------- - stopVideoFeedback *CameraFeedback - - - +RespondStopVideo Respond to stop video request from SubscribeStopVideo. */ +func (s *ServiceImpl) RespondStopVideo( + ctx context.Context, + stopVideoFeedback *CameraFeedback, -func (s *ServiceImpl) RespondStopVideo(ctx context.Context, stopVideoFeedback *CameraFeedback) (*RespondStopVideoResponse, error) { - - request := &RespondStopVideoRequest{} - request.StopVideoFeedback = *stopVideoFeedback +) (*RespondStopVideoResponse, error) { + request := &RespondStopVideoRequest{ + StopVideoFeedback: *stopVideoFeedback, + } response, err := s.Client.RespondStopVideo(ctx, request) if err != nil { return nil, err @@ -254,12 +224,12 @@ func (s *ServiceImpl) RespondStopVideo(ctx context.Context, stopVideoFeedback *C } /* - Subscribe to start video streaming requests. Each request received should response to using RespondStartVideoStreaming - - +StartVideoStreaming Subscribe to start video streaming requests. Each request received should response to using RespondStartVideoStreaming */ +func (a *ServiceImpl) StartVideoStreaming( + ctx context.Context, -func (a *ServiceImpl) StartVideoStreaming(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeStartVideoStreamingRequest{} stream, err := a.Client.SubscribeStartVideoStreaming(ctx, request) @@ -278,8 +248,7 @@ func (a *ServiceImpl) StartVideoStreaming(ctx context.Context) (<-chan int32, er if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive StartVideoStreaming messages, err: %v\n", err) - break + log.Fatalf("Unable to receive StartVideoStreaming messages, err: %v", err) } ch <- m.GetStreamId() } @@ -288,20 +257,16 @@ func (a *ServiceImpl) StartVideoStreaming(ctx context.Context) (<-chan int32, er } /* - Respond to start video streaming from SubscribeStartVideoStreaming. - - Parameters - ---------- - startVideoStreamingFeedback *CameraFeedback - - - +RespondStartVideoStreaming Respond to start video streaming from SubscribeStartVideoStreaming. */ +func (s *ServiceImpl) RespondStartVideoStreaming( + ctx context.Context, + startVideoStreamingFeedback *CameraFeedback, -func (s *ServiceImpl) RespondStartVideoStreaming(ctx context.Context, startVideoStreamingFeedback *CameraFeedback) (*RespondStartVideoStreamingResponse, error) { - - request := &RespondStartVideoStreamingRequest{} - request.StartVideoStreamingFeedback = *startVideoStreamingFeedback +) (*RespondStartVideoStreamingResponse, error) { + request := &RespondStartVideoStreamingRequest{ + StartVideoStreamingFeedback: *startVideoStreamingFeedback, + } response, err := s.Client.RespondStartVideoStreaming(ctx, request) if err != nil { return nil, err @@ -310,12 +275,12 @@ func (s *ServiceImpl) RespondStartVideoStreaming(ctx context.Context, startVideo } /* - Subscribe to stop video streaming requests. Each request received should response to using RespondStopVideoStreaming - - +StopVideoStreaming Subscribe to stop video streaming requests. Each request received should response to using RespondStopVideoStreaming */ +func (a *ServiceImpl) StopVideoStreaming( + ctx context.Context, -func (a *ServiceImpl) StopVideoStreaming(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeStopVideoStreamingRequest{} stream, err := a.Client.SubscribeStopVideoStreaming(ctx, request) @@ -334,8 +299,7 @@ func (a *ServiceImpl) StopVideoStreaming(ctx context.Context) (<-chan int32, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive StopVideoStreaming messages, err: %v\n", err) - break + log.Fatalf("Unable to receive StopVideoStreaming messages, err: %v", err) } ch <- m.GetStreamId() } @@ -344,20 +308,16 @@ func (a *ServiceImpl) StopVideoStreaming(ctx context.Context) (<-chan int32, err } /* - Respond to stop video streaming from SubscribeStopVideoStreaming. - - Parameters - ---------- - stopVideoStreamingFeedback *CameraFeedback - - - +RespondStopVideoStreaming Respond to stop video streaming from SubscribeStopVideoStreaming. */ +func (s *ServiceImpl) RespondStopVideoStreaming( + ctx context.Context, + stopVideoStreamingFeedback *CameraFeedback, -func (s *ServiceImpl) RespondStopVideoStreaming(ctx context.Context, stopVideoStreamingFeedback *CameraFeedback) (*RespondStopVideoStreamingResponse, error) { - - request := &RespondStopVideoStreamingRequest{} - request.StopVideoStreamingFeedback = *stopVideoStreamingFeedback +) (*RespondStopVideoStreamingResponse, error) { + request := &RespondStopVideoStreamingRequest{ + StopVideoStreamingFeedback: *stopVideoStreamingFeedback, + } response, err := s.Client.RespondStopVideoStreaming(ctx, request) if err != nil { return nil, err @@ -366,12 +326,12 @@ func (s *ServiceImpl) RespondStopVideoStreaming(ctx context.Context, stopVideoSt } /* - Subscribe to set camera mode requests. Each request received should response to using RespondSetMode - - +SetMode Subscribe to set camera mode requests. Each request received should response to using RespondSetMode */ +func (a *ServiceImpl) SetMode( + ctx context.Context, -func (a *ServiceImpl) SetMode(ctx context.Context) (<-chan Mode, error) { +) (<-chan Mode, error) { ch := make(chan Mode) request := &SubscribeSetModeRequest{} stream, err := a.Client.SubscribeSetMode(ctx, request) @@ -390,8 +350,7 @@ func (a *ServiceImpl) SetMode(ctx context.Context) (<-chan Mode, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive SetMode messages, err: %v\n", err) - break + log.Fatalf("Unable to receive SetMode messages, err: %v", err) } ch <- m.GetMode() } @@ -400,20 +359,16 @@ func (a *ServiceImpl) SetMode(ctx context.Context) (<-chan Mode, error) { } /* - Respond to set camera mode from SubscribeSetMode. - - Parameters - ---------- - setModeFeedback *CameraFeedback - - - +RespondSetMode Respond to set camera mode from SubscribeSetMode. */ +func (s *ServiceImpl) RespondSetMode( + ctx context.Context, + setModeFeedback *CameraFeedback, -func (s *ServiceImpl) RespondSetMode(ctx context.Context, setModeFeedback *CameraFeedback) (*RespondSetModeResponse, error) { - - request := &RespondSetModeRequest{} - request.SetModeFeedback = *setModeFeedback +) (*RespondSetModeResponse, error) { + request := &RespondSetModeRequest{ + SetModeFeedback: *setModeFeedback, + } response, err := s.Client.RespondSetMode(ctx, request) if err != nil { return nil, err @@ -422,12 +377,12 @@ func (s *ServiceImpl) RespondSetMode(ctx context.Context, setModeFeedback *Camer } /* - Subscribe to camera storage information requests. Each request received should response to using RespondStorageInformation - - +StorageInformation Subscribe to camera storage information requests. Each request received should response to using RespondStorageInformation */ +func (a *ServiceImpl) StorageInformation( + ctx context.Context, -func (a *ServiceImpl) StorageInformation(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeStorageInformationRequest{} stream, err := a.Client.SubscribeStorageInformation(ctx, request) @@ -446,8 +401,7 @@ func (a *ServiceImpl) StorageInformation(ctx context.Context) (<-chan int32, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive StorageInformation messages, err: %v\n", err) - break + log.Fatalf("Unable to receive StorageInformation messages, err: %v", err) } ch <- m.GetStorageId() } @@ -456,25 +410,19 @@ func (a *ServiceImpl) StorageInformation(ctx context.Context) (<-chan int32, err } /* - Respond to camera storage information from SubscribeStorageInformation. - - Parameters - ---------- - storageInformationFeedback *CameraFeedback - - - storageInformation *StorageInformation - - - +RespondStorageInformation Respond to camera storage information from SubscribeStorageInformation. */ +func (s *ServiceImpl) RespondStorageInformation( + ctx context.Context, + storageInformationFeedback *CameraFeedback, -func (s *ServiceImpl) RespondStorageInformation(ctx context.Context, storageInformationFeedback *CameraFeedback, storageInformation *StorageInformation) (*RespondStorageInformationResponse, error) { - - request := &RespondStorageInformationRequest{} - request.StorageInformationFeedback = *storageInformationFeedback - request.StorageInformation = storageInformation + storageInformation *StorageInformation, +) (*RespondStorageInformationResponse, error) { + request := &RespondStorageInformationRequest{ + StorageInformationFeedback: *storageInformationFeedback, + StorageInformation: storageInformation, + } response, err := s.Client.RespondStorageInformation(ctx, request) if err != nil { return nil, err @@ -483,12 +431,12 @@ func (s *ServiceImpl) RespondStorageInformation(ctx context.Context, storageInfo } /* - Subscribe to camera capture status requests. Each request received should response to using RespondCaptureStatus - - +CaptureStatus Subscribe to camera capture status requests. Each request received should response to using RespondCaptureStatus */ +func (a *ServiceImpl) CaptureStatus( + ctx context.Context, -func (a *ServiceImpl) CaptureStatus(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeCaptureStatusRequest{} stream, err := a.Client.SubscribeCaptureStatus(ctx, request) @@ -507,8 +455,7 @@ func (a *ServiceImpl) CaptureStatus(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CaptureStatus messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CaptureStatus messages, err: %v", err) } ch <- m.GetReserved() } @@ -517,25 +464,19 @@ func (a *ServiceImpl) CaptureStatus(ctx context.Context) (<-chan int32, error) { } /* - Respond to camera capture status from SubscribeCaptureStatus. - - Parameters - ---------- - captureStatusFeedback *CameraFeedback - - - captureStatus *CaptureStatus - - - +RespondCaptureStatus Respond to camera capture status from SubscribeCaptureStatus. */ +func (s *ServiceImpl) RespondCaptureStatus( + ctx context.Context, + captureStatusFeedback *CameraFeedback, -func (s *ServiceImpl) RespondCaptureStatus(ctx context.Context, captureStatusFeedback *CameraFeedback, captureStatus *CaptureStatus) (*RespondCaptureStatusResponse, error) { - - request := &RespondCaptureStatusRequest{} - request.CaptureStatusFeedback = *captureStatusFeedback - request.CaptureStatus = captureStatus + captureStatus *CaptureStatus, +) (*RespondCaptureStatusResponse, error) { + request := &RespondCaptureStatusRequest{ + CaptureStatusFeedback: *captureStatusFeedback, + CaptureStatus: captureStatus, + } response, err := s.Client.RespondCaptureStatus(ctx, request) if err != nil { return nil, err @@ -544,12 +485,12 @@ func (s *ServiceImpl) RespondCaptureStatus(ctx context.Context, captureStatusFee } /* - Subscribe to format storage requests. Each request received should response to using RespondFormatStorage - - +FormatStorage Subscribe to format storage requests. Each request received should response to using RespondFormatStorage */ +func (a *ServiceImpl) FormatStorage( + ctx context.Context, -func (a *ServiceImpl) FormatStorage(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeFormatStorageRequest{} stream, err := a.Client.SubscribeFormatStorage(ctx, request) @@ -568,8 +509,7 @@ func (a *ServiceImpl) FormatStorage(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive FormatStorage messages, err: %v\n", err) - break + log.Fatalf("Unable to receive FormatStorage messages, err: %v", err) } ch <- m.GetStorageId() } @@ -578,20 +518,16 @@ func (a *ServiceImpl) FormatStorage(ctx context.Context) (<-chan int32, error) { } /* - Respond to format storage from SubscribeFormatStorage. - - Parameters - ---------- - formatStorageFeedback *CameraFeedback - - - +RespondFormatStorage Respond to format storage from SubscribeFormatStorage. */ +func (s *ServiceImpl) RespondFormatStorage( + ctx context.Context, + formatStorageFeedback *CameraFeedback, -func (s *ServiceImpl) RespondFormatStorage(ctx context.Context, formatStorageFeedback *CameraFeedback) (*RespondFormatStorageResponse, error) { - - request := &RespondFormatStorageRequest{} - request.FormatStorageFeedback = *formatStorageFeedback +) (*RespondFormatStorageResponse, error) { + request := &RespondFormatStorageRequest{ + FormatStorageFeedback: *formatStorageFeedback, + } response, err := s.Client.RespondFormatStorage(ctx, request) if err != nil { return nil, err @@ -600,12 +536,12 @@ func (s *ServiceImpl) RespondFormatStorage(ctx context.Context, formatStorageFee } /* - Subscribe to reset settings requests. Each request received should response to using RespondResetSettings - - +ResetSettings Subscribe to reset settings requests. Each request received should response to using RespondResetSettings */ +func (a *ServiceImpl) ResetSettings( + ctx context.Context, -func (a *ServiceImpl) ResetSettings(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeResetSettingsRequest{} stream, err := a.Client.SubscribeResetSettings(ctx, request) @@ -624,8 +560,7 @@ func (a *ServiceImpl) ResetSettings(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ResetSettings messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ResetSettings messages, err: %v", err) } ch <- m.GetReserved() } @@ -634,20 +569,16 @@ func (a *ServiceImpl) ResetSettings(ctx context.Context) (<-chan int32, error) { } /* - Respond to reset settings from SubscribeResetSettings. - - Parameters - ---------- - resetSettingsFeedback *CameraFeedback - - - +RespondResetSettings Respond to reset settings from SubscribeResetSettings. */ +func (s *ServiceImpl) RespondResetSettings( + ctx context.Context, + resetSettingsFeedback *CameraFeedback, -func (s *ServiceImpl) RespondResetSettings(ctx context.Context, resetSettingsFeedback *CameraFeedback) (*RespondResetSettingsResponse, error) { - - request := &RespondResetSettingsRequest{} - request.ResetSettingsFeedback = *resetSettingsFeedback +) (*RespondResetSettingsResponse, error) { + request := &RespondResetSettingsRequest{ + ResetSettingsFeedback: *resetSettingsFeedback, + } response, err := s.Client.RespondResetSettings(ctx, request) if err != nil { return nil, err @@ -656,12 +587,12 @@ func (s *ServiceImpl) RespondResetSettings(ctx context.Context, resetSettingsFee } /* - Subscribe to zoom in start command - - +ZoomInStart Subscribe to zoom in start command */ +func (a *ServiceImpl) ZoomInStart( + ctx context.Context, -func (a *ServiceImpl) ZoomInStart(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeZoomInStartRequest{} stream, err := a.Client.SubscribeZoomInStart(ctx, request) @@ -680,8 +611,7 @@ func (a *ServiceImpl) ZoomInStart(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ZoomInStart messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ZoomInStart messages, err: %v", err) } ch <- m.GetReserved() } @@ -690,20 +620,16 @@ func (a *ServiceImpl) ZoomInStart(ctx context.Context) (<-chan int32, error) { } /* - Respond to zoom in start. - - Parameters - ---------- - zoomInStartFeedback *CameraFeedback - - - +RespondZoomInStart Respond to zoom in start. */ +func (s *ServiceImpl) RespondZoomInStart( + ctx context.Context, + zoomInStartFeedback *CameraFeedback, -func (s *ServiceImpl) RespondZoomInStart(ctx context.Context, zoomInStartFeedback *CameraFeedback) (*RespondZoomInStartResponse, error) { - - request := &RespondZoomInStartRequest{} - request.ZoomInStartFeedback = *zoomInStartFeedback +) (*RespondZoomInStartResponse, error) { + request := &RespondZoomInStartRequest{ + ZoomInStartFeedback: *zoomInStartFeedback, + } response, err := s.Client.RespondZoomInStart(ctx, request) if err != nil { return nil, err @@ -712,12 +638,12 @@ func (s *ServiceImpl) RespondZoomInStart(ctx context.Context, zoomInStartFeedbac } /* - Subscribe to zoom out start command - - +ZoomOutStart Subscribe to zoom out start command */ +func (a *ServiceImpl) ZoomOutStart( + ctx context.Context, -func (a *ServiceImpl) ZoomOutStart(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeZoomOutStartRequest{} stream, err := a.Client.SubscribeZoomOutStart(ctx, request) @@ -736,8 +662,7 @@ func (a *ServiceImpl) ZoomOutStart(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ZoomOutStart messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ZoomOutStart messages, err: %v", err) } ch <- m.GetReserved() } @@ -746,20 +671,16 @@ func (a *ServiceImpl) ZoomOutStart(ctx context.Context) (<-chan int32, error) { } /* - Respond to zoom out start. - - Parameters - ---------- - zoomOutStartFeedback *CameraFeedback - - - +RespondZoomOutStart Respond to zoom out start. */ +func (s *ServiceImpl) RespondZoomOutStart( + ctx context.Context, + zoomOutStartFeedback *CameraFeedback, -func (s *ServiceImpl) RespondZoomOutStart(ctx context.Context, zoomOutStartFeedback *CameraFeedback) (*RespondZoomOutStartResponse, error) { - - request := &RespondZoomOutStartRequest{} - request.ZoomOutStartFeedback = *zoomOutStartFeedback +) (*RespondZoomOutStartResponse, error) { + request := &RespondZoomOutStartRequest{ + ZoomOutStartFeedback: *zoomOutStartFeedback, + } response, err := s.Client.RespondZoomOutStart(ctx, request) if err != nil { return nil, err @@ -768,12 +689,12 @@ func (s *ServiceImpl) RespondZoomOutStart(ctx context.Context, zoomOutStartFeedb } /* - Subscribe to zoom stop command - - +ZoomStop Subscribe to zoom stop command */ +func (a *ServiceImpl) ZoomStop( + ctx context.Context, -func (a *ServiceImpl) ZoomStop(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeZoomStopRequest{} stream, err := a.Client.SubscribeZoomStop(ctx, request) @@ -792,8 +713,7 @@ func (a *ServiceImpl) ZoomStop(ctx context.Context) (<-chan int32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ZoomStop messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ZoomStop messages, err: %v", err) } ch <- m.GetReserved() } @@ -802,20 +722,16 @@ func (a *ServiceImpl) ZoomStop(ctx context.Context) (<-chan int32, error) { } /* - Respond to zoom stop. - - Parameters - ---------- - zoomStopFeedback *CameraFeedback - - - +RespondZoomStop Respond to zoom stop. */ +func (s *ServiceImpl) RespondZoomStop( + ctx context.Context, + zoomStopFeedback *CameraFeedback, -func (s *ServiceImpl) RespondZoomStop(ctx context.Context, zoomStopFeedback *CameraFeedback) (*RespondZoomStopResponse, error) { - - request := &RespondZoomStopRequest{} - request.ZoomStopFeedback = *zoomStopFeedback +) (*RespondZoomStopResponse, error) { + request := &RespondZoomStopRequest{ + ZoomStopFeedback: *zoomStopFeedback, + } response, err := s.Client.RespondZoomStop(ctx, request) if err != nil { return nil, err @@ -824,12 +740,12 @@ func (s *ServiceImpl) RespondZoomStop(ctx context.Context, zoomStopFeedback *Cam } /* - Subscribe to zoom range command - - +ZoomRange Subscribe to zoom range command */ +func (a *ServiceImpl) ZoomRange( + ctx context.Context, -func (a *ServiceImpl) ZoomRange(ctx context.Context) (<-chan float32, error) { +) (<-chan float32, error) { ch := make(chan float32) request := &SubscribeZoomRangeRequest{} stream, err := a.Client.SubscribeZoomRange(ctx, request) @@ -848,8 +764,7 @@ func (a *ServiceImpl) ZoomRange(ctx context.Context) (<-chan float32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ZoomRange messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ZoomRange messages, err: %v", err) } ch <- m.GetFactor() } @@ -858,20 +773,16 @@ func (a *ServiceImpl) ZoomRange(ctx context.Context) (<-chan float32, error) { } /* - Respond to zoom range. - - Parameters - ---------- - zoomRangeFeedback *CameraFeedback - - - +RespondZoomRange Respond to zoom range. */ +func (s *ServiceImpl) RespondZoomRange( + ctx context.Context, + zoomRangeFeedback *CameraFeedback, -func (s *ServiceImpl) RespondZoomRange(ctx context.Context, zoomRangeFeedback *CameraFeedback) (*RespondZoomRangeResponse, error) { - - request := &RespondZoomRangeRequest{} - request.ZoomRangeFeedback = *zoomRangeFeedback +) (*RespondZoomRangeResponse, error) { + request := &RespondZoomRangeRequest{ + ZoomRangeFeedback: *zoomRangeFeedback, + } response, err := s.Client.RespondZoomRange(ctx, request) if err != nil { return nil, err @@ -880,21 +791,16 @@ func (s *ServiceImpl) RespondZoomRange(ctx context.Context, zoomRangeFeedback *C } /* - Set/update the current rectangle tracking status. - - Parameters - ---------- - trackedRectangle *TrackRectangle - - - +SetTrackingRectangleStatus Set/update the current rectangle tracking status. */ +func (s *ServiceImpl) SetTrackingRectangleStatus( + ctx context.Context, + trackedRectangle *TrackRectangle, -func (s *ServiceImpl) SetTrackingRectangleStatus(ctx context.Context, trackedRectangle *TrackRectangle) (*SetTrackingRectangleStatusResponse, error) { - - request := &SetTrackingRectangleStatusRequest{} - request.TrackedRectangle = trackedRectangle - +) (*SetTrackingRectangleStatusResponse, error) { + request := &SetTrackingRectangleStatusRequest{ + TrackedRectangle: trackedRectangle, + } response, err := s.Client.SetTrackingRectangleStatus(ctx, request) if err != nil { return nil, err @@ -903,13 +809,12 @@ func (s *ServiceImpl) SetTrackingRectangleStatus(ctx context.Context, trackedRec } /* - Set the current tracking status to off. - - +SetTrackingOffStatus Set the current tracking status to off. */ +func (s *ServiceImpl) SetTrackingOffStatus( + ctx context.Context, -func (s *ServiceImpl) SetTrackingOffStatus(ctx context.Context) (*SetTrackingOffStatusResponse, error) { - +) (*SetTrackingOffStatusResponse, error) { request := &SetTrackingOffStatusRequest{} response, err := s.Client.SetTrackingOffStatus(ctx, request) if err != nil { @@ -919,12 +824,12 @@ func (s *ServiceImpl) SetTrackingOffStatus(ctx context.Context) (*SetTrackingOff } /* - Subscribe to incoming tracking point command. - - +TrackingPointCommand Subscribe to incoming tracking point command. */ +func (a *ServiceImpl) TrackingPointCommand( + ctx context.Context, -func (a *ServiceImpl) TrackingPointCommand(ctx context.Context) (<-chan *TrackPoint, error) { +) (<-chan *TrackPoint, error) { ch := make(chan *TrackPoint) request := &SubscribeTrackingPointCommandRequest{} stream, err := a.Client.SubscribeTrackingPointCommand(ctx, request) @@ -943,8 +848,7 @@ func (a *ServiceImpl) TrackingPointCommand(ctx context.Context) (<-chan *TrackPo if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive TrackingPointCommand messages, err: %v\n", err) - break + log.Fatalf("Unable to receive TrackingPointCommand messages, err: %v", err) } ch <- m.GetTrackPoint() } @@ -953,12 +857,12 @@ func (a *ServiceImpl) TrackingPointCommand(ctx context.Context) (<-chan *TrackPo } /* - Subscribe to incoming tracking rectangle command. - - +TrackingRectangleCommand Subscribe to incoming tracking rectangle command. */ +func (a *ServiceImpl) TrackingRectangleCommand( + ctx context.Context, -func (a *ServiceImpl) TrackingRectangleCommand(ctx context.Context) (<-chan *TrackRectangle, error) { +) (<-chan *TrackRectangle, error) { ch := make(chan *TrackRectangle) request := &SubscribeTrackingRectangleCommandRequest{} stream, err := a.Client.SubscribeTrackingRectangleCommand(ctx, request) @@ -977,8 +881,7 @@ func (a *ServiceImpl) TrackingRectangleCommand(ctx context.Context) (<-chan *Tra if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive TrackingRectangleCommand messages, err: %v\n", err) - break + log.Fatalf("Unable to receive TrackingRectangleCommand messages, err: %v", err) } ch <- m.GetTrackRectangle() } @@ -987,12 +890,12 @@ func (a *ServiceImpl) TrackingRectangleCommand(ctx context.Context) (<-chan *Tra } /* - Subscribe to incoming tracking off command. - - +TrackingOffCommand Subscribe to incoming tracking off command. */ +func (a *ServiceImpl) TrackingOffCommand( + ctx context.Context, -func (a *ServiceImpl) TrackingOffCommand(ctx context.Context) (<-chan int32, error) { +) (<-chan int32, error) { ch := make(chan int32) request := &SubscribeTrackingOffCommandRequest{} stream, err := a.Client.SubscribeTrackingOffCommand(ctx, request) @@ -1011,8 +914,7 @@ func (a *ServiceImpl) TrackingOffCommand(ctx context.Context) (<-chan int32, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive TrackingOffCommand messages, err: %v\n", err) - break + log.Fatalf("Unable to receive TrackingOffCommand messages, err: %v", err) } ch <- m.GetDummy() } @@ -1021,20 +923,16 @@ func (a *ServiceImpl) TrackingOffCommand(ctx context.Context) (<-chan int32, err } /* - Respond to an incoming tracking point command. - - Parameters - ---------- - stopVideoFeedback *CameraFeedback - - - +RespondTrackingPointCommand Respond to an incoming tracking point command. */ +func (s *ServiceImpl) RespondTrackingPointCommand( + ctx context.Context, + stopVideoFeedback *CameraFeedback, -func (s *ServiceImpl) RespondTrackingPointCommand(ctx context.Context, stopVideoFeedback *CameraFeedback) (*RespondTrackingPointCommandResponse, error) { - - request := &RespondTrackingPointCommandRequest{} - request.StopVideoFeedback = *stopVideoFeedback +) (*RespondTrackingPointCommandResponse, error) { + request := &RespondTrackingPointCommandRequest{ + StopVideoFeedback: *stopVideoFeedback, + } response, err := s.Client.RespondTrackingPointCommand(ctx, request) if err != nil { return nil, err @@ -1043,20 +941,16 @@ func (s *ServiceImpl) RespondTrackingPointCommand(ctx context.Context, stopVideo } /* - Respond to an incoming tracking rectangle command. - - Parameters - ---------- - stopVideoFeedback *CameraFeedback - - - +RespondTrackingRectangleCommand Respond to an incoming tracking rectangle command. */ +func (s *ServiceImpl) RespondTrackingRectangleCommand( + ctx context.Context, + stopVideoFeedback *CameraFeedback, -func (s *ServiceImpl) RespondTrackingRectangleCommand(ctx context.Context, stopVideoFeedback *CameraFeedback) (*RespondTrackingRectangleCommandResponse, error) { - - request := &RespondTrackingRectangleCommandRequest{} - request.StopVideoFeedback = *stopVideoFeedback +) (*RespondTrackingRectangleCommandResponse, error) { + request := &RespondTrackingRectangleCommandRequest{ + StopVideoFeedback: *stopVideoFeedback, + } response, err := s.Client.RespondTrackingRectangleCommand(ctx, request) if err != nil { return nil, err @@ -1065,20 +959,16 @@ func (s *ServiceImpl) RespondTrackingRectangleCommand(ctx context.Context, stopV } /* - Respond to an incoming tracking off command. - - Parameters - ---------- - stopVideoFeedback *CameraFeedback - - - +RespondTrackingOffCommand Respond to an incoming tracking off command. */ +func (s *ServiceImpl) RespondTrackingOffCommand( + ctx context.Context, + stopVideoFeedback *CameraFeedback, -func (s *ServiceImpl) RespondTrackingOffCommand(ctx context.Context, stopVideoFeedback *CameraFeedback) (*RespondTrackingOffCommandResponse, error) { - - request := &RespondTrackingOffCommandRequest{} - request.StopVideoFeedback = *stopVideoFeedback +) (*RespondTrackingOffCommandResponse, error) { + request := &RespondTrackingOffCommandRequest{ + StopVideoFeedback: *stopVideoFeedback, + } response, err := s.Client.RespondTrackingOffCommand(ctx, request) if err != nil { return nil, err diff --git a/Sources/camera_server/camera_server.pb.go b/Sources/camera_server/camera_server.pb.go index 6a3eee8..4d721d4 100644 --- a/Sources/camera_server/camera_server.pb.go +++ b/Sources/camera_server/camera_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: camera_server.proto package camera_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -411,11 +412,9 @@ type SetInformationRequest struct { func (x *SetInformationRequest) Reset() { *x = SetInformationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetInformationRequest) String() string { @@ -426,7 +425,7 @@ func (*SetInformationRequest) ProtoMessage() {} func (x *SetInformationRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -458,11 +457,9 @@ type SetInformationResponse struct { func (x *SetInformationResponse) Reset() { *x = SetInformationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetInformationResponse) String() string { @@ -473,7 +470,7 @@ func (*SetInformationResponse) ProtoMessage() {} func (x *SetInformationResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -505,11 +502,9 @@ type SetVideoStreamingRequest struct { func (x *SetVideoStreamingRequest) Reset() { *x = SetVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVideoStreamingRequest) String() string { @@ -520,7 +515,7 @@ func (*SetVideoStreamingRequest) ProtoMessage() {} func (x *SetVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -552,11 +547,9 @@ type SetVideoStreamingResponse struct { func (x *SetVideoStreamingResponse) Reset() { *x = SetVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVideoStreamingResponse) String() string { @@ -567,7 +560,7 @@ func (*SetVideoStreamingResponse) ProtoMessage() {} func (x *SetVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -599,11 +592,9 @@ type SetInProgressRequest struct { func (x *SetInProgressRequest) Reset() { *x = SetInProgressRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetInProgressRequest) String() string { @@ -614,7 +605,7 @@ func (*SetInProgressRequest) ProtoMessage() {} func (x *SetInProgressRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -646,11 +637,9 @@ type SetInProgressResponse struct { func (x *SetInProgressResponse) Reset() { *x = SetInProgressResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetInProgressResponse) String() string { @@ -661,7 +650,7 @@ func (*SetInProgressResponse) ProtoMessage() {} func (x *SetInProgressResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -691,11 +680,9 @@ type SubscribeTakePhotoRequest struct { func (x *SubscribeTakePhotoRequest) Reset() { *x = SubscribeTakePhotoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTakePhotoRequest) String() string { @@ -706,7 +693,7 @@ func (*SubscribeTakePhotoRequest) ProtoMessage() {} func (x *SubscribeTakePhotoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -731,11 +718,9 @@ type TakePhotoResponse struct { func (x *TakePhotoResponse) Reset() { *x = TakePhotoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakePhotoResponse) String() string { @@ -746,7 +731,7 @@ func (*TakePhotoResponse) ProtoMessage() {} func (x *TakePhotoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -779,11 +764,9 @@ type RespondTakePhotoRequest struct { func (x *RespondTakePhotoRequest) Reset() { *x = RespondTakePhotoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTakePhotoRequest) String() string { @@ -794,7 +777,7 @@ func (*RespondTakePhotoRequest) ProtoMessage() {} func (x *RespondTakePhotoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -833,11 +816,9 @@ type RespondTakePhotoResponse struct { func (x *RespondTakePhotoResponse) Reset() { *x = RespondTakePhotoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTakePhotoResponse) String() string { @@ -848,7 +829,7 @@ func (*RespondTakePhotoResponse) ProtoMessage() {} func (x *RespondTakePhotoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -878,11 +859,9 @@ type SubscribeStartVideoRequest struct { func (x *SubscribeStartVideoRequest) Reset() { *x = SubscribeStartVideoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStartVideoRequest) String() string { @@ -893,7 +872,7 @@ func (*SubscribeStartVideoRequest) ProtoMessage() {} func (x *SubscribeStartVideoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -918,11 +897,9 @@ type StartVideoResponse struct { func (x *StartVideoResponse) Reset() { *x = StartVideoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartVideoResponse) String() string { @@ -933,7 +910,7 @@ func (*StartVideoResponse) ProtoMessage() {} func (x *StartVideoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -965,11 +942,9 @@ type RespondStartVideoRequest struct { func (x *RespondStartVideoRequest) Reset() { *x = RespondStartVideoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStartVideoRequest) String() string { @@ -980,7 +955,7 @@ func (*RespondStartVideoRequest) ProtoMessage() {} func (x *RespondStartVideoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1012,11 +987,9 @@ type RespondStartVideoResponse struct { func (x *RespondStartVideoResponse) Reset() { *x = RespondStartVideoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStartVideoResponse) String() string { @@ -1027,7 +1000,7 @@ func (*RespondStartVideoResponse) ProtoMessage() {} func (x *RespondStartVideoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1057,11 +1030,9 @@ type SubscribeStopVideoRequest struct { func (x *SubscribeStopVideoRequest) Reset() { *x = SubscribeStopVideoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStopVideoRequest) String() string { @@ -1072,7 +1043,7 @@ func (*SubscribeStopVideoRequest) ProtoMessage() {} func (x *SubscribeStopVideoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1097,11 +1068,9 @@ type StopVideoResponse struct { func (x *StopVideoResponse) Reset() { *x = StopVideoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopVideoResponse) String() string { @@ -1112,7 +1081,7 @@ func (*StopVideoResponse) ProtoMessage() {} func (x *StopVideoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1144,11 +1113,9 @@ type RespondStopVideoRequest struct { func (x *RespondStopVideoRequest) Reset() { *x = RespondStopVideoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStopVideoRequest) String() string { @@ -1159,7 +1126,7 @@ func (*RespondStopVideoRequest) ProtoMessage() {} func (x *RespondStopVideoRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1191,11 +1158,9 @@ type RespondStopVideoResponse struct { func (x *RespondStopVideoResponse) Reset() { *x = RespondStopVideoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStopVideoResponse) String() string { @@ -1206,7 +1171,7 @@ func (*RespondStopVideoResponse) ProtoMessage() {} func (x *RespondStopVideoResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1236,11 +1201,9 @@ type SubscribeStartVideoStreamingRequest struct { func (x *SubscribeStartVideoStreamingRequest) Reset() { *x = SubscribeStartVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStartVideoStreamingRequest) String() string { @@ -1251,7 +1214,7 @@ func (*SubscribeStartVideoStreamingRequest) ProtoMessage() {} func (x *SubscribeStartVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1276,11 +1239,9 @@ type StartVideoStreamingResponse struct { func (x *StartVideoStreamingResponse) Reset() { *x = StartVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartVideoStreamingResponse) String() string { @@ -1291,7 +1252,7 @@ func (*StartVideoStreamingResponse) ProtoMessage() {} func (x *StartVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1323,11 +1284,9 @@ type RespondStartVideoStreamingRequest struct { func (x *RespondStartVideoStreamingRequest) Reset() { *x = RespondStartVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStartVideoStreamingRequest) String() string { @@ -1338,7 +1297,7 @@ func (*RespondStartVideoStreamingRequest) ProtoMessage() {} func (x *RespondStartVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1370,11 +1329,9 @@ type RespondStartVideoStreamingResponse struct { func (x *RespondStartVideoStreamingResponse) Reset() { *x = RespondStartVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStartVideoStreamingResponse) String() string { @@ -1385,7 +1342,7 @@ func (*RespondStartVideoStreamingResponse) ProtoMessage() {} func (x *RespondStartVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1415,11 +1372,9 @@ type SubscribeStopVideoStreamingRequest struct { func (x *SubscribeStopVideoStreamingRequest) Reset() { *x = SubscribeStopVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStopVideoStreamingRequest) String() string { @@ -1430,7 +1385,7 @@ func (*SubscribeStopVideoStreamingRequest) ProtoMessage() {} func (x *SubscribeStopVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1455,11 +1410,9 @@ type StopVideoStreamingResponse struct { func (x *StopVideoStreamingResponse) Reset() { *x = StopVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopVideoStreamingResponse) String() string { @@ -1470,7 +1423,7 @@ func (*StopVideoStreamingResponse) ProtoMessage() {} func (x *StopVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1502,11 +1455,9 @@ type RespondStopVideoStreamingRequest struct { func (x *RespondStopVideoStreamingRequest) Reset() { *x = RespondStopVideoStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStopVideoStreamingRequest) String() string { @@ -1517,7 +1468,7 @@ func (*RespondStopVideoStreamingRequest) ProtoMessage() {} func (x *RespondStopVideoStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1549,11 +1500,9 @@ type RespondStopVideoStreamingResponse struct { func (x *RespondStopVideoStreamingResponse) Reset() { *x = RespondStopVideoStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStopVideoStreamingResponse) String() string { @@ -1564,7 +1513,7 @@ func (*RespondStopVideoStreamingResponse) ProtoMessage() {} func (x *RespondStopVideoStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1594,11 +1543,9 @@ type SubscribeSetModeRequest struct { func (x *SubscribeSetModeRequest) Reset() { *x = SubscribeSetModeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeSetModeRequest) String() string { @@ -1609,7 +1556,7 @@ func (*SubscribeSetModeRequest) ProtoMessage() {} func (x *SubscribeSetModeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1634,11 +1581,9 @@ type SetModeResponse struct { func (x *SetModeResponse) Reset() { *x = SetModeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetModeResponse) String() string { @@ -1649,7 +1594,7 @@ func (*SetModeResponse) ProtoMessage() {} func (x *SetModeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1681,11 +1626,9 @@ type RespondSetModeRequest struct { func (x *RespondSetModeRequest) Reset() { *x = RespondSetModeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondSetModeRequest) String() string { @@ -1696,7 +1639,7 @@ func (*RespondSetModeRequest) ProtoMessage() {} func (x *RespondSetModeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1728,11 +1671,9 @@ type RespondSetModeResponse struct { func (x *RespondSetModeResponse) Reset() { *x = RespondSetModeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondSetModeResponse) String() string { @@ -1743,7 +1684,7 @@ func (*RespondSetModeResponse) ProtoMessage() {} func (x *RespondSetModeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1773,11 +1714,9 @@ type SubscribeStorageInformationRequest struct { func (x *SubscribeStorageInformationRequest) Reset() { *x = SubscribeStorageInformationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStorageInformationRequest) String() string { @@ -1788,7 +1727,7 @@ func (*SubscribeStorageInformationRequest) ProtoMessage() {} func (x *SubscribeStorageInformationRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1813,11 +1752,9 @@ type StorageInformationResponse struct { func (x *StorageInformationResponse) Reset() { *x = StorageInformationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StorageInformationResponse) String() string { @@ -1828,7 +1765,7 @@ func (*StorageInformationResponse) ProtoMessage() {} func (x *StorageInformationResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1861,11 +1798,9 @@ type RespondStorageInformationRequest struct { func (x *RespondStorageInformationRequest) Reset() { *x = RespondStorageInformationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStorageInformationRequest) String() string { @@ -1876,7 +1811,7 @@ func (*RespondStorageInformationRequest) ProtoMessage() {} func (x *RespondStorageInformationRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1915,11 +1850,9 @@ type RespondStorageInformationResponse struct { func (x *RespondStorageInformationResponse) Reset() { *x = RespondStorageInformationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondStorageInformationResponse) String() string { @@ -1930,7 +1863,7 @@ func (*RespondStorageInformationResponse) ProtoMessage() {} func (x *RespondStorageInformationResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1960,11 +1893,9 @@ type SubscribeCaptureStatusRequest struct { func (x *SubscribeCaptureStatusRequest) Reset() { *x = SubscribeCaptureStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[34] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCaptureStatusRequest) String() string { @@ -1975,7 +1906,7 @@ func (*SubscribeCaptureStatusRequest) ProtoMessage() {} func (x *SubscribeCaptureStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[34] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2000,11 +1931,9 @@ type CaptureStatusResponse struct { func (x *CaptureStatusResponse) Reset() { *x = CaptureStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CaptureStatusResponse) String() string { @@ -2015,7 +1944,7 @@ func (*CaptureStatusResponse) ProtoMessage() {} func (x *CaptureStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[35] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2048,11 +1977,9 @@ type RespondCaptureStatusRequest struct { func (x *RespondCaptureStatusRequest) Reset() { *x = RespondCaptureStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[36] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondCaptureStatusRequest) String() string { @@ -2063,7 +1990,7 @@ func (*RespondCaptureStatusRequest) ProtoMessage() {} func (x *RespondCaptureStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[36] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2102,11 +2029,9 @@ type RespondCaptureStatusResponse struct { func (x *RespondCaptureStatusResponse) Reset() { *x = RespondCaptureStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[37] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondCaptureStatusResponse) String() string { @@ -2117,7 +2042,7 @@ func (*RespondCaptureStatusResponse) ProtoMessage() {} func (x *RespondCaptureStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[37] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2147,11 +2072,9 @@ type SubscribeFormatStorageRequest struct { func (x *SubscribeFormatStorageRequest) Reset() { *x = SubscribeFormatStorageRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[38] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeFormatStorageRequest) String() string { @@ -2162,7 +2085,7 @@ func (*SubscribeFormatStorageRequest) ProtoMessage() {} func (x *SubscribeFormatStorageRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[38] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2187,11 +2110,9 @@ type FormatStorageResponse struct { func (x *FormatStorageResponse) Reset() { *x = FormatStorageResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[39] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FormatStorageResponse) String() string { @@ -2202,7 +2123,7 @@ func (*FormatStorageResponse) ProtoMessage() {} func (x *FormatStorageResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[39] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2234,11 +2155,9 @@ type RespondFormatStorageRequest struct { func (x *RespondFormatStorageRequest) Reset() { *x = RespondFormatStorageRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[40] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondFormatStorageRequest) String() string { @@ -2249,7 +2168,7 @@ func (*RespondFormatStorageRequest) ProtoMessage() {} func (x *RespondFormatStorageRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[40] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2281,11 +2200,9 @@ type RespondFormatStorageResponse struct { func (x *RespondFormatStorageResponse) Reset() { *x = RespondFormatStorageResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[41] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondFormatStorageResponse) String() string { @@ -2296,7 +2213,7 @@ func (*RespondFormatStorageResponse) ProtoMessage() {} func (x *RespondFormatStorageResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[41] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2326,11 +2243,9 @@ type SubscribeResetSettingsRequest struct { func (x *SubscribeResetSettingsRequest) Reset() { *x = SubscribeResetSettingsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[42] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeResetSettingsRequest) String() string { @@ -2341,7 +2256,7 @@ func (*SubscribeResetSettingsRequest) ProtoMessage() {} func (x *SubscribeResetSettingsRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[42] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2366,11 +2281,9 @@ type ResetSettingsResponse struct { func (x *ResetSettingsResponse) Reset() { *x = ResetSettingsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[43] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ResetSettingsResponse) String() string { @@ -2381,7 +2294,7 @@ func (*ResetSettingsResponse) ProtoMessage() {} func (x *ResetSettingsResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[43] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2413,11 +2326,9 @@ type RespondResetSettingsRequest struct { func (x *RespondResetSettingsRequest) Reset() { *x = RespondResetSettingsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[44] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondResetSettingsRequest) String() string { @@ -2428,7 +2339,7 @@ func (*RespondResetSettingsRequest) ProtoMessage() {} func (x *RespondResetSettingsRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[44] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2460,11 +2371,9 @@ type RespondResetSettingsResponse struct { func (x *RespondResetSettingsResponse) Reset() { *x = RespondResetSettingsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[45] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[45] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondResetSettingsResponse) String() string { @@ -2475,7 +2384,7 @@ func (*RespondResetSettingsResponse) ProtoMessage() {} func (x *RespondResetSettingsResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[45] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2505,11 +2414,9 @@ type SubscribeZoomInStartRequest struct { func (x *SubscribeZoomInStartRequest) Reset() { *x = SubscribeZoomInStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[46] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[46] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeZoomInStartRequest) String() string { @@ -2520,7 +2427,7 @@ func (*SubscribeZoomInStartRequest) ProtoMessage() {} func (x *SubscribeZoomInStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[46] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2545,11 +2452,9 @@ type ZoomInStartResponse struct { func (x *ZoomInStartResponse) Reset() { *x = ZoomInStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[47] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[47] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomInStartResponse) String() string { @@ -2560,7 +2465,7 @@ func (*ZoomInStartResponse) ProtoMessage() {} func (x *ZoomInStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[47] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2592,11 +2497,9 @@ type RespondZoomInStartRequest struct { func (x *RespondZoomInStartRequest) Reset() { *x = RespondZoomInStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[48] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[48] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomInStartRequest) String() string { @@ -2607,7 +2510,7 @@ func (*RespondZoomInStartRequest) ProtoMessage() {} func (x *RespondZoomInStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[48] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2639,11 +2542,9 @@ type RespondZoomInStartResponse struct { func (x *RespondZoomInStartResponse) Reset() { *x = RespondZoomInStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[49] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[49] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomInStartResponse) String() string { @@ -2654,7 +2555,7 @@ func (*RespondZoomInStartResponse) ProtoMessage() {} func (x *RespondZoomInStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[49] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2684,11 +2585,9 @@ type SubscribeZoomOutStartRequest struct { func (x *SubscribeZoomOutStartRequest) Reset() { *x = SubscribeZoomOutStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[50] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[50] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeZoomOutStartRequest) String() string { @@ -2699,7 +2598,7 @@ func (*SubscribeZoomOutStartRequest) ProtoMessage() {} func (x *SubscribeZoomOutStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[50] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2724,11 +2623,9 @@ type ZoomOutStartResponse struct { func (x *ZoomOutStartResponse) Reset() { *x = ZoomOutStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[51] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[51] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomOutStartResponse) String() string { @@ -2739,7 +2636,7 @@ func (*ZoomOutStartResponse) ProtoMessage() {} func (x *ZoomOutStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[51] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2771,11 +2668,9 @@ type RespondZoomOutStartRequest struct { func (x *RespondZoomOutStartRequest) Reset() { *x = RespondZoomOutStartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[52] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[52] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomOutStartRequest) String() string { @@ -2786,7 +2681,7 @@ func (*RespondZoomOutStartRequest) ProtoMessage() {} func (x *RespondZoomOutStartRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[52] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2818,11 +2713,9 @@ type RespondZoomOutStartResponse struct { func (x *RespondZoomOutStartResponse) Reset() { *x = RespondZoomOutStartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[53] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[53] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomOutStartResponse) String() string { @@ -2833,7 +2726,7 @@ func (*RespondZoomOutStartResponse) ProtoMessage() {} func (x *RespondZoomOutStartResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[53] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2863,11 +2756,9 @@ type SubscribeZoomStopRequest struct { func (x *SubscribeZoomStopRequest) Reset() { *x = SubscribeZoomStopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[54] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[54] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeZoomStopRequest) String() string { @@ -2878,7 +2769,7 @@ func (*SubscribeZoomStopRequest) ProtoMessage() {} func (x *SubscribeZoomStopRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[54] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2903,11 +2794,9 @@ type ZoomStopResponse struct { func (x *ZoomStopResponse) Reset() { *x = ZoomStopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[55] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[55] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomStopResponse) String() string { @@ -2918,7 +2807,7 @@ func (*ZoomStopResponse) ProtoMessage() {} func (x *ZoomStopResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[55] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2950,11 +2839,9 @@ type RespondZoomStopRequest struct { func (x *RespondZoomStopRequest) Reset() { *x = RespondZoomStopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[56] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[56] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomStopRequest) String() string { @@ -2965,7 +2852,7 @@ func (*RespondZoomStopRequest) ProtoMessage() {} func (x *RespondZoomStopRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[56] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2997,11 +2884,9 @@ type RespondZoomStopResponse struct { func (x *RespondZoomStopResponse) Reset() { *x = RespondZoomStopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[57] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[57] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomStopResponse) String() string { @@ -3012,7 +2897,7 @@ func (*RespondZoomStopResponse) ProtoMessage() {} func (x *RespondZoomStopResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[57] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3042,11 +2927,9 @@ type SubscribeZoomRangeRequest struct { func (x *SubscribeZoomRangeRequest) Reset() { *x = SubscribeZoomRangeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[58] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[58] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeZoomRangeRequest) String() string { @@ -3057,7 +2940,7 @@ func (*SubscribeZoomRangeRequest) ProtoMessage() {} func (x *SubscribeZoomRangeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[58] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3082,11 +2965,9 @@ type ZoomRangeResponse struct { func (x *ZoomRangeResponse) Reset() { *x = ZoomRangeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[59] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[59] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ZoomRangeResponse) String() string { @@ -3097,7 +2978,7 @@ func (*ZoomRangeResponse) ProtoMessage() {} func (x *ZoomRangeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[59] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3129,11 +3010,9 @@ type RespondZoomRangeRequest struct { func (x *RespondZoomRangeRequest) Reset() { *x = RespondZoomRangeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[60] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[60] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomRangeRequest) String() string { @@ -3144,7 +3023,7 @@ func (*RespondZoomRangeRequest) ProtoMessage() {} func (x *RespondZoomRangeRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[60] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3176,11 +3055,9 @@ type RespondZoomRangeResponse struct { func (x *RespondZoomRangeResponse) Reset() { *x = RespondZoomRangeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[61] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[61] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondZoomRangeResponse) String() string { @@ -3191,7 +3068,7 @@ func (*RespondZoomRangeResponse) ProtoMessage() {} func (x *RespondZoomRangeResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[61] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3234,11 +3111,9 @@ type Information struct { func (x *Information) Reset() { *x = Information{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[62] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[62] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Information) String() string { @@ -3249,7 +3124,7 @@ func (*Information) ProtoMessage() {} func (x *Information) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[62] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3353,11 +3228,9 @@ type VideoStreaming struct { func (x *VideoStreaming) Reset() { *x = VideoStreaming{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[63] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[63] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VideoStreaming) String() string { @@ -3368,7 +3241,7 @@ func (*VideoStreaming) ProtoMessage() {} func (x *VideoStreaming) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[63] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3411,11 +3284,9 @@ type Position struct { func (x *Position) Reset() { *x = Position{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[64] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[64] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Position) String() string { @@ -3426,7 +3297,7 @@ func (*Position) ProtoMessage() {} func (x *Position) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[64] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3490,11 +3361,9 @@ type Quaternion struct { func (x *Quaternion) Reset() { *x = Quaternion{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[65] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[65] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Quaternion) String() string { @@ -3505,7 +3374,7 @@ func (*Quaternion) ProtoMessage() {} func (x *Quaternion) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[65] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3564,11 +3433,9 @@ type CaptureInfo struct { func (x *CaptureInfo) Reset() { *x = CaptureInfo{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[66] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[66] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CaptureInfo) String() string { @@ -3579,7 +3446,7 @@ func (*CaptureInfo) ProtoMessage() {} func (x *CaptureInfo) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[66] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3648,11 +3515,9 @@ type CameraServerResult struct { func (x *CameraServerResult) Reset() { *x = CameraServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[67] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[67] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CameraServerResult) String() string { @@ -3663,7 +3528,7 @@ func (*CameraServerResult) ProtoMessage() {} func (x *CameraServerResult) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[67] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3710,11 +3575,9 @@ type StorageInformation struct { func (x *StorageInformation) Reset() { *x = StorageInformation{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[68] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[68] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StorageInformation) String() string { @@ -3725,7 +3588,7 @@ func (*StorageInformation) ProtoMessage() {} func (x *StorageInformation) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[68] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3811,11 +3674,9 @@ type CaptureStatus struct { func (x *CaptureStatus) Reset() { *x = CaptureStatus{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[69] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[69] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CaptureStatus) String() string { @@ -3826,7 +3687,7 @@ func (*CaptureStatus) ProtoMessage() {} func (x *CaptureStatus) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[69] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3893,11 +3754,9 @@ type SetTrackingPointStatusRequest struct { func (x *SetTrackingPointStatusRequest) Reset() { *x = SetTrackingPointStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[70] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[70] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTrackingPointStatusRequest) String() string { @@ -3908,7 +3767,7 @@ func (*SetTrackingPointStatusRequest) ProtoMessage() {} func (x *SetTrackingPointStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[70] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3938,11 +3797,9 @@ type SetTrackingPointStatusResponse struct { func (x *SetTrackingPointStatusResponse) Reset() { *x = SetTrackingPointStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[71] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[71] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTrackingPointStatusResponse) String() string { @@ -3953,7 +3810,7 @@ func (*SetTrackingPointStatusResponse) ProtoMessage() {} func (x *SetTrackingPointStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[71] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3978,11 +3835,9 @@ type SetTrackingRectangleStatusRequest struct { func (x *SetTrackingRectangleStatusRequest) Reset() { *x = SetTrackingRectangleStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[72] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[72] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTrackingRectangleStatusRequest) String() string { @@ -3993,7 +3848,7 @@ func (*SetTrackingRectangleStatusRequest) ProtoMessage() {} func (x *SetTrackingRectangleStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[72] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4023,11 +3878,9 @@ type SetTrackingRectangleStatusResponse struct { func (x *SetTrackingRectangleStatusResponse) Reset() { *x = SetTrackingRectangleStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[73] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[73] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTrackingRectangleStatusResponse) String() string { @@ -4038,7 +3891,7 @@ func (*SetTrackingRectangleStatusResponse) ProtoMessage() {} func (x *SetTrackingRectangleStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[73] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4061,11 +3914,9 @@ type SetTrackingOffStatusRequest struct { func (x *SetTrackingOffStatusRequest) Reset() { *x = SetTrackingOffStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[74] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[74] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTrackingOffStatusRequest) String() string { @@ -4076,7 +3927,7 @@ func (*SetTrackingOffStatusRequest) ProtoMessage() {} func (x *SetTrackingOffStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[74] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4099,11 +3950,9 @@ type SetTrackingOffStatusResponse struct { func (x *SetTrackingOffStatusResponse) Reset() { *x = SetTrackingOffStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[75] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[75] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTrackingOffStatusResponse) String() string { @@ -4114,7 +3963,7 @@ func (*SetTrackingOffStatusResponse) ProtoMessage() {} func (x *SetTrackingOffStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[75] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4137,11 +3986,9 @@ type SubscribeTrackingPointCommandRequest struct { func (x *SubscribeTrackingPointCommandRequest) Reset() { *x = SubscribeTrackingPointCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[76] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[76] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTrackingPointCommandRequest) String() string { @@ -4152,7 +3999,7 @@ func (*SubscribeTrackingPointCommandRequest) ProtoMessage() {} func (x *SubscribeTrackingPointCommandRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[76] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4177,11 +4024,9 @@ type TrackingPointCommandResponse struct { func (x *TrackingPointCommandResponse) Reset() { *x = TrackingPointCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[77] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[77] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackingPointCommandResponse) String() string { @@ -4192,7 +4037,7 @@ func (*TrackingPointCommandResponse) ProtoMessage() {} func (x *TrackingPointCommandResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[77] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4222,11 +4067,9 @@ type SubscribeTrackingRectangleCommandRequest struct { func (x *SubscribeTrackingRectangleCommandRequest) Reset() { *x = SubscribeTrackingRectangleCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[78] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[78] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTrackingRectangleCommandRequest) String() string { @@ -4237,7 +4080,7 @@ func (*SubscribeTrackingRectangleCommandRequest) ProtoMessage() {} func (x *SubscribeTrackingRectangleCommandRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[78] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4262,11 +4105,9 @@ type TrackingRectangleCommandResponse struct { func (x *TrackingRectangleCommandResponse) Reset() { *x = TrackingRectangleCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[79] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[79] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackingRectangleCommandResponse) String() string { @@ -4277,7 +4118,7 @@ func (*TrackingRectangleCommandResponse) ProtoMessage() {} func (x *TrackingRectangleCommandResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[79] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4307,11 +4148,9 @@ type SubscribeTrackingOffCommandRequest struct { func (x *SubscribeTrackingOffCommandRequest) Reset() { *x = SubscribeTrackingOffCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[80] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[80] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTrackingOffCommandRequest) String() string { @@ -4322,7 +4161,7 @@ func (*SubscribeTrackingOffCommandRequest) ProtoMessage() {} func (x *SubscribeTrackingOffCommandRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[80] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4347,11 +4186,9 @@ type TrackingOffCommandResponse struct { func (x *TrackingOffCommandResponse) Reset() { *x = TrackingOffCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[81] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[81] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackingOffCommandResponse) String() string { @@ -4362,7 +4199,7 @@ func (*TrackingOffCommandResponse) ProtoMessage() {} func (x *TrackingOffCommandResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[81] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4394,11 +4231,9 @@ type RespondTrackingPointCommandRequest struct { func (x *RespondTrackingPointCommandRequest) Reset() { *x = RespondTrackingPointCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[82] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[82] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTrackingPointCommandRequest) String() string { @@ -4409,7 +4244,7 @@ func (*RespondTrackingPointCommandRequest) ProtoMessage() {} func (x *RespondTrackingPointCommandRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[82] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4441,11 +4276,9 @@ type RespondTrackingPointCommandResponse struct { func (x *RespondTrackingPointCommandResponse) Reset() { *x = RespondTrackingPointCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[83] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[83] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTrackingPointCommandResponse) String() string { @@ -4456,7 +4289,7 @@ func (*RespondTrackingPointCommandResponse) ProtoMessage() {} func (x *RespondTrackingPointCommandResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[83] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4488,11 +4321,9 @@ type RespondTrackingRectangleCommandRequest struct { func (x *RespondTrackingRectangleCommandRequest) Reset() { *x = RespondTrackingRectangleCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[84] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[84] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTrackingRectangleCommandRequest) String() string { @@ -4503,7 +4334,7 @@ func (*RespondTrackingRectangleCommandRequest) ProtoMessage() {} func (x *RespondTrackingRectangleCommandRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[84] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4535,11 +4366,9 @@ type RespondTrackingRectangleCommandResponse struct { func (x *RespondTrackingRectangleCommandResponse) Reset() { *x = RespondTrackingRectangleCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[85] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[85] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTrackingRectangleCommandResponse) String() string { @@ -4550,7 +4379,7 @@ func (*RespondTrackingRectangleCommandResponse) ProtoMessage() {} func (x *RespondTrackingRectangleCommandResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[85] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4582,11 +4411,9 @@ type RespondTrackingOffCommandRequest struct { func (x *RespondTrackingOffCommandRequest) Reset() { *x = RespondTrackingOffCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[86] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[86] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTrackingOffCommandRequest) String() string { @@ -4597,7 +4424,7 @@ func (*RespondTrackingOffCommandRequest) ProtoMessage() {} func (x *RespondTrackingOffCommandRequest) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[86] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4629,11 +4456,9 @@ type RespondTrackingOffCommandResponse struct { func (x *RespondTrackingOffCommandResponse) Reset() { *x = RespondTrackingOffCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[87] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[87] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RespondTrackingOffCommandResponse) String() string { @@ -4644,7 +4469,7 @@ func (*RespondTrackingOffCommandResponse) ProtoMessage() {} func (x *RespondTrackingOffCommandResponse) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[87] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4679,11 +4504,9 @@ type TrackPoint struct { func (x *TrackPoint) Reset() { *x = TrackPoint{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[88] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[88] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackPoint) String() string { @@ -4694,7 +4517,7 @@ func (*TrackPoint) ProtoMessage() {} func (x *TrackPoint) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[88] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4744,11 +4567,9 @@ type TrackRectangle struct { func (x *TrackRectangle) Reset() { *x = TrackRectangle{} - if protoimpl.UnsafeEnabled { - mi := &file_camera_server_proto_msgTypes[89] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_camera_server_proto_msgTypes[89] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TrackRectangle) String() string { @@ -4759,7 +4580,7 @@ func (*TrackRectangle) ProtoMessage() {} func (x *TrackRectangle) ProtoReflect() protoreflect.Message { mi := &file_camera_server_proto_msgTypes[89] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6077,1089 +5898,6 @@ func file_camera_server_proto_init() { if File_camera_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_camera_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SetInformationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SetInformationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SetInProgressRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*SetInProgressResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTakePhotoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*TakePhotoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*RespondTakePhotoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*RespondTakePhotoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStartVideoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*StartVideoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*RespondStartVideoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*RespondStartVideoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStopVideoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*StopVideoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*RespondStopVideoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*RespondStopVideoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStartVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*StartVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*RespondStartVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*RespondStartVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStopVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*StopVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*RespondStopVideoStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*RespondStopVideoStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeSetModeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*SetModeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*RespondSetModeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*RespondSetModeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStorageInformationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*StorageInformationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*RespondStorageInformationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*RespondStorageInformationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[34].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCaptureStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[35].Exporter = func(v any, i int) any { - switch v := v.(*CaptureStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[36].Exporter = func(v any, i int) any { - switch v := v.(*RespondCaptureStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[37].Exporter = func(v any, i int) any { - switch v := v.(*RespondCaptureStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[38].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeFormatStorageRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[39].Exporter = func(v any, i int) any { - switch v := v.(*FormatStorageResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[40].Exporter = func(v any, i int) any { - switch v := v.(*RespondFormatStorageRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[41].Exporter = func(v any, i int) any { - switch v := v.(*RespondFormatStorageResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[42].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeResetSettingsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[43].Exporter = func(v any, i int) any { - switch v := v.(*ResetSettingsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[44].Exporter = func(v any, i int) any { - switch v := v.(*RespondResetSettingsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[45].Exporter = func(v any, i int) any { - switch v := v.(*RespondResetSettingsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[46].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeZoomInStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[47].Exporter = func(v any, i int) any { - switch v := v.(*ZoomInStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[48].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomInStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[49].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomInStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[50].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeZoomOutStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[51].Exporter = func(v any, i int) any { - switch v := v.(*ZoomOutStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[52].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomOutStartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[53].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomOutStartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[54].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeZoomStopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[55].Exporter = func(v any, i int) any { - switch v := v.(*ZoomStopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[56].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomStopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[57].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomStopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[58].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeZoomRangeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[59].Exporter = func(v any, i int) any { - switch v := v.(*ZoomRangeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[60].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomRangeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[61].Exporter = func(v any, i int) any { - switch v := v.(*RespondZoomRangeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[62].Exporter = func(v any, i int) any { - switch v := v.(*Information); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[63].Exporter = func(v any, i int) any { - switch v := v.(*VideoStreaming); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[64].Exporter = func(v any, i int) any { - switch v := v.(*Position); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[65].Exporter = func(v any, i int) any { - switch v := v.(*Quaternion); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[66].Exporter = func(v any, i int) any { - switch v := v.(*CaptureInfo); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[67].Exporter = func(v any, i int) any { - switch v := v.(*CameraServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[68].Exporter = func(v any, i int) any { - switch v := v.(*StorageInformation); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[69].Exporter = func(v any, i int) any { - switch v := v.(*CaptureStatus); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[70].Exporter = func(v any, i int) any { - switch v := v.(*SetTrackingPointStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[71].Exporter = func(v any, i int) any { - switch v := v.(*SetTrackingPointStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[72].Exporter = func(v any, i int) any { - switch v := v.(*SetTrackingRectangleStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[73].Exporter = func(v any, i int) any { - switch v := v.(*SetTrackingRectangleStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[74].Exporter = func(v any, i int) any { - switch v := v.(*SetTrackingOffStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[75].Exporter = func(v any, i int) any { - switch v := v.(*SetTrackingOffStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[76].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTrackingPointCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[77].Exporter = func(v any, i int) any { - switch v := v.(*TrackingPointCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[78].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTrackingRectangleCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[79].Exporter = func(v any, i int) any { - switch v := v.(*TrackingRectangleCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[80].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTrackingOffCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[81].Exporter = func(v any, i int) any { - switch v := v.(*TrackingOffCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[82].Exporter = func(v any, i int) any { - switch v := v.(*RespondTrackingPointCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[83].Exporter = func(v any, i int) any { - switch v := v.(*RespondTrackingPointCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[84].Exporter = func(v any, i int) any { - switch v := v.(*RespondTrackingRectangleCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[85].Exporter = func(v any, i int) any { - switch v := v.(*RespondTrackingRectangleCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[86].Exporter = func(v any, i int) any { - switch v := v.(*RespondTrackingOffCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[87].Exporter = func(v any, i int) any { - switch v := v.(*RespondTrackingOffCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[88].Exporter = func(v any, i int) any { - switch v := v.(*TrackPoint); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_camera_server_proto_msgTypes[89].Exporter = func(v any, i int) any { - switch v := v.(*TrackRectangle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/camera_server/camera_server_grpc.pb.go b/Sources/camera_server/camera_server_grpc.pb.go index d95e2f3..3fca588 100644 --- a/Sources/camera_server/camera_server_grpc.pb.go +++ b/Sources/camera_server/camera_server_grpc.pb.go @@ -8,6 +8,7 @@ package camera_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/component_metadata/component_metadata.go b/Sources/component_metadata/component_metadata.go index 89f2fbb..6031d68 100644 --- a/Sources/component_metadata/component_metadata.go +++ b/Sources/component_metadata/component_metadata.go @@ -2,11 +2,11 @@ package component_metadata import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,20 +14,18 @@ type ServiceImpl struct { } /* - Request metadata from a specific component. This is used to start requesting metadata from a component. - The metadata can later be accessed via subscription (see below) or GetMetadata. - - Parameters - ---------- - compid uint32 - +RequestComponent Request metadata from a specific component. This is used to start requesting metadata from a component. + The metadata can later be accessed via subscription (see below) or GetMetadata. */ +func (s *ServiceImpl) RequestComponent( + ctx context.Context, + compid uint32, -func (s *ServiceImpl) RequestComponent(ctx context.Context, compid uint32) (*RequestComponentResponse, error) { - - request := &RequestComponentRequest{} - request.Compid = compid +) (*RequestComponentResponse, error) { + request := &RequestComponentRequest{ + Compid: compid, + } response, err := s.Client.RequestComponent(ctx, request) if err != nil { return nil, err @@ -36,14 +34,14 @@ func (s *ServiceImpl) RequestComponent(ctx context.Context, compid uint32) (*Req } /* - Request metadata from the autopilot component. This is used to start requesting metadata from the autopilot. - The metadata can later be accessed via subscription (see below) or GetMetadata. - +RequestAutopilotComponent Request metadata from the autopilot component. This is used to start requesting metadata from the autopilot. + The metadata can later be accessed via subscription (see below) or GetMetadata. */ +func (s *ServiceImpl) RequestAutopilotComponent( + ctx context.Context, -func (s *ServiceImpl) RequestAutopilotComponent(ctx context.Context) (*RequestAutopilotComponentResponse, error) { - +) (*RequestAutopilotComponentResponse, error) { request := &RequestAutopilotComponentRequest{} response, err := s.Client.RequestAutopilotComponent(ctx, request) if err != nil { @@ -53,12 +51,12 @@ func (s *ServiceImpl) RequestAutopilotComponent(ctx context.Context) (*RequestAu } /* - Register a callback that gets called when metadata is available - - +MetadataAvailable Register a callback that gets called when metadata is available */ +func (a *ServiceImpl) MetadataAvailable( + ctx context.Context, -func (a *ServiceImpl) MetadataAvailable(ctx context.Context) (<-chan *MetadataUpdate, error) { +) (<-chan *MetadataUpdate, error) { ch := make(chan *MetadataUpdate) request := &SubscribeMetadataAvailableRequest{} stream, err := a.Client.SubscribeMetadataAvailable(ctx, request) @@ -77,8 +75,7 @@ func (a *ServiceImpl) MetadataAvailable(ctx context.Context) (<-chan *MetadataUp if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive MetadataAvailable messages, err: %v\n", err) - break + log.Fatalf("Unable to receive MetadataAvailable messages, err: %v", err) } ch <- m.GetData() } @@ -87,30 +84,23 @@ func (a *ServiceImpl) MetadataAvailable(ctx context.Context) (<-chan *MetadataUp } /* - Access metadata. This can be used if you know the metadata is available already, otherwise use - the subscription to get notified when it becomes available. - - Parameters - ---------- - compid uint32metadataType *MetadataType - - - Returns - ------- - False - Response : MetadataData - +GetMetadata Access metadata. This can be used if you know the metadata is available already, otherwise use + the subscription to get notified when it becomes available. */ - -func (s *ServiceImpl) GetMetadata(ctx context.Context, compid uint32, metadataType *MetadataType) (*GetMetadataResponse, error) { - request := &GetMetadataRequest{} - request.Compid = compid - request.MetadataType = *metadataType +func (s *ServiceImpl) GetMetadata( + ctx context.Context, + compid uint32, + metadataType *MetadataType, + +) (*GetMetadataResponse, error) { + request := &GetMetadataRequest{ + Compid: compid, + MetadataType: *metadataType, + } response, err := s.Client.GetMetadata(ctx, request) if err != nil { return nil, err } return response, nil - } diff --git a/Sources/component_metadata/component_metadata.pb.go b/Sources/component_metadata/component_metadata.pb.go index e4052e0..a74053c 100644 --- a/Sources/component_metadata/component_metadata.pb.go +++ b/Sources/component_metadata/component_metadata.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: component_metadata.proto package component_metadata import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -150,11 +151,9 @@ type RequestComponentRequest struct { func (x *RequestComponentRequest) Reset() { *x = RequestComponentRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RequestComponentRequest) String() string { @@ -165,7 +164,7 @@ func (*RequestComponentRequest) ProtoMessage() {} func (x *RequestComponentRequest) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -198,11 +197,9 @@ type GetMetadataRequest struct { func (x *GetMetadataRequest) Reset() { *x = GetMetadataRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetMetadataRequest) String() string { @@ -213,7 +210,7 @@ func (*GetMetadataRequest) ProtoMessage() {} func (x *GetMetadataRequest) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -253,11 +250,9 @@ type GetMetadataResponse struct { func (x *GetMetadataResponse) Reset() { *x = GetMetadataResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetMetadataResponse) String() string { @@ -268,7 +263,7 @@ func (*GetMetadataResponse) ProtoMessage() {} func (x *GetMetadataResponse) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -308,11 +303,9 @@ type MetadataData struct { func (x *MetadataData) Reset() { *x = MetadataData{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MetadataData) String() string { @@ -323,7 +316,7 @@ func (*MetadataData) ProtoMessage() {} func (x *MetadataData) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -357,11 +350,9 @@ type ComponentMetadataResult struct { func (x *ComponentMetadataResult) Reset() { *x = ComponentMetadataResult{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ComponentMetadataResult) String() string { @@ -372,7 +363,7 @@ func (*ComponentMetadataResult) ProtoMessage() {} func (x *ComponentMetadataResult) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -409,11 +400,9 @@ type RequestComponentResponse struct { func (x *RequestComponentResponse) Reset() { *x = RequestComponentResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RequestComponentResponse) String() string { @@ -424,7 +413,7 @@ func (*RequestComponentResponse) ProtoMessage() {} func (x *RequestComponentResponse) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -447,11 +436,9 @@ type RequestAutopilotComponentRequest struct { func (x *RequestAutopilotComponentRequest) Reset() { *x = RequestAutopilotComponentRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RequestAutopilotComponentRequest) String() string { @@ -462,7 +449,7 @@ func (*RequestAutopilotComponentRequest) ProtoMessage() {} func (x *RequestAutopilotComponentRequest) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -485,11 +472,9 @@ type RequestAutopilotComponentResponse struct { func (x *RequestAutopilotComponentResponse) Reset() { *x = RequestAutopilotComponentResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RequestAutopilotComponentResponse) String() string { @@ -500,7 +485,7 @@ func (*RequestAutopilotComponentResponse) ProtoMessage() {} func (x *RequestAutopilotComponentResponse) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -523,11 +508,9 @@ type SubscribeMetadataAvailableRequest struct { func (x *SubscribeMetadataAvailableRequest) Reset() { *x = SubscribeMetadataAvailableRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeMetadataAvailableRequest) String() string { @@ -538,7 +521,7 @@ func (*SubscribeMetadataAvailableRequest) ProtoMessage() {} func (x *SubscribeMetadataAvailableRequest) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -563,11 +546,9 @@ type MetadataAvailableResponse struct { func (x *MetadataAvailableResponse) Reset() { *x = MetadataAvailableResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MetadataAvailableResponse) String() string { @@ -578,7 +559,7 @@ func (*MetadataAvailableResponse) ProtoMessage() {} func (x *MetadataAvailableResponse) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -613,11 +594,9 @@ type MetadataUpdate struct { func (x *MetadataUpdate) Reset() { *x = MetadataUpdate{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MetadataUpdate) String() string { @@ -628,7 +607,7 @@ func (*MetadataUpdate) ProtoMessage() {} func (x *MetadataUpdate) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -855,141 +834,6 @@ func file_component_metadata_proto_init() { if File_component_metadata_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_component_metadata_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*RequestComponentRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*GetMetadataRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*GetMetadataResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*MetadataData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*ComponentMetadataResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*RequestComponentResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*RequestAutopilotComponentRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*RequestAutopilotComponentResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeMetadataAvailableRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*MetadataAvailableResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*MetadataUpdate); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/component_metadata/component_metadata_grpc.pb.go b/Sources/component_metadata/component_metadata_grpc.pb.go index 4ae09a0..8a97c19 100644 --- a/Sources/component_metadata/component_metadata_grpc.pb.go +++ b/Sources/component_metadata/component_metadata_grpc.pb.go @@ -8,6 +8,7 @@ package component_metadata import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/component_metadata_server/component_metadata_server.go b/Sources/component_metadata_server/component_metadata_server.go index 8399554..f7873b4 100644 --- a/Sources/component_metadata_server/component_metadata_server.go +++ b/Sources/component_metadata_server/component_metadata_server.go @@ -9,20 +9,16 @@ type ServiceImpl struct { } /* - Provide metadata (can only be called once) - - Parameters - ---------- - metadata []*Metadata - - +SetMetadata Provide metadata (can only be called once) */ +func (s *ServiceImpl) SetMetadata( + ctx context.Context, + metadata []*Metadata, -func (s *ServiceImpl) SetMetadata(ctx context.Context, metadata []*Metadata) (*SetMetadataResponse, error) { - - request := &SetMetadataRequest{} - request.Metadata = metadata - +) (*SetMetadataResponse, error) { + request := &SetMetadataRequest{ + Metadata: metadata, + } response, err := s.Client.SetMetadata(ctx, request) if err != nil { return nil, err diff --git a/Sources/component_metadata_server/component_metadata_server.pb.go b/Sources/component_metadata_server/component_metadata_server.pb.go index 244e264..c4ebd5b 100644 --- a/Sources/component_metadata_server/component_metadata_server.pb.go +++ b/Sources/component_metadata_server/component_metadata_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: component_metadata_server.proto package component_metadata_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -79,11 +80,9 @@ type SetMetadataRequest struct { func (x *SetMetadataRequest) Reset() { *x = SetMetadataRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetMetadataRequest) String() string { @@ -94,7 +93,7 @@ func (*SetMetadataRequest) ProtoMessage() {} func (x *SetMetadataRequest) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -124,11 +123,9 @@ type SetMetadataResponse struct { func (x *SetMetadataResponse) Reset() { *x = SetMetadataResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetMetadataResponse) String() string { @@ -139,7 +136,7 @@ func (*SetMetadataResponse) ProtoMessage() {} func (x *SetMetadataResponse) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -165,11 +162,9 @@ type Metadata struct { func (x *Metadata) Reset() { *x = Metadata{} - if protoimpl.UnsafeEnabled { - mi := &file_component_metadata_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_component_metadata_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Metadata) String() string { @@ -180,7 +175,7 @@ func (*Metadata) ProtoMessage() {} func (x *Metadata) ProtoReflect() protoreflect.Message { mi := &file_component_metadata_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -294,45 +289,6 @@ func file_component_metadata_server_proto_init() { if File_component_metadata_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_component_metadata_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SetMetadataRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SetMetadataResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_component_metadata_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*Metadata); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/component_metadata_server/component_metadata_server_grpc.pb.go b/Sources/component_metadata_server/component_metadata_server_grpc.pb.go index aa48455..aad7509 100644 --- a/Sources/component_metadata_server/component_metadata_server_grpc.pb.go +++ b/Sources/component_metadata_server/component_metadata_server_grpc.pb.go @@ -8,6 +8,7 @@ package component_metadata_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/core/core.go b/Sources/core/core.go index 7c685a0..ed0ba0a 100644 --- a/Sources/core/core.go +++ b/Sources/core/core.go @@ -2,11 +2,11 @@ package core import ( "context" - "fmt" "io" + "log" - "google.golang.org/grpc/status" codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to 'connection state' updates. - - +ConnectionState Subscribe to 'connection state' updates. */ +func (a *ServiceImpl) ConnectionState( + ctx context.Context, -func (a *ServiceImpl) ConnectionState(ctx context.Context) (<-chan *ConnectionState, error) { +) (<-chan *ConnectionState, error) { ch := make(chan *ConnectionState) request := &SubscribeConnectionStateRequest{} stream, err := a.Client.SubscribeConnectionState(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) ConnectionState(ctx context.Context) (<-chan *ConnectionSt if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ConnectionState messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ConnectionState messages, err: %v", err) } ch <- m.GetConnectionState() } @@ -48,24 +47,21 @@ func (a *ServiceImpl) ConnectionState(ctx context.Context) (<-chan *ConnectionSt } /* - Set timeout of MAVLink transfers. - - The default timeout used is generally (0.5 seconds) seconds. - If MAVSDK is used on the same host this timeout can be reduced, while - if MAVSDK has to communicate over links with high latency it might - need to be increased to prevent timeouts. - - Parameters - ---------- - timeoutS float64 - +SetMavlinkTimeout Set timeout of MAVLink transfers. + The default timeout used is generally (0.5 seconds) seconds. + If MAVSDK is used on the same host this timeout can be reduced, while + if MAVSDK has to communicate over links with high latency it might + need to be increased to prevent timeouts. */ +func (s *ServiceImpl) SetMavlinkTimeout( + ctx context.Context, + timeoutS float64, -func (s *ServiceImpl) SetMavlinkTimeout(ctx context.Context, timeoutS float64) (*SetMavlinkTimeoutResponse, error) { - - request := &SetMavlinkTimeoutRequest{} - request.TimeoutS = timeoutS +) (*SetMavlinkTimeoutResponse, error) { + request := &SetMavlinkTimeoutRequest{ + TimeoutS: timeoutS, + } response, err := s.Client.SetMavlinkTimeout(ctx, request) if err != nil { return nil, err diff --git a/Sources/core/core.pb.go b/Sources/core/core.pb.go index f87a09b..073d63d 100644 --- a/Sources/core/core.pb.go +++ b/Sources/core/core.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: core.proto package core import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -28,11 +29,9 @@ type SubscribeConnectionStateRequest struct { func (x *SubscribeConnectionStateRequest) Reset() { *x = SubscribeConnectionStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_core_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_core_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeConnectionStateRequest) String() string { @@ -43,7 +42,7 @@ func (*SubscribeConnectionStateRequest) ProtoMessage() {} func (x *SubscribeConnectionStateRequest) ProtoReflect() protoreflect.Message { mi := &file_core_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -68,11 +67,9 @@ type ConnectionStateResponse struct { func (x *ConnectionStateResponse) Reset() { *x = ConnectionStateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_core_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_core_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ConnectionStateResponse) String() string { @@ -83,7 +80,7 @@ func (*ConnectionStateResponse) ProtoMessage() {} func (x *ConnectionStateResponse) ProtoReflect() protoreflect.Message { mi := &file_core_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -115,11 +112,9 @@ type SetMavlinkTimeoutRequest struct { func (x *SetMavlinkTimeoutRequest) Reset() { *x = SetMavlinkTimeoutRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_core_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_core_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetMavlinkTimeoutRequest) String() string { @@ -130,7 +125,7 @@ func (*SetMavlinkTimeoutRequest) ProtoMessage() {} func (x *SetMavlinkTimeoutRequest) ProtoReflect() protoreflect.Message { mi := &file_core_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -160,11 +155,9 @@ type SetMavlinkTimeoutResponse struct { func (x *SetMavlinkTimeoutResponse) Reset() { *x = SetMavlinkTimeoutResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_core_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_core_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetMavlinkTimeoutResponse) String() string { @@ -175,7 +168,7 @@ func (*SetMavlinkTimeoutResponse) ProtoMessage() {} func (x *SetMavlinkTimeoutResponse) ProtoReflect() protoreflect.Message { mi := &file_core_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -201,11 +194,9 @@ type ConnectionState struct { func (x *ConnectionState) Reset() { *x = ConnectionState{} - if protoimpl.UnsafeEnabled { - mi := &file_core_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_core_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ConnectionState) String() string { @@ -216,7 +207,7 @@ func (*ConnectionState) ProtoMessage() {} func (x *ConnectionState) ProtoReflect() protoreflect.Message { mi := &file_core_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -318,68 +309,6 @@ func file_core_proto_init() { if File_core_proto != nil { return } - if !protoimpl.UnsafeEnabled { - file_core_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeConnectionStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_core_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*ConnectionStateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_core_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetMavlinkTimeoutRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_core_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetMavlinkTimeoutResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_core_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*ConnectionState); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/core/core_grpc.pb.go b/Sources/core/core_grpc.pb.go index b63ece7..2c5d916 100644 --- a/Sources/core/core_grpc.pb.go +++ b/Sources/core/core_grpc.pb.go @@ -8,6 +8,7 @@ package core import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/failure/failure.go b/Sources/failure/failure.go index e804529..23460bd 100644 --- a/Sources/failure/failure.go +++ b/Sources/failure/failure.go @@ -9,27 +9,22 @@ type ServiceImpl struct { } /* - Injects a failure. - - Parameters - ---------- - failureUnit *FailureUnit - - - failureType *FailureType - - - instance int32 - - +Inject Injects a failure. */ +func (s *ServiceImpl) Inject( + ctx context.Context, + failureUnit *FailureUnit, -func (s *ServiceImpl) Inject(ctx context.Context, failureUnit *FailureUnit, failureType *FailureType, instance int32) (*InjectResponse, error) { + failureType *FailureType, - request := &InjectRequest{} - request.FailureUnit = *failureUnit - request.FailureType = *failureType - request.Instance = instance + instance int32, + +) (*InjectResponse, error) { + request := &InjectRequest{ + FailureUnit: *failureUnit, + FailureType: *failureType, + Instance: instance, + } response, err := s.Client.Inject(ctx, request) if err != nil { return nil, err diff --git a/Sources/failure/failure.pb.go b/Sources/failure/failure.pb.go index d1f931f..872ea3e 100644 --- a/Sources/failure/failure.pb.go +++ b/Sources/failure/failure.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: failure.proto package failure import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -248,11 +249,9 @@ type InjectRequest struct { func (x *InjectRequest) Reset() { *x = InjectRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_failure_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_failure_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *InjectRequest) String() string { @@ -263,7 +262,7 @@ func (*InjectRequest) ProtoMessage() {} func (x *InjectRequest) ProtoReflect() protoreflect.Message { mi := &file_failure_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -309,11 +308,9 @@ type InjectResponse struct { func (x *InjectResponse) Reset() { *x = InjectResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_failure_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_failure_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *InjectResponse) String() string { @@ -324,7 +321,7 @@ func (*InjectResponse) ProtoMessage() {} func (x *InjectResponse) ProtoReflect() protoreflect.Message { mi := &file_failure_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -357,11 +354,9 @@ type FailureResult struct { func (x *FailureResult) Reset() { *x = FailureResult{} - if protoimpl.UnsafeEnabled { - mi := &file_failure_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_failure_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FailureResult) String() string { @@ -372,7 +367,7 @@ func (*FailureResult) ProtoMessage() {} func (x *FailureResult) ProtoReflect() protoreflect.Message { mi := &file_failure_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -541,45 +536,6 @@ func file_failure_proto_init() { if File_failure_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_failure_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*InjectRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_failure_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*InjectResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_failure_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*FailureResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/failure/failure_grpc.pb.go b/Sources/failure/failure_grpc.pb.go index 5564d01..b886e9e 100644 --- a/Sources/failure/failure_grpc.pb.go +++ b/Sources/failure/failure_grpc.pb.go @@ -8,6 +8,7 @@ package failure import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/follow_me/follow_me.go b/Sources/follow_me/follow_me.go index ce4f637..89d0c81 100644 --- a/Sources/follow_me/follow_me.go +++ b/Sources/follow_me/follow_me.go @@ -9,45 +9,31 @@ type ServiceImpl struct { } /* - Get current configuration. - - - - Returns - ------- - False - Config : Config - The current configuration - - +GetConfig Get current configuration. */ +func (s *ServiceImpl) GetConfig( + ctx context.Context, -func (s *ServiceImpl) GetConfig(ctx context.Context) (*GetConfigResponse, error) { +) (*GetConfigResponse, error) { request := &GetConfigRequest{} response, err := s.Client.GetConfig(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Apply configuration by sending it to the system. - - Parameters - ---------- - config *Config - - - +SetConfig Apply configuration by sending it to the system. */ +func (s *ServiceImpl) SetConfig( + ctx context.Context, + config *Config, -func (s *ServiceImpl) SetConfig(ctx context.Context, config *Config) (*SetConfigResponse, error) { - - request := &SetConfigRequest{} - request.Config = config - +) (*SetConfigResponse, error) { + request := &SetConfigRequest{ + Config: config, + } response, err := s.Client.SetConfig(ctx, request) if err != nil { return nil, err @@ -56,45 +42,31 @@ func (s *ServiceImpl) SetConfig(ctx context.Context, config *Config) (*SetConfig } /* - Check if FollowMe is active. - - - - Returns - ------- - False - IsActive : bool - Whether follow me is active or not - - +IsActive Check if FollowMe is active. */ +func (s *ServiceImpl) IsActive( + ctx context.Context, -func (s *ServiceImpl) IsActive(ctx context.Context) (*IsActiveResponse, error) { +) (*IsActiveResponse, error) { request := &IsActiveRequest{} response, err := s.Client.IsActive(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set location of the moving target. - - Parameters - ---------- - location *TargetLocation - - - +SetTargetLocation Set location of the moving target. */ +func (s *ServiceImpl) SetTargetLocation( + ctx context.Context, + location *TargetLocation, -func (s *ServiceImpl) SetTargetLocation(ctx context.Context, location *TargetLocation) (*SetTargetLocationResponse, error) { - - request := &SetTargetLocationRequest{} - request.Location = location - +) (*SetTargetLocationResponse, error) { + request := &SetTargetLocationRequest{ + Location: location, + } response, err := s.Client.SetTargetLocation(ctx, request) if err != nil { return nil, err @@ -103,37 +75,27 @@ func (s *ServiceImpl) SetTargetLocation(ctx context.Context, location *TargetLoc } /* - Get the last location of the target. - - - - Returns - ------- - False - Location : TargetLocation - The last target location that was set - - +GetLastLocation Get the last location of the target. */ +func (s *ServiceImpl) GetLastLocation( + ctx context.Context, -func (s *ServiceImpl) GetLastLocation(ctx context.Context) (*GetLastLocationResponse, error) { +) (*GetLastLocationResponse, error) { request := &GetLastLocationRequest{} response, err := s.Client.GetLastLocation(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Start FollowMe mode. - - +Start Start FollowMe mode. */ +func (s *ServiceImpl) Start( + ctx context.Context, -func (s *ServiceImpl) Start(ctx context.Context) (*StartResponse, error) { - +) (*StartResponse, error) { request := &StartRequest{} response, err := s.Client.Start(ctx, request) if err != nil { @@ -143,13 +105,12 @@ func (s *ServiceImpl) Start(ctx context.Context) (*StartResponse, error) { } /* - Stop FollowMe mode. - - +Stop Stop FollowMe mode. */ +func (s *ServiceImpl) Stop( + ctx context.Context, -func (s *ServiceImpl) Stop(ctx context.Context) (*StopResponse, error) { - +) (*StopResponse, error) { request := &StopRequest{} response, err := s.Client.Stop(ctx, request) if err != nil { diff --git a/Sources/follow_me/follow_me.pb.go b/Sources/follow_me/follow_me.pb.go index b36c55c..964fbf0 100644 --- a/Sources/follow_me/follow_me.pb.go +++ b/Sources/follow_me/follow_me.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: follow_me.proto package follow_me import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -155,11 +156,9 @@ type Config struct { func (x *Config) Reset() { *x = Config{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Config) String() string { @@ -170,7 +169,7 @@ func (*Config) ProtoMessage() {} func (x *Config) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -243,11 +242,9 @@ type TargetLocation struct { func (x *TargetLocation) Reset() { *x = TargetLocation{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TargetLocation) String() string { @@ -258,7 +255,7 @@ func (*TargetLocation) ProtoMessage() {} func (x *TargetLocation) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -323,11 +320,9 @@ type GetConfigRequest struct { func (x *GetConfigRequest) Reset() { *x = GetConfigRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetConfigRequest) String() string { @@ -338,7 +333,7 @@ func (*GetConfigRequest) ProtoMessage() {} func (x *GetConfigRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -363,11 +358,9 @@ type GetConfigResponse struct { func (x *GetConfigResponse) Reset() { *x = GetConfigResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetConfigResponse) String() string { @@ -378,7 +371,7 @@ func (*GetConfigResponse) ProtoMessage() {} func (x *GetConfigResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -410,11 +403,9 @@ type SetConfigRequest struct { func (x *SetConfigRequest) Reset() { *x = SetConfigRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetConfigRequest) String() string { @@ -425,7 +416,7 @@ func (*SetConfigRequest) ProtoMessage() {} func (x *SetConfigRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -457,11 +448,9 @@ type SetConfigResponse struct { func (x *SetConfigResponse) Reset() { *x = SetConfigResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetConfigResponse) String() string { @@ -472,7 +461,7 @@ func (*SetConfigResponse) ProtoMessage() {} func (x *SetConfigResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -502,11 +491,9 @@ type IsActiveRequest struct { func (x *IsActiveRequest) Reset() { *x = IsActiveRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IsActiveRequest) String() string { @@ -517,7 +504,7 @@ func (*IsActiveRequest) ProtoMessage() {} func (x *IsActiveRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -542,11 +529,9 @@ type IsActiveResponse struct { func (x *IsActiveResponse) Reset() { *x = IsActiveResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IsActiveResponse) String() string { @@ -557,7 +542,7 @@ func (*IsActiveResponse) ProtoMessage() {} func (x *IsActiveResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -589,11 +574,9 @@ type SetTargetLocationRequest struct { func (x *SetTargetLocationRequest) Reset() { *x = SetTargetLocationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTargetLocationRequest) String() string { @@ -604,7 +587,7 @@ func (*SetTargetLocationRequest) ProtoMessage() {} func (x *SetTargetLocationRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -636,11 +619,9 @@ type SetTargetLocationResponse struct { func (x *SetTargetLocationResponse) Reset() { *x = SetTargetLocationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTargetLocationResponse) String() string { @@ -651,7 +632,7 @@ func (*SetTargetLocationResponse) ProtoMessage() {} func (x *SetTargetLocationResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -681,11 +662,9 @@ type GetLastLocationRequest struct { func (x *GetLastLocationRequest) Reset() { *x = GetLastLocationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetLastLocationRequest) String() string { @@ -696,7 +675,7 @@ func (*GetLastLocationRequest) ProtoMessage() {} func (x *GetLastLocationRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -721,11 +700,9 @@ type GetLastLocationResponse struct { func (x *GetLastLocationResponse) Reset() { *x = GetLastLocationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetLastLocationResponse) String() string { @@ -736,7 +713,7 @@ func (*GetLastLocationResponse) ProtoMessage() {} func (x *GetLastLocationResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -766,11 +743,9 @@ type StartRequest struct { func (x *StartRequest) Reset() { *x = StartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartRequest) String() string { @@ -781,7 +756,7 @@ func (*StartRequest) ProtoMessage() {} func (x *StartRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -806,11 +781,9 @@ type StartResponse struct { func (x *StartResponse) Reset() { *x = StartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartResponse) String() string { @@ -821,7 +794,7 @@ func (*StartResponse) ProtoMessage() {} func (x *StartResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -851,11 +824,9 @@ type StopRequest struct { func (x *StopRequest) Reset() { *x = StopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopRequest) String() string { @@ -866,7 +837,7 @@ func (*StopRequest) ProtoMessage() {} func (x *StopRequest) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -891,11 +862,9 @@ type StopResponse struct { func (x *StopResponse) Reset() { *x = StopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopResponse) String() string { @@ -906,7 +875,7 @@ func (*StopResponse) ProtoMessage() {} func (x *StopResponse) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -939,11 +908,9 @@ type FollowMeResult struct { func (x *FollowMeResult) Reset() { *x = FollowMeResult{} - if protoimpl.UnsafeEnabled { - mi := &file_follow_me_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_follow_me_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FollowMeResult) String() string { @@ -954,7 +921,7 @@ func (*FollowMeResult) ProtoMessage() {} func (x *FollowMeResult) ProtoReflect() protoreflect.Message { mi := &file_follow_me_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1239,213 +1206,6 @@ func file_follow_me_proto_init() { if File_follow_me_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_follow_me_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*Config); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*TargetLocation); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*GetConfigRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*GetConfigResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SetConfigRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*SetConfigResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*IsActiveRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*IsActiveResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SetTargetLocationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*SetTargetLocationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*GetLastLocationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*GetLastLocationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*StartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*StartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*StopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*StopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_follow_me_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*FollowMeResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/follow_me/follow_me_grpc.pb.go b/Sources/follow_me/follow_me_grpc.pb.go index 3bc8824..e5faf1d 100644 --- a/Sources/follow_me/follow_me_grpc.pb.go +++ b/Sources/follow_me/follow_me_grpc.pb.go @@ -8,6 +8,7 @@ package follow_me import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/ftp/ftp.go b/Sources/ftp/ftp.go index c4d43ca..3b97d6a 100644 --- a/Sources/ftp/ftp.go +++ b/Sources/ftp/ftp.go @@ -2,11 +2,11 @@ package ftp import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,19 +14,21 @@ type ServiceImpl struct { } /* - Downloads a file to local directory. - - Parameters - ---------- - remoteFilePath string, localDir string, useBurst bool +Download Downloads a file to local directory. */ +func (a *ServiceImpl) Download( + ctx context.Context, + remoteFilePath string, + localDir string, + useBurst bool, -func (a *ServiceImpl) Download(ctx context.Context, remoteFilePath string, localDir string, useBurst bool) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) - request := &SubscribeDownloadRequest{} - request.RemoteFilePath = remoteFilePath - request.LocalDir = localDir - request.UseBurst = useBurst + request := &SubscribeDownloadRequest{ + RemoteFilePath: remoteFilePath, + LocalDir: localDir, + UseBurst: useBurst, + } stream, err := a.Client.SubscribeDownload(ctx, request) if err != nil { return nil, err @@ -43,8 +45,7 @@ func (a *ServiceImpl) Download(ctx context.Context, remoteFilePath string, local if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Download messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Download messages, err: %v", err) } ch <- m.GetProgressData() } @@ -53,18 +54,19 @@ func (a *ServiceImpl) Download(ctx context.Context, remoteFilePath string, local } /* - Uploads local file to remote directory. - - Parameters - ---------- - localFilePath string, remoteDir string +Upload Uploads local file to remote directory. */ +func (a *ServiceImpl) Upload( + ctx context.Context, + localFilePath string, + remoteDir string, -func (a *ServiceImpl) Upload(ctx context.Context, localFilePath string, remoteDir string) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) - request := &SubscribeUploadRequest{} - request.LocalFilePath = localFilePath - request.RemoteDir = remoteDir + request := &SubscribeUploadRequest{ + LocalFilePath: localFilePath, + RemoteDir: remoteDir, + } stream, err := a.Client.SubscribeUpload(ctx, request) if err != nil { return nil, err @@ -81,8 +83,7 @@ func (a *ServiceImpl) Upload(ctx context.Context, localFilePath string, remoteDi if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Upload messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Upload messages, err: %v", err) } ch <- m.GetProgressData() } @@ -91,46 +92,34 @@ func (a *ServiceImpl) Upload(ctx context.Context, localFilePath string, remoteDi } /* - Lists items from a remote directory. - - Parameters - ---------- - remoteDir string - - Returns - ------- - True - Paths : []*string - The found directory contents. - - +ListDirectory Lists items from a remote directory. */ +func (s *ServiceImpl) ListDirectory( + ctx context.Context, + remoteDir string, -func (s *ServiceImpl) ListDirectory(ctx context.Context, remoteDir string) (*ListDirectoryResponse, error) { - request := &ListDirectoryRequest{} - request.RemoteDir = remoteDir +) (*ListDirectoryResponse, error) { + request := &ListDirectoryRequest{ + RemoteDir: remoteDir, + } response, err := s.Client.ListDirectory(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Creates a remote directory. - - Parameters - ---------- - remoteDir string - - +CreateDirectory Creates a remote directory. */ +func (s *ServiceImpl) CreateDirectory( + ctx context.Context, + remoteDir string, -func (s *ServiceImpl) CreateDirectory(ctx context.Context, remoteDir string) (*CreateDirectoryResponse, error) { - - request := &CreateDirectoryRequest{} - request.RemoteDir = remoteDir +) (*CreateDirectoryResponse, error) { + request := &CreateDirectoryRequest{ + RemoteDir: remoteDir, + } response, err := s.Client.CreateDirectory(ctx, request) if err != nil { return nil, err @@ -139,19 +128,16 @@ func (s *ServiceImpl) CreateDirectory(ctx context.Context, remoteDir string) (*C } /* - Removes a remote directory. - - Parameters - ---------- - remoteDir string - - +RemoveDirectory Removes a remote directory. */ +func (s *ServiceImpl) RemoveDirectory( + ctx context.Context, + remoteDir string, -func (s *ServiceImpl) RemoveDirectory(ctx context.Context, remoteDir string) (*RemoveDirectoryResponse, error) { - - request := &RemoveDirectoryRequest{} - request.RemoteDir = remoteDir +) (*RemoveDirectoryResponse, error) { + request := &RemoveDirectoryRequest{ + RemoteDir: remoteDir, + } response, err := s.Client.RemoveDirectory(ctx, request) if err != nil { return nil, err @@ -160,19 +146,16 @@ func (s *ServiceImpl) RemoveDirectory(ctx context.Context, remoteDir string) (*R } /* - Removes a remote file. - - Parameters - ---------- - remoteFilePath string - - +RemoveFile Removes a remote file. */ +func (s *ServiceImpl) RemoveFile( + ctx context.Context, + remoteFilePath string, -func (s *ServiceImpl) RemoveFile(ctx context.Context, remoteFilePath string) (*RemoveFileResponse, error) { - - request := &RemoveFileRequest{} - request.RemoteFilePath = remoteFilePath +) (*RemoveFileResponse, error) { + request := &RemoveFileRequest{ + RemoteFilePath: remoteFilePath, + } response, err := s.Client.RemoveFile(ctx, request) if err != nil { return nil, err @@ -181,22 +164,18 @@ func (s *ServiceImpl) RemoveFile(ctx context.Context, remoteFilePath string) (*R } /* - Renames a remote file or remote directory. - - Parameters - ---------- - remoteFromPath string - - remoteToPath string - - +Rename Renames a remote file or remote directory. */ - -func (s *ServiceImpl) Rename(ctx context.Context, remoteFromPath string, remoteToPath string) (*RenameResponse, error) { - - request := &RenameRequest{} - request.RemoteFromPath = remoteFromPath - request.RemoteToPath = remoteToPath +func (s *ServiceImpl) Rename( + ctx context.Context, + remoteFromPath string, + remoteToPath string, + +) (*RenameResponse, error) { + request := &RenameRequest{ + RemoteFromPath: remoteFromPath, + RemoteToPath: remoteToPath, + } response, err := s.Client.Rename(ctx, request) if err != nil { return nil, err @@ -205,47 +184,36 @@ func (s *ServiceImpl) Rename(ctx context.Context, remoteFromPath string, remoteT } /* - Compares a local file to a remote file using a CRC32 checksum. - - Parameters - ---------- - localFilePath stringremoteFilePath string - - Returns - ------- - False - AreIdentical : bool - Whether the files are identical. - - +AreFilesIdentical Compares a local file to a remote file using a CRC32 checksum. */ - -func (s *ServiceImpl) AreFilesIdentical(ctx context.Context, localFilePath string, remoteFilePath string) (*AreFilesIdenticalResponse, error) { - request := &AreFilesIdenticalRequest{} - request.LocalFilePath = localFilePath - request.RemoteFilePath = remoteFilePath +func (s *ServiceImpl) AreFilesIdentical( + ctx context.Context, + localFilePath string, + remoteFilePath string, + +) (*AreFilesIdenticalResponse, error) { + request := &AreFilesIdenticalRequest{ + LocalFilePath: localFilePath, + RemoteFilePath: remoteFilePath, + } response, err := s.Client.AreFilesIdentical(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set target component ID. By default it is the autopilot. - - Parameters - ---------- - compid uint32 - - +SetTargetCompid Set target component ID. By default it is the autopilot. */ +func (s *ServiceImpl) SetTargetCompid( + ctx context.Context, + compid uint32, -func (s *ServiceImpl) SetTargetCompid(ctx context.Context, compid uint32) (*SetTargetCompidResponse, error) { - - request := &SetTargetCompidRequest{} - request.Compid = compid +) (*SetTargetCompidResponse, error) { + request := &SetTargetCompidRequest{ + Compid: compid, + } response, err := s.Client.SetTargetCompid(ctx, request) if err != nil { return nil, err diff --git a/Sources/ftp/ftp.pb.go b/Sources/ftp/ftp.pb.go index 1fd6855..0762bdb 100644 --- a/Sources/ftp/ftp.pb.go +++ b/Sources/ftp/ftp.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: ftp.proto package ftp import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -112,11 +113,9 @@ type SubscribeDownloadRequest struct { func (x *SubscribeDownloadRequest) Reset() { *x = SubscribeDownloadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeDownloadRequest) String() string { @@ -127,7 +126,7 @@ func (*SubscribeDownloadRequest) ProtoMessage() {} func (x *SubscribeDownloadRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -174,11 +173,9 @@ type DownloadResponse struct { func (x *DownloadResponse) Reset() { *x = DownloadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadResponse) String() string { @@ -189,7 +186,7 @@ func (*DownloadResponse) ProtoMessage() {} func (x *DownloadResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -229,11 +226,9 @@ type SubscribeUploadRequest struct { func (x *SubscribeUploadRequest) Reset() { *x = SubscribeUploadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeUploadRequest) String() string { @@ -244,7 +239,7 @@ func (*SubscribeUploadRequest) ProtoMessage() {} func (x *SubscribeUploadRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -284,11 +279,9 @@ type UploadResponse struct { func (x *UploadResponse) Reset() { *x = UploadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadResponse) String() string { @@ -299,7 +292,7 @@ func (*UploadResponse) ProtoMessage() {} func (x *UploadResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -338,11 +331,9 @@ type ListDirectoryRequest struct { func (x *ListDirectoryRequest) Reset() { *x = ListDirectoryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ListDirectoryRequest) String() string { @@ -353,7 +344,7 @@ func (*ListDirectoryRequest) ProtoMessage() {} func (x *ListDirectoryRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -386,11 +377,9 @@ type ListDirectoryResponse struct { func (x *ListDirectoryResponse) Reset() { *x = ListDirectoryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ListDirectoryResponse) String() string { @@ -401,7 +390,7 @@ func (*ListDirectoryResponse) ProtoMessage() {} func (x *ListDirectoryResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -440,11 +429,9 @@ type CreateDirectoryRequest struct { func (x *CreateDirectoryRequest) Reset() { *x = CreateDirectoryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CreateDirectoryRequest) String() string { @@ -455,7 +442,7 @@ func (*CreateDirectoryRequest) ProtoMessage() {} func (x *CreateDirectoryRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -487,11 +474,9 @@ type CreateDirectoryResponse struct { func (x *CreateDirectoryResponse) Reset() { *x = CreateDirectoryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CreateDirectoryResponse) String() string { @@ -502,7 +487,7 @@ func (*CreateDirectoryResponse) ProtoMessage() {} func (x *CreateDirectoryResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -534,11 +519,9 @@ type RemoveDirectoryRequest struct { func (x *RemoveDirectoryRequest) Reset() { *x = RemoveDirectoryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RemoveDirectoryRequest) String() string { @@ -549,7 +532,7 @@ func (*RemoveDirectoryRequest) ProtoMessage() {} func (x *RemoveDirectoryRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -581,11 +564,9 @@ type RemoveDirectoryResponse struct { func (x *RemoveDirectoryResponse) Reset() { *x = RemoveDirectoryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RemoveDirectoryResponse) String() string { @@ -596,7 +577,7 @@ func (*RemoveDirectoryResponse) ProtoMessage() {} func (x *RemoveDirectoryResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -628,11 +609,9 @@ type RemoveFileRequest struct { func (x *RemoveFileRequest) Reset() { *x = RemoveFileRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RemoveFileRequest) String() string { @@ -643,7 +622,7 @@ func (*RemoveFileRequest) ProtoMessage() {} func (x *RemoveFileRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -675,11 +654,9 @@ type RemoveFileResponse struct { func (x *RemoveFileResponse) Reset() { *x = RemoveFileResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RemoveFileResponse) String() string { @@ -690,7 +667,7 @@ func (*RemoveFileResponse) ProtoMessage() {} func (x *RemoveFileResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -723,11 +700,9 @@ type RenameRequest struct { func (x *RenameRequest) Reset() { *x = RenameRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RenameRequest) String() string { @@ -738,7 +713,7 @@ func (*RenameRequest) ProtoMessage() {} func (x *RenameRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -777,11 +752,9 @@ type RenameResponse struct { func (x *RenameResponse) Reset() { *x = RenameResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RenameResponse) String() string { @@ -792,7 +765,7 @@ func (*RenameResponse) ProtoMessage() {} func (x *RenameResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -825,11 +798,9 @@ type AreFilesIdenticalRequest struct { func (x *AreFilesIdenticalRequest) Reset() { *x = AreFilesIdenticalRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AreFilesIdenticalRequest) String() string { @@ -840,7 +811,7 @@ func (*AreFilesIdenticalRequest) ProtoMessage() {} func (x *AreFilesIdenticalRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -880,11 +851,9 @@ type AreFilesIdenticalResponse struct { func (x *AreFilesIdenticalResponse) Reset() { *x = AreFilesIdenticalResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AreFilesIdenticalResponse) String() string { @@ -895,7 +864,7 @@ func (*AreFilesIdenticalResponse) ProtoMessage() {} func (x *AreFilesIdenticalResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -934,11 +903,9 @@ type SetTargetCompidRequest struct { func (x *SetTargetCompidRequest) Reset() { *x = SetTargetCompidRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTargetCompidRequest) String() string { @@ -949,7 +916,7 @@ func (*SetTargetCompidRequest) ProtoMessage() {} func (x *SetTargetCompidRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -981,11 +948,9 @@ type SetTargetCompidResponse struct { func (x *SetTargetCompidResponse) Reset() { *x = SetTargetCompidResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetTargetCompidResponse) String() string { @@ -996,7 +961,7 @@ func (*SetTargetCompidResponse) ProtoMessage() {} func (x *SetTargetCompidResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1030,11 +995,9 @@ type ProgressData struct { func (x *ProgressData) Reset() { *x = ProgressData{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProgressData) String() string { @@ -1045,7 +1008,7 @@ func (*ProgressData) ProtoMessage() {} func (x *ProgressData) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1086,11 +1049,9 @@ type FtpResult struct { func (x *FtpResult) Reset() { *x = FtpResult{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FtpResult) String() string { @@ -1101,7 +1062,7 @@ func (*FtpResult) ProtoMessage() {} func (x *FtpResult) ProtoReflect() protoreflect.Message { mi := &file_ftp_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1412,249 +1373,6 @@ func file_ftp_proto_init() { if File_ftp_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_ftp_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeDownloadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*DownloadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeUploadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*UploadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*ListDirectoryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*ListDirectoryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*CreateDirectoryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*CreateDirectoryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*RemoveDirectoryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*RemoveDirectoryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*RemoveFileRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*RemoveFileResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*RenameRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*RenameResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*AreFilesIdenticalRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*AreFilesIdenticalResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*SetTargetCompidRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*SetTargetCompidResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*ProgressData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*FtpResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/ftp/ftp_grpc.pb.go b/Sources/ftp/ftp_grpc.pb.go index b5447eb..2facef0 100644 --- a/Sources/ftp/ftp_grpc.pb.go +++ b/Sources/ftp/ftp_grpc.pb.go @@ -8,6 +8,7 @@ package ftp import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/ftp_server/ftp_server.go b/Sources/ftp_server/ftp_server.go index 946e5c8..a839dd6 100644 --- a/Sources/ftp_server/ftp_server.go +++ b/Sources/ftp_server/ftp_server.go @@ -9,24 +9,21 @@ type ServiceImpl struct { } /* - Set root directory. - - This is the directory that can then be accessed by a client. - The directory needs to exist when this is called. - The permissions are the same as the file permission for the user running the server. - The root directory can't be changed while an FTP process is in progress. - - Parameters - ---------- - path string - +SetRootDir Set root directory. + This is the directory that can then be accessed by a client. + The directory needs to exist when this is called. + The permissions are the same as the file permission for the user running the server. + The root directory can't be changed while an FTP process is in progress. */ +func (s *ServiceImpl) SetRootDir( + ctx context.Context, + path string, -func (s *ServiceImpl) SetRootDir(ctx context.Context, path string) (*SetRootDirResponse, error) { - - request := &SetRootDirRequest{} - request.Path = path +) (*SetRootDirResponse, error) { + request := &SetRootDirRequest{ + Path: path, + } response, err := s.Client.SetRootDir(ctx, request) if err != nil { return nil, err diff --git a/Sources/ftp_server/ftp_server.pb.go b/Sources/ftp_server/ftp_server.pb.go index b4b9ac5..a4220de 100644 --- a/Sources/ftp_server/ftp_server.pb.go +++ b/Sources/ftp_server/ftp_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: ftp_server.proto package ftp_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -83,11 +84,9 @@ type SetRootDirRequest struct { func (x *SetRootDirRequest) Reset() { *x = SetRootDirRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRootDirRequest) String() string { @@ -98,7 +97,7 @@ func (*SetRootDirRequest) ProtoMessage() {} func (x *SetRootDirRequest) ProtoReflect() protoreflect.Message { mi := &file_ftp_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -130,11 +129,9 @@ type SetRootDirResponse struct { func (x *SetRootDirResponse) Reset() { *x = SetRootDirResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRootDirResponse) String() string { @@ -145,7 +142,7 @@ func (*SetRootDirResponse) ProtoMessage() {} func (x *SetRootDirResponse) ProtoReflect() protoreflect.Message { mi := &file_ftp_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -179,11 +176,9 @@ type FtpServerResult struct { func (x *FtpServerResult) Reset() { *x = FtpServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_ftp_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_ftp_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FtpServerResult) String() string { @@ -194,7 +189,7 @@ func (*FtpServerResult) ProtoMessage() {} func (x *FtpServerResult) ProtoReflect() protoreflect.Message { mi := &file_ftp_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -302,45 +297,6 @@ func file_ftp_server_proto_init() { if File_ftp_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_ftp_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SetRootDirRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SetRootDirResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_ftp_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*FtpServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/ftp_server/ftp_server_grpc.pb.go b/Sources/ftp_server/ftp_server_grpc.pb.go index bce557a..ad5f8c7 100644 --- a/Sources/ftp_server/ftp_server_grpc.pb.go +++ b/Sources/ftp_server/ftp_server_grpc.pb.go @@ -8,6 +8,7 @@ package ftp_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/geofence/geofence.go b/Sources/geofence/geofence.go index baa49fe..2900b9e 100644 --- a/Sources/geofence/geofence.go +++ b/Sources/geofence/geofence.go @@ -9,24 +9,19 @@ type ServiceImpl struct { } /* - Upload geofences. - - Polygon and Circular geofences are uploaded to a drone. Once uploaded, the geofence will remain - on the drone even if a connection is lost. - - Parameters - ---------- - geofenceData *GeofenceData - - +UploadGeofence Upload geofences. + Polygon and Circular geofences are uploaded to a drone. Once uploaded, the geofence will remain + on the drone even if a connection is lost. */ +func (s *ServiceImpl) UploadGeofence( + ctx context.Context, + geofenceData *GeofenceData, -func (s *ServiceImpl) UploadGeofence(ctx context.Context, geofenceData *GeofenceData) (*UploadGeofenceResponse, error) { - - request := &UploadGeofenceRequest{} - request.GeofenceData = geofenceData - +) (*UploadGeofenceResponse, error) { + request := &UploadGeofenceRequest{ + GeofenceData: geofenceData, + } response, err := s.Client.UploadGeofence(ctx, request) if err != nil { return nil, err @@ -35,13 +30,12 @@ func (s *ServiceImpl) UploadGeofence(ctx context.Context, geofenceData *Geofence } /* - Clear all geofences saved on the vehicle. - - +ClearGeofence Clear all geofences saved on the vehicle. */ +func (s *ServiceImpl) ClearGeofence( + ctx context.Context, -func (s *ServiceImpl) ClearGeofence(ctx context.Context) (*ClearGeofenceResponse, error) { - +) (*ClearGeofenceResponse, error) { request := &ClearGeofenceRequest{} response, err := s.Client.ClearGeofence(ctx, request) if err != nil { diff --git a/Sources/geofence/geofence.pb.go b/Sources/geofence/geofence.pb.go index e786198..17e718e 100644 --- a/Sources/geofence/geofence.pb.go +++ b/Sources/geofence/geofence.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: geofence.proto package geofence import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -144,11 +145,9 @@ type Point struct { func (x *Point) Reset() { *x = Point{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Point) String() string { @@ -159,7 +158,7 @@ func (*Point) ProtoMessage() {} func (x *Point) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -200,11 +199,9 @@ type Polygon struct { func (x *Polygon) Reset() { *x = Polygon{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Polygon) String() string { @@ -215,7 +212,7 @@ func (*Polygon) ProtoMessage() {} func (x *Polygon) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -257,11 +254,9 @@ type Circle struct { func (x *Circle) Reset() { *x = Circle{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Circle) String() string { @@ -272,7 +267,7 @@ func (*Circle) ProtoMessage() {} func (x *Circle) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -320,11 +315,9 @@ type GeofenceData struct { func (x *GeofenceData) Reset() { *x = GeofenceData{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GeofenceData) String() string { @@ -335,7 +328,7 @@ func (*GeofenceData) ProtoMessage() {} func (x *GeofenceData) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -374,11 +367,9 @@ type UploadGeofenceRequest struct { func (x *UploadGeofenceRequest) Reset() { *x = UploadGeofenceRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadGeofenceRequest) String() string { @@ -389,7 +380,7 @@ func (*UploadGeofenceRequest) ProtoMessage() {} func (x *UploadGeofenceRequest) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -421,11 +412,9 @@ type UploadGeofenceResponse struct { func (x *UploadGeofenceResponse) Reset() { *x = UploadGeofenceResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadGeofenceResponse) String() string { @@ -436,7 +425,7 @@ func (*UploadGeofenceResponse) ProtoMessage() {} func (x *UploadGeofenceResponse) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -466,11 +455,9 @@ type ClearGeofenceRequest struct { func (x *ClearGeofenceRequest) Reset() { *x = ClearGeofenceRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearGeofenceRequest) String() string { @@ -481,7 +468,7 @@ func (*ClearGeofenceRequest) ProtoMessage() {} func (x *ClearGeofenceRequest) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -506,11 +493,9 @@ type ClearGeofenceResponse struct { func (x *ClearGeofenceResponse) Reset() { *x = ClearGeofenceResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearGeofenceResponse) String() string { @@ -521,7 +506,7 @@ func (*ClearGeofenceResponse) ProtoMessage() {} func (x *ClearGeofenceResponse) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -555,11 +540,9 @@ type GeofenceResult struct { func (x *GeofenceResult) Reset() { *x = GeofenceResult{} - if protoimpl.UnsafeEnabled { - mi := &file_geofence_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_geofence_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GeofenceResult) String() string { @@ -570,7 +553,7 @@ func (*GeofenceResult) ProtoMessage() {} func (x *GeofenceResult) ProtoReflect() protoreflect.Message { mi := &file_geofence_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -754,117 +737,6 @@ func file_geofence_proto_init() { if File_geofence_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_geofence_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*Point); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*Polygon); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*Circle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*GeofenceData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*UploadGeofenceRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*UploadGeofenceResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*ClearGeofenceRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*ClearGeofenceResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_geofence_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*GeofenceResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/geofence/geofence_grpc.pb.go b/Sources/geofence/geofence_grpc.pb.go index cf90ccf..49e128e 100644 --- a/Sources/geofence/geofence_grpc.pb.go +++ b/Sources/geofence/geofence_grpc.pb.go @@ -8,6 +8,7 @@ package geofence import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/gimbal/gimbal.go b/Sources/gimbal/gimbal.go index be94493..021a20f 100644 --- a/Sources/gimbal/gimbal.go +++ b/Sources/gimbal/gimbal.go @@ -2,11 +2,11 @@ package gimbal import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,29 +14,24 @@ type ServiceImpl struct { } /* - Set gimbal roll, pitch and yaw angles. - - This sets the desired roll, pitch and yaw angles of a gimbal. - Will return when the command is accepted, however, it might - take the gimbal longer to actually be set to the new angles. - - Parameters - ---------- - rollDeg float32 - - pitchDeg float32 - - yawDeg float32 - +SetAngles Set gimbal roll, pitch and yaw angles. + This sets the desired roll, pitch and yaw angles of a gimbal. + Will return when the command is accepted, however, it might + take the gimbal longer to actually be set to the new angles. */ - -func (s *ServiceImpl) SetAngles(ctx context.Context, rollDeg float32, pitchDeg float32, yawDeg float32) (*SetAnglesResponse, error) { - - request := &SetAnglesRequest{} - request.RollDeg = rollDeg - request.PitchDeg = pitchDeg - request.YawDeg = yawDeg +func (s *ServiceImpl) SetAngles( + ctx context.Context, + rollDeg float32, + pitchDeg float32, + yawDeg float32, + +) (*SetAnglesResponse, error) { + request := &SetAnglesRequest{ + RollDeg: rollDeg, + PitchDeg: pitchDeg, + YawDeg: yawDeg, + } response, err := s.Client.SetAngles(ctx, request) if err != nil { return nil, err @@ -45,26 +40,22 @@ func (s *ServiceImpl) SetAngles(ctx context.Context, rollDeg float32, pitchDeg f } /* - Set gimbal pitch and yaw angles. - - This sets the desired pitch and yaw angles of a gimbal. - Will return when the command is accepted, however, it might - take the gimbal longer to actually be set to the new angles. - - Parameters - ---------- - pitchDeg float32 - - yawDeg float32 - +SetPitchAndYaw Set gimbal pitch and yaw angles. + This sets the desired pitch and yaw angles of a gimbal. + Will return when the command is accepted, however, it might + take the gimbal longer to actually be set to the new angles. */ - -func (s *ServiceImpl) SetPitchAndYaw(ctx context.Context, pitchDeg float32, yawDeg float32) (*SetPitchAndYawResponse, error) { - - request := &SetPitchAndYawRequest{} - request.PitchDeg = pitchDeg - request.YawDeg = yawDeg +func (s *ServiceImpl) SetPitchAndYaw( + ctx context.Context, + pitchDeg float32, + yawDeg float32, + +) (*SetPitchAndYawResponse, error) { + request := &SetPitchAndYawRequest{ + PitchDeg: pitchDeg, + YawDeg: yawDeg, + } response, err := s.Client.SetPitchAndYaw(ctx, request) if err != nil { return nil, err @@ -73,26 +64,22 @@ func (s *ServiceImpl) SetPitchAndYaw(ctx context.Context, pitchDeg float32, yawD } /* - Set gimbal angular rates around pitch and yaw axes. - - This sets the desired angular rates around pitch and yaw axes of a gimbal. - Will return when the command is accepted, however, it might - take the gimbal longer to actually reach the angular rate. - - Parameters - ---------- - pitchRateDegS float32 - - yawRateDegS float32 - +SetPitchRateAndYawRate Set gimbal angular rates around pitch and yaw axes. + This sets the desired angular rates around pitch and yaw axes of a gimbal. + Will return when the command is accepted, however, it might + take the gimbal longer to actually reach the angular rate. */ - -func (s *ServiceImpl) SetPitchRateAndYawRate(ctx context.Context, pitchRateDegS float32, yawRateDegS float32) (*SetPitchRateAndYawRateResponse, error) { - - request := &SetPitchRateAndYawRateRequest{} - request.PitchRateDegS = pitchRateDegS - request.YawRateDegS = yawRateDegS +func (s *ServiceImpl) SetPitchRateAndYawRate( + ctx context.Context, + pitchRateDegS float32, + yawRateDegS float32, + +) (*SetPitchRateAndYawRateResponse, error) { + request := &SetPitchRateAndYawRateRequest{ + PitchRateDegS: pitchRateDegS, + YawRateDegS: yawRateDegS, + } response, err := s.Client.SetPitchRateAndYawRate(ctx, request) if err != nil { return nil, err @@ -101,24 +88,20 @@ func (s *ServiceImpl) SetPitchRateAndYawRate(ctx context.Context, pitchRateDegS } /* - Set gimbal mode. - - This sets the desired yaw mode of a gimbal. - Will return when the command is accepted. However, it might - take the gimbal longer to actually be set to the new angles. - - Parameters - ---------- - gimbalMode *GimbalMode - - +SetMode Set gimbal mode. + This sets the desired yaw mode of a gimbal. + Will return when the command is accepted. However, it might + take the gimbal longer to actually be set to the new angles. */ +func (s *ServiceImpl) SetMode( + ctx context.Context, + gimbalMode *GimbalMode, -func (s *ServiceImpl) SetMode(ctx context.Context, gimbalMode *GimbalMode) (*SetModeResponse, error) { - - request := &SetModeRequest{} - request.GimbalMode = *gimbalMode +) (*SetModeResponse, error) { + request := &SetModeRequest{ + GimbalMode: *gimbalMode, + } response, err := s.Client.SetMode(ctx, request) if err != nil { return nil, err @@ -127,31 +110,26 @@ func (s *ServiceImpl) SetMode(ctx context.Context, gimbalMode *GimbalMode) (*Set } /* - Set gimbal region of interest (ROI). - - This sets a region of interest that the gimbal will point to. - The gimbal will continue to point to the specified region until it - receives a new command. - The function will return when the command is accepted, however, it might - take the gimbal longer to actually rotate to the ROI. - - Parameters - ---------- - latitudeDeg float64 - - longitudeDeg float64 - - altitudeM float32 - +SetRoiLocation Set gimbal region of interest (ROI). + This sets a region of interest that the gimbal will point to. + The gimbal will continue to point to the specified region until it + receives a new command. + The function will return when the command is accepted, however, it might + take the gimbal longer to actually rotate to the ROI. */ - -func (s *ServiceImpl) SetRoiLocation(ctx context.Context, latitudeDeg float64, longitudeDeg float64, altitudeM float32) (*SetRoiLocationResponse, error) { - - request := &SetRoiLocationRequest{} - request.LatitudeDeg = latitudeDeg - request.LongitudeDeg = longitudeDeg - request.AltitudeM = altitudeM +func (s *ServiceImpl) SetRoiLocation( + ctx context.Context, + latitudeDeg float64, + longitudeDeg float64, + altitudeM float32, + +) (*SetRoiLocationResponse, error) { + request := &SetRoiLocationRequest{ + LatitudeDeg: latitudeDeg, + LongitudeDeg: longitudeDeg, + AltitudeM: altitudeM, + } response, err := s.Client.SetRoiLocation(ctx, request) if err != nil { return nil, err @@ -160,28 +138,24 @@ func (s *ServiceImpl) SetRoiLocation(ctx context.Context, latitudeDeg float64, l } /* - Take control. - - There can be only two components in control of a gimbal at any given time. - One with "primary" control, and one with "secondary" control. The way the - secondary control is implemented is not specified and hence depends on the - vehicle. - - Components are expected to be cooperative, which means that they can - override each other and should therefore do it carefully. - - Parameters - ---------- - controlMode *ControlMode - +TakeControl Take control. + There can be only two components in control of a gimbal at any given time. + One with "primary" control, and one with "secondary" control. The way the + secondary control is implemented is not specified and hence depends on the + vehicle. + Components are expected to be cooperative, which means that they can + override each other and should therefore do it carefully. */ +func (s *ServiceImpl) TakeControl( + ctx context.Context, + controlMode *ControlMode, -func (s *ServiceImpl) TakeControl(ctx context.Context, controlMode *ControlMode) (*TakeControlResponse, error) { - - request := &TakeControlRequest{} - request.ControlMode = *controlMode +) (*TakeControlResponse, error) { + request := &TakeControlRequest{ + ControlMode: *controlMode, + } response, err := s.Client.TakeControl(ctx, request) if err != nil { return nil, err @@ -190,15 +164,14 @@ func (s *ServiceImpl) TakeControl(ctx context.Context, controlMode *ControlMode) } /* - Release control. - - Release control, such that other components can control the gimbal. - +ReleaseControl Release control. + Release control, such that other components can control the gimbal. */ +func (s *ServiceImpl) ReleaseControl( + ctx context.Context, -func (s *ServiceImpl) ReleaseControl(ctx context.Context) (*ReleaseControlResponse, error) { - +) (*ReleaseControlResponse, error) { request := &ReleaseControlRequest{} response, err := s.Client.ReleaseControl(ctx, request) if err != nil { @@ -208,16 +181,16 @@ func (s *ServiceImpl) ReleaseControl(ctx context.Context) (*ReleaseControlRespon } /* - Subscribe to control status updates. - - This allows a component to know if it has primary, secondary or - no control over the gimbal. Also, it gives the system and component ids - of the other components in control (if any). - +Control Subscribe to control status updates. + This allows a component to know if it has primary, secondary or + no control over the gimbal. Also, it gives the system and component ids + of the other components in control (if any). */ +func (a *ServiceImpl) Control( + ctx context.Context, -func (a *ServiceImpl) Control(ctx context.Context) (<-chan *ControlStatus, error) { +) (<-chan *ControlStatus, error) { ch := make(chan *ControlStatus) request := &SubscribeControlRequest{} stream, err := a.Client.SubscribeControl(ctx, request) @@ -236,8 +209,7 @@ func (a *ServiceImpl) Control(ctx context.Context) (<-chan *ControlStatus, error if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Control messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Control messages, err: %v", err) } ch <- m.GetControlStatus() } @@ -246,14 +218,14 @@ func (a *ServiceImpl) Control(ctx context.Context) (<-chan *ControlStatus, error } /* - Subscribe to attitude updates. - - This gets you the gimbal's attitude and angular rate. - +Attitude Subscribe to attitude updates. + This gets you the gimbal's attitude and angular rate. */ +func (a *ServiceImpl) Attitude( + ctx context.Context, -func (a *ServiceImpl) Attitude(ctx context.Context) (<-chan *Attitude, error) { +) (<-chan *Attitude, error) { ch := make(chan *Attitude) request := &SubscribeAttitudeRequest{} stream, err := a.Client.SubscribeAttitude(ctx, request) @@ -272,8 +244,7 @@ func (a *ServiceImpl) Attitude(ctx context.Context) (<-chan *Attitude, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Attitude messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Attitude messages, err: %v", err) } ch <- m.GetAttitude() } diff --git a/Sources/gimbal/gimbal.pb.go b/Sources/gimbal/gimbal.pb.go index 9f2ba4f..8d01191 100644 --- a/Sources/gimbal/gimbal.pb.go +++ b/Sources/gimbal/gimbal.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: gimbal.proto package gimbal import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -188,11 +189,9 @@ type SetAnglesRequest struct { func (x *SetAnglesRequest) Reset() { *x = SetAnglesRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAnglesRequest) String() string { @@ -203,7 +202,7 @@ func (*SetAnglesRequest) ProtoMessage() {} func (x *SetAnglesRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -249,11 +248,9 @@ type SetAnglesResponse struct { func (x *SetAnglesResponse) Reset() { *x = SetAnglesResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAnglesResponse) String() string { @@ -264,7 +261,7 @@ func (*SetAnglesResponse) ProtoMessage() {} func (x *SetAnglesResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -297,11 +294,9 @@ type SetPitchAndYawRequest struct { func (x *SetPitchAndYawRequest) Reset() { *x = SetPitchAndYawRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPitchAndYawRequest) String() string { @@ -312,7 +307,7 @@ func (*SetPitchAndYawRequest) ProtoMessage() {} func (x *SetPitchAndYawRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -351,11 +346,9 @@ type SetPitchAndYawResponse struct { func (x *SetPitchAndYawResponse) Reset() { *x = SetPitchAndYawResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPitchAndYawResponse) String() string { @@ -366,7 +359,7 @@ func (*SetPitchAndYawResponse) ProtoMessage() {} func (x *SetPitchAndYawResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -399,11 +392,9 @@ type SetPitchRateAndYawRateRequest struct { func (x *SetPitchRateAndYawRateRequest) Reset() { *x = SetPitchRateAndYawRateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPitchRateAndYawRateRequest) String() string { @@ -414,7 +405,7 @@ func (*SetPitchRateAndYawRateRequest) ProtoMessage() {} func (x *SetPitchRateAndYawRateRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -453,11 +444,9 @@ type SetPitchRateAndYawRateResponse struct { func (x *SetPitchRateAndYawRateResponse) Reset() { *x = SetPitchRateAndYawRateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPitchRateAndYawRateResponse) String() string { @@ -468,7 +457,7 @@ func (*SetPitchRateAndYawRateResponse) ProtoMessage() {} func (x *SetPitchRateAndYawRateResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -500,11 +489,9 @@ type SetModeRequest struct { func (x *SetModeRequest) Reset() { *x = SetModeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetModeRequest) String() string { @@ -515,7 +502,7 @@ func (*SetModeRequest) ProtoMessage() {} func (x *SetModeRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -547,11 +534,9 @@ type SetModeResponse struct { func (x *SetModeResponse) Reset() { *x = SetModeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetModeResponse) String() string { @@ -562,7 +547,7 @@ func (*SetModeResponse) ProtoMessage() {} func (x *SetModeResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -596,11 +581,9 @@ type SetRoiLocationRequest struct { func (x *SetRoiLocationRequest) Reset() { *x = SetRoiLocationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRoiLocationRequest) String() string { @@ -611,7 +594,7 @@ func (*SetRoiLocationRequest) ProtoMessage() {} func (x *SetRoiLocationRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -657,11 +640,9 @@ type SetRoiLocationResponse struct { func (x *SetRoiLocationResponse) Reset() { *x = SetRoiLocationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRoiLocationResponse) String() string { @@ -672,7 +653,7 @@ func (*SetRoiLocationResponse) ProtoMessage() {} func (x *SetRoiLocationResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -704,11 +685,9 @@ type TakeControlRequest struct { func (x *TakeControlRequest) Reset() { *x = TakeControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakeControlRequest) String() string { @@ -719,7 +698,7 @@ func (*TakeControlRequest) ProtoMessage() {} func (x *TakeControlRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -751,11 +730,9 @@ type TakeControlResponse struct { func (x *TakeControlResponse) Reset() { *x = TakeControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TakeControlResponse) String() string { @@ -766,7 +743,7 @@ func (*TakeControlResponse) ProtoMessage() {} func (x *TakeControlResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -796,11 +773,9 @@ type ReleaseControlRequest struct { func (x *ReleaseControlRequest) Reset() { *x = ReleaseControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReleaseControlRequest) String() string { @@ -811,7 +786,7 @@ func (*ReleaseControlRequest) ProtoMessage() {} func (x *ReleaseControlRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -836,11 +811,9 @@ type ReleaseControlResponse struct { func (x *ReleaseControlResponse) Reset() { *x = ReleaseControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReleaseControlResponse) String() string { @@ -851,7 +824,7 @@ func (*ReleaseControlResponse) ProtoMessage() {} func (x *ReleaseControlResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -881,11 +854,9 @@ type SubscribeControlRequest struct { func (x *SubscribeControlRequest) Reset() { *x = SubscribeControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeControlRequest) String() string { @@ -896,7 +867,7 @@ func (*SubscribeControlRequest) ProtoMessage() {} func (x *SubscribeControlRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -921,11 +892,9 @@ type ControlResponse struct { func (x *ControlResponse) Reset() { *x = ControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ControlResponse) String() string { @@ -936,7 +905,7 @@ func (*ControlResponse) ProtoMessage() {} func (x *ControlResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -979,11 +948,9 @@ type Quaternion struct { func (x *Quaternion) Reset() { *x = Quaternion{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Quaternion) String() string { @@ -994,7 +961,7 @@ func (*Quaternion) ProtoMessage() {} func (x *Quaternion) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1056,11 +1023,9 @@ type EulerAngle struct { func (x *EulerAngle) Reset() { *x = EulerAngle{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *EulerAngle) String() string { @@ -1071,7 +1036,7 @@ func (*EulerAngle) ProtoMessage() {} func (x *EulerAngle) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1120,11 +1085,9 @@ type AngularVelocityBody struct { func (x *AngularVelocityBody) Reset() { *x = AngularVelocityBody{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngularVelocityBody) String() string { @@ -1135,7 +1098,7 @@ func (*AngularVelocityBody) ProtoMessage() {} func (x *AngularVelocityBody) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1187,11 +1150,9 @@ type Attitude struct { func (x *Attitude) Reset() { *x = Attitude{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Attitude) String() string { @@ -1202,7 +1163,7 @@ func (*Attitude) ProtoMessage() {} func (x *Attitude) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1267,11 +1228,9 @@ type SubscribeAttitudeRequest struct { func (x *SubscribeAttitudeRequest) Reset() { *x = SubscribeAttitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeAttitudeRequest) String() string { @@ -1282,7 +1241,7 @@ func (*SubscribeAttitudeRequest) ProtoMessage() {} func (x *SubscribeAttitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1307,11 +1266,9 @@ type AttitudeResponse struct { func (x *AttitudeResponse) Reset() { *x = AttitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AttitudeResponse) String() string { @@ -1322,7 +1279,7 @@ func (*AttitudeResponse) ProtoMessage() {} func (x *AttitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1359,11 +1316,9 @@ type ControlStatus struct { func (x *ControlStatus) Reset() { *x = ControlStatus{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ControlStatus) String() string { @@ -1374,7 +1329,7 @@ func (*ControlStatus) ProtoMessage() {} func (x *ControlStatus) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1436,11 +1391,9 @@ type GimbalResult struct { func (x *GimbalResult) Reset() { *x = GimbalResult{} - if protoimpl.UnsafeEnabled { - mi := &file_gimbal_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gimbal_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GimbalResult) String() string { @@ -1451,7 +1404,7 @@ func (*GimbalResult) ProtoMessage() {} func (x *GimbalResult) ProtoReflect() protoreflect.Message { mi := &file_gimbal_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1831,297 +1784,6 @@ func file_gimbal_proto_init() { if File_gimbal_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_gimbal_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SetAnglesRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SetAnglesResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetPitchAndYawRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetPitchAndYawResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SetPitchRateAndYawRateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*SetPitchRateAndYawRateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SetModeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*SetModeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SetRoiLocationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*SetRoiLocationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*TakeControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*TakeControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*ReleaseControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*ReleaseControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*ControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*Quaternion); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*EulerAngle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*AngularVelocityBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*Attitude); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeAttitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*AttitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*ControlStatus); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gimbal_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*GimbalResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/gimbal/gimbal_grpc.pb.go b/Sources/gimbal/gimbal_grpc.pb.go index 403d7cf..8501803 100644 --- a/Sources/gimbal/gimbal_grpc.pb.go +++ b/Sources/gimbal/gimbal_grpc.pb.go @@ -8,6 +8,7 @@ package gimbal import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/gripper/gripper.go b/Sources/gripper/gripper.go index e175b3d..6a86fe7 100644 --- a/Sources/gripper/gripper.go +++ b/Sources/gripper/gripper.go @@ -9,19 +9,16 @@ type ServiceImpl struct { } /* - Gripper grab cargo. - - Parameters - ---------- - instance uint32 - - +Grab Gripper grab cargo. */ +func (s *ServiceImpl) Grab( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Grab(ctx context.Context, instance uint32) (*GrabResponse, error) { - - request := &GrabRequest{} - request.Instance = instance +) (*GrabResponse, error) { + request := &GrabRequest{ + Instance: instance, + } response, err := s.Client.Grab(ctx, request) if err != nil { return nil, err @@ -30,19 +27,16 @@ func (s *ServiceImpl) Grab(ctx context.Context, instance uint32) (*GrabResponse, } /* - Gripper release cargo. - - Parameters - ---------- - instance uint32 - - +Release Gripper release cargo. */ +func (s *ServiceImpl) Release( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Release(ctx context.Context, instance uint32) (*ReleaseResponse, error) { - - request := &ReleaseRequest{} - request.Instance = instance +) (*ReleaseResponse, error) { + request := &ReleaseRequest{ + Instance: instance, + } response, err := s.Client.Release(ctx, request) if err != nil { return nil, err diff --git a/Sources/gripper/gripper.pb.go b/Sources/gripper/gripper.pb.go index b6b41b0..43546e9 100644 --- a/Sources/gripper/gripper.pb.go +++ b/Sources/gripper/gripper.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: gripper.proto package gripper import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -142,11 +143,9 @@ type GrabRequest struct { func (x *GrabRequest) Reset() { *x = GrabRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gripper_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gripper_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GrabRequest) String() string { @@ -157,7 +156,7 @@ func (*GrabRequest) ProtoMessage() {} func (x *GrabRequest) ProtoReflect() protoreflect.Message { mi := &file_gripper_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -189,11 +188,9 @@ type GrabResponse struct { func (x *GrabResponse) Reset() { *x = GrabResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gripper_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gripper_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GrabResponse) String() string { @@ -204,7 +201,7 @@ func (*GrabResponse) ProtoMessage() {} func (x *GrabResponse) ProtoReflect() protoreflect.Message { mi := &file_gripper_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -236,11 +233,9 @@ type ReleaseRequest struct { func (x *ReleaseRequest) Reset() { *x = ReleaseRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_gripper_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gripper_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReleaseRequest) String() string { @@ -251,7 +246,7 @@ func (*ReleaseRequest) ProtoMessage() {} func (x *ReleaseRequest) ProtoReflect() protoreflect.Message { mi := &file_gripper_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -283,11 +278,9 @@ type ReleaseResponse struct { func (x *ReleaseResponse) Reset() { *x = ReleaseResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_gripper_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gripper_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReleaseResponse) String() string { @@ -298,7 +291,7 @@ func (*ReleaseResponse) ProtoMessage() {} func (x *ReleaseResponse) ProtoReflect() protoreflect.Message { mi := &file_gripper_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -332,11 +325,9 @@ type GripperResult struct { func (x *GripperResult) Reset() { *x = GripperResult{} - if protoimpl.UnsafeEnabled { - mi := &file_gripper_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_gripper_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GripperResult) String() string { @@ -347,7 +338,7 @@ func (*GripperResult) ProtoMessage() {} func (x *GripperResult) ProtoReflect() protoreflect.Message { mi := &file_gripper_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -478,68 +469,6 @@ func file_gripper_proto_init() { if File_gripper_proto != nil { return } - if !protoimpl.UnsafeEnabled { - file_gripper_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*GrabRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gripper_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*GrabResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gripper_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*ReleaseRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gripper_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*ReleaseResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_gripper_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*GripperResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/gripper/gripper_grpc.pb.go b/Sources/gripper/gripper_grpc.pb.go index d9de456..1721397 100644 --- a/Sources/gripper/gripper_grpc.pb.go +++ b/Sources/gripper/gripper_grpc.pb.go @@ -8,6 +8,7 @@ package gripper import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/info/info.go b/Sources/info/info.go index dd430c6..61977a5 100644 --- a/Sources/info/info.go +++ b/Sources/info/info.go @@ -2,11 +2,11 @@ package info import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,132 +14,87 @@ type ServiceImpl struct { } /* - Get flight information of the system. - - - - Returns - ------- - False - FlightInfo : FlightInfo - Flight information of the system - - +GetFlightInformation Get flight information of the system. */ +func (s *ServiceImpl) GetFlightInformation( + ctx context.Context, -func (s *ServiceImpl) GetFlightInformation(ctx context.Context) (*GetFlightInformationResponse, error) { +) (*GetFlightInformationResponse, error) { request := &GetFlightInformationRequest{} response, err := s.Client.GetFlightInformation(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Get the identification of the system. - - - - Returns - ------- - False - Identification : Identification - Identification of the system - - +GetIdentification Get the identification of the system. */ +func (s *ServiceImpl) GetIdentification( + ctx context.Context, -func (s *ServiceImpl) GetIdentification(ctx context.Context) (*GetIdentificationResponse, error) { +) (*GetIdentificationResponse, error) { request := &GetIdentificationRequest{} response, err := s.Client.GetIdentification(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Get product information of the system. - - - - Returns - ------- - False - Product : Product - Product information of the system - - +GetProduct Get product information of the system. */ +func (s *ServiceImpl) GetProduct( + ctx context.Context, -func (s *ServiceImpl) GetProduct(ctx context.Context) (*GetProductResponse, error) { +) (*GetProductResponse, error) { request := &GetProductRequest{} response, err := s.Client.GetProduct(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Get the version information of the system. - - - - Returns - ------- - False - Version : Version - Version information about the system - - +GetVersion Get the version information of the system. */ +func (s *ServiceImpl) GetVersion( + ctx context.Context, -func (s *ServiceImpl) GetVersion(ctx context.Context) (*GetVersionResponse, error) { +) (*GetVersionResponse, error) { request := &GetVersionRequest{} response, err := s.Client.GetVersion(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Get the speed factor of a simulation (with lockstep a simulation can run faster or slower than realtime). - - - - Returns - ------- - False - SpeedFactor : float64 - Speed factor of simulation - - +GetSpeedFactor Get the speed factor of a simulation (with lockstep a simulation can run faster or slower than realtime). */ +func (s *ServiceImpl) GetSpeedFactor( + ctx context.Context, -func (s *ServiceImpl) GetSpeedFactor(ctx context.Context) (*GetSpeedFactorResponse, error) { +) (*GetSpeedFactorResponse, error) { request := &GetSpeedFactorRequest{} response, err := s.Client.GetSpeedFactor(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Subscribe to 'flight information' updates. - - +FlightInformation Subscribe to 'flight information' updates. */ +func (a *ServiceImpl) FlightInformation( + ctx context.Context, -func (a *ServiceImpl) FlightInformation(ctx context.Context) (<-chan *FlightInfo, error) { +) (<-chan *FlightInfo, error) { ch := make(chan *FlightInfo) request := &SubscribeFlightInformationRequest{} stream, err := a.Client.SubscribeFlightInformation(ctx, request) @@ -158,8 +113,7 @@ func (a *ServiceImpl) FlightInformation(ctx context.Context) (<-chan *FlightInfo if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive FlightInformation messages, err: %v\n", err) - break + log.Fatalf("Unable to receive FlightInformation messages, err: %v", err) } ch <- m.GetFlightInfo() } diff --git a/Sources/info/info.pb.go b/Sources/info/info.pb.go index 4b9bc6e..2111543 100644 --- a/Sources/info/info.pb.go +++ b/Sources/info/info.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: info.proto package info import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -140,11 +141,9 @@ type GetFlightInformationRequest struct { func (x *GetFlightInformationRequest) Reset() { *x = GetFlightInformationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetFlightInformationRequest) String() string { @@ -155,7 +154,7 @@ func (*GetFlightInformationRequest) ProtoMessage() {} func (x *GetFlightInformationRequest) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -181,11 +180,9 @@ type GetFlightInformationResponse struct { func (x *GetFlightInformationResponse) Reset() { *x = GetFlightInformationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetFlightInformationResponse) String() string { @@ -196,7 +193,7 @@ func (*GetFlightInformationResponse) ProtoMessage() {} func (x *GetFlightInformationResponse) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -233,11 +230,9 @@ type GetIdentificationRequest struct { func (x *GetIdentificationRequest) Reset() { *x = GetIdentificationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetIdentificationRequest) String() string { @@ -248,7 +243,7 @@ func (*GetIdentificationRequest) ProtoMessage() {} func (x *GetIdentificationRequest) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -274,11 +269,9 @@ type GetIdentificationResponse struct { func (x *GetIdentificationResponse) Reset() { *x = GetIdentificationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetIdentificationResponse) String() string { @@ -289,7 +282,7 @@ func (*GetIdentificationResponse) ProtoMessage() {} func (x *GetIdentificationResponse) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -326,11 +319,9 @@ type GetProductRequest struct { func (x *GetProductRequest) Reset() { *x = GetProductRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetProductRequest) String() string { @@ -341,7 +332,7 @@ func (*GetProductRequest) ProtoMessage() {} func (x *GetProductRequest) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -367,11 +358,9 @@ type GetProductResponse struct { func (x *GetProductResponse) Reset() { *x = GetProductResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetProductResponse) String() string { @@ -382,7 +371,7 @@ func (*GetProductResponse) ProtoMessage() {} func (x *GetProductResponse) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -419,11 +408,9 @@ type GetVersionRequest struct { func (x *GetVersionRequest) Reset() { *x = GetVersionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetVersionRequest) String() string { @@ -434,7 +421,7 @@ func (*GetVersionRequest) ProtoMessage() {} func (x *GetVersionRequest) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -460,11 +447,9 @@ type GetVersionResponse struct { func (x *GetVersionResponse) Reset() { *x = GetVersionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetVersionResponse) String() string { @@ -475,7 +460,7 @@ func (*GetVersionResponse) ProtoMessage() {} func (x *GetVersionResponse) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -512,11 +497,9 @@ type GetSpeedFactorRequest struct { func (x *GetSpeedFactorRequest) Reset() { *x = GetSpeedFactorRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetSpeedFactorRequest) String() string { @@ -527,7 +510,7 @@ func (*GetSpeedFactorRequest) ProtoMessage() {} func (x *GetSpeedFactorRequest) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -553,11 +536,9 @@ type GetSpeedFactorResponse struct { func (x *GetSpeedFactorResponse) Reset() { *x = GetSpeedFactorResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetSpeedFactorResponse) String() string { @@ -568,7 +549,7 @@ func (*GetSpeedFactorResponse) ProtoMessage() {} func (x *GetSpeedFactorResponse) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -605,11 +586,9 @@ type SubscribeFlightInformationRequest struct { func (x *SubscribeFlightInformationRequest) Reset() { *x = SubscribeFlightInformationRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeFlightInformationRequest) String() string { @@ -620,7 +599,7 @@ func (*SubscribeFlightInformationRequest) ProtoMessage() {} func (x *SubscribeFlightInformationRequest) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -645,11 +624,9 @@ type FlightInformationResponse struct { func (x *FlightInformationResponse) Reset() { *x = FlightInformationResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FlightInformationResponse) String() string { @@ -660,7 +637,7 @@ func (*FlightInformationResponse) ProtoMessage() {} func (x *FlightInformationResponse) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -696,11 +673,9 @@ type FlightInfo struct { func (x *FlightInfo) Reset() { *x = FlightInfo{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FlightInfo) String() string { @@ -711,7 +686,7 @@ func (*FlightInfo) ProtoMessage() {} func (x *FlightInfo) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -766,11 +741,9 @@ type Identification struct { func (x *Identification) Reset() { *x = Identification{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Identification) String() string { @@ -781,7 +754,7 @@ func (*Identification) ProtoMessage() {} func (x *Identification) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -824,11 +797,9 @@ type Product struct { func (x *Product) Reset() { *x = Product{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Product) String() string { @@ -839,7 +810,7 @@ func (*Product) ProtoMessage() {} func (x *Product) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -904,11 +875,9 @@ type Version struct { func (x *Version) Reset() { *x = Version{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Version) String() string { @@ -919,7 +888,7 @@ func (*Version) ProtoMessage() {} func (x *Version) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1030,11 +999,9 @@ type InfoResult struct { func (x *InfoResult) Reset() { *x = InfoResult{} - if protoimpl.UnsafeEnabled { - mi := &file_info_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_info_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *InfoResult) String() string { @@ -1045,7 +1012,7 @@ func (*InfoResult) ProtoMessage() {} func (x *InfoResult) ProtoReflect() protoreflect.Message { mi := &file_info_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1352,213 +1319,6 @@ func file_info_proto_init() { if File_info_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_info_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*GetFlightInformationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*GetFlightInformationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*GetIdentificationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*GetIdentificationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*GetProductRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*GetProductResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*GetVersionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*GetVersionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*GetSpeedFactorRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*GetSpeedFactorResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeFlightInformationRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*FlightInformationResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*FlightInfo); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*Identification); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*Product); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*Version); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_info_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*InfoResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/info/info_grpc.pb.go b/Sources/info/info_grpc.pb.go index 53c57a7..29c5acc 100644 --- a/Sources/info/info_grpc.pb.go +++ b/Sources/info/info_grpc.pb.go @@ -8,6 +8,7 @@ package info import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/log_files/log_files.go b/Sources/log_files/log_files.go index 21bbbb3..e5afc81 100644 --- a/Sources/log_files/log_files.go +++ b/Sources/log_files/log_files.go @@ -2,11 +2,11 @@ package log_files import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,43 +14,36 @@ type ServiceImpl struct { } /* - Get List of log files. - - - - Returns - ------- - True - Entries : []*Entry - List of entries - - +GetEntries Get List of log files. */ +func (s *ServiceImpl) GetEntries( + ctx context.Context, -func (s *ServiceImpl) GetEntries(ctx context.Context) (*GetEntriesResponse, error) { +) (*GetEntriesResponse, error) { request := &GetEntriesRequest{} response, err := s.Client.GetEntries(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Download log file. - - Parameters - ---------- - entry *Entry , path string +DownloadLogFile Download log file. */ +func (a *ServiceImpl) DownloadLogFile( + ctx context.Context, + entry *Entry, + + path string, -func (a *ServiceImpl) DownloadLogFile(ctx context.Context, entry *Entry, path string) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) - request := &SubscribeDownloadLogFileRequest{} - request.Entry = entry + request := &SubscribeDownloadLogFileRequest{ + Entry: entry, - request.Path = path + Path: path, + } stream, err := a.Client.SubscribeDownloadLogFile(ctx, request) if err != nil { return nil, err @@ -67,8 +60,7 @@ func (a *ServiceImpl) DownloadLogFile(ctx context.Context, entry *Entry, path st if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive DownloadLogFile messages, err: %v\n", err) - break + log.Fatalf("Unable to receive DownloadLogFile messages, err: %v", err) } ch <- m.GetProgress() } @@ -77,13 +69,12 @@ func (a *ServiceImpl) DownloadLogFile(ctx context.Context, entry *Entry, path st } /* - Erase all log files. - - +EraseAllLogFiles Erase all log files. */ +func (s *ServiceImpl) EraseAllLogFiles( + ctx context.Context, -func (s *ServiceImpl) EraseAllLogFiles(ctx context.Context) (*EraseAllLogFilesResponse, error) { - +) (*EraseAllLogFilesResponse, error) { request := &EraseAllLogFilesRequest{} response, err := s.Client.EraseAllLogFiles(ctx, request) if err != nil { diff --git a/Sources/log_files/log_files.pb.go b/Sources/log_files/log_files.pb.go index 4bf2d20..fff462f 100644 --- a/Sources/log_files/log_files.pb.go +++ b/Sources/log_files/log_files.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: log_files.proto package log_files import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -93,11 +94,9 @@ type GetEntriesRequest struct { func (x *GetEntriesRequest) Reset() { *x = GetEntriesRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetEntriesRequest) String() string { @@ -108,7 +107,7 @@ func (*GetEntriesRequest) ProtoMessage() {} func (x *GetEntriesRequest) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -134,11 +133,9 @@ type GetEntriesResponse struct { func (x *GetEntriesResponse) Reset() { *x = GetEntriesResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetEntriesResponse) String() string { @@ -149,7 +146,7 @@ func (*GetEntriesResponse) ProtoMessage() {} func (x *GetEntriesResponse) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -189,11 +186,9 @@ type SubscribeDownloadLogFileRequest struct { func (x *SubscribeDownloadLogFileRequest) Reset() { *x = SubscribeDownloadLogFileRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeDownloadLogFileRequest) String() string { @@ -204,7 +199,7 @@ func (*SubscribeDownloadLogFileRequest) ProtoMessage() {} func (x *SubscribeDownloadLogFileRequest) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -244,11 +239,9 @@ type DownloadLogFileResponse struct { func (x *DownloadLogFileResponse) Reset() { *x = DownloadLogFileResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadLogFileResponse) String() string { @@ -259,7 +252,7 @@ func (*DownloadLogFileResponse) ProtoMessage() {} func (x *DownloadLogFileResponse) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -296,11 +289,9 @@ type EraseAllLogFilesRequest struct { func (x *EraseAllLogFilesRequest) Reset() { *x = EraseAllLogFilesRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *EraseAllLogFilesRequest) String() string { @@ -311,7 +302,7 @@ func (*EraseAllLogFilesRequest) ProtoMessage() {} func (x *EraseAllLogFilesRequest) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -336,11 +327,9 @@ type EraseAllLogFilesResponse struct { func (x *EraseAllLogFilesResponse) Reset() { *x = EraseAllLogFilesResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *EraseAllLogFilesResponse) String() string { @@ -351,7 +340,7 @@ func (*EraseAllLogFilesResponse) ProtoMessage() {} func (x *EraseAllLogFilesResponse) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -384,11 +373,9 @@ type ProgressData struct { func (x *ProgressData) Reset() { *x = ProgressData{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProgressData) String() string { @@ -399,7 +386,7 @@ func (*ProgressData) ProtoMessage() {} func (x *ProgressData) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -434,11 +421,9 @@ type Entry struct { func (x *Entry) Reset() { *x = Entry{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Entry) String() string { @@ -449,7 +434,7 @@ func (*Entry) ProtoMessage() {} func (x *Entry) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -497,11 +482,9 @@ type LogFilesResult struct { func (x *LogFilesResult) Reset() { *x = LogFilesResult{} - if protoimpl.UnsafeEnabled { - mi := &file_log_files_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_files_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LogFilesResult) String() string { @@ -512,7 +495,7 @@ func (*LogFilesResult) ProtoMessage() {} func (x *LogFilesResult) ProtoReflect() protoreflect.Message { mi := &file_log_files_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -693,117 +676,6 @@ func file_log_files_proto_init() { if File_log_files_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_log_files_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*GetEntriesRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*GetEntriesResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeDownloadLogFileRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*DownloadLogFileResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*EraseAllLogFilesRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*EraseAllLogFilesResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*ProgressData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*Entry); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_files_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*LogFilesResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/log_files/log_files_grpc.pb.go b/Sources/log_files/log_files_grpc.pb.go index 6770141..a4132df 100644 --- a/Sources/log_files/log_files_grpc.pb.go +++ b/Sources/log_files/log_files_grpc.pb.go @@ -8,6 +8,7 @@ package log_files import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/log_streaming/log_streaming.go b/Sources/log_streaming/log_streaming.go index c3660dd..b6537c1 100644 --- a/Sources/log_streaming/log_streaming.go +++ b/Sources/log_streaming/log_streaming.go @@ -2,11 +2,11 @@ package log_streaming import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,13 +14,12 @@ type ServiceImpl struct { } /* - Start streaming logging data. - - +StartLogStreaming Start streaming logging data. */ +func (s *ServiceImpl) StartLogStreaming( + ctx context.Context, -func (s *ServiceImpl) StartLogStreaming(ctx context.Context) (*StartLogStreamingResponse, error) { - +) (*StartLogStreamingResponse, error) { request := &StartLogStreamingRequest{} response, err := s.Client.StartLogStreaming(ctx, request) if err != nil { @@ -30,13 +29,12 @@ func (s *ServiceImpl) StartLogStreaming(ctx context.Context) (*StartLogStreaming } /* - Stop streaming logging data. - - +StopLogStreaming Stop streaming logging data. */ +func (s *ServiceImpl) StopLogStreaming( + ctx context.Context, -func (s *ServiceImpl) StopLogStreaming(ctx context.Context) (*StopLogStreamingResponse, error) { - +) (*StopLogStreamingResponse, error) { request := &StopLogStreamingRequest{} response, err := s.Client.StopLogStreaming(ctx, request) if err != nil { @@ -46,12 +44,12 @@ func (s *ServiceImpl) StopLogStreaming(ctx context.Context) (*StopLogStreamingRe } /* - Subscribe to logging messages - - +LogStreamingRaw Subscribe to logging messages */ +func (a *ServiceImpl) LogStreamingRaw( + ctx context.Context, -func (a *ServiceImpl) LogStreamingRaw(ctx context.Context) (<-chan *LogStreamingRaw, error) { +) (<-chan *LogStreamingRaw, error) { ch := make(chan *LogStreamingRaw) request := &SubscribeLogStreamingRawRequest{} stream, err := a.Client.SubscribeLogStreamingRaw(ctx, request) @@ -70,8 +68,7 @@ func (a *ServiceImpl) LogStreamingRaw(ctx context.Context) (<-chan *LogStreaming if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive LogStreamingRaw messages, err: %v\n", err) - break + log.Fatalf("Unable to receive LogStreamingRaw messages, err: %v", err) } ch <- m.GetLoggingRaw() } diff --git a/Sources/log_streaming/log_streaming.pb.go b/Sources/log_streaming/log_streaming.pb.go index b856873..d0a6f2b 100644 --- a/Sources/log_streaming/log_streaming.pb.go +++ b/Sources/log_streaming/log_streaming.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: log_streaming.proto package log_streaming import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -93,11 +94,9 @@ type StartLogStreamingRequest struct { func (x *StartLogStreamingRequest) Reset() { *x = StartLogStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartLogStreamingRequest) String() string { @@ -108,7 +107,7 @@ func (*StartLogStreamingRequest) ProtoMessage() {} func (x *StartLogStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -133,11 +132,9 @@ type StartLogStreamingResponse struct { func (x *StartLogStreamingResponse) Reset() { *x = StartLogStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartLogStreamingResponse) String() string { @@ -148,7 +145,7 @@ func (*StartLogStreamingResponse) ProtoMessage() {} func (x *StartLogStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -178,11 +175,9 @@ type StopLogStreamingRequest struct { func (x *StopLogStreamingRequest) Reset() { *x = StopLogStreamingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopLogStreamingRequest) String() string { @@ -193,7 +188,7 @@ func (*StopLogStreamingRequest) ProtoMessage() {} func (x *StopLogStreamingRequest) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -218,11 +213,9 @@ type StopLogStreamingResponse struct { func (x *StopLogStreamingResponse) Reset() { *x = StopLogStreamingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopLogStreamingResponse) String() string { @@ -233,7 +226,7 @@ func (*StopLogStreamingResponse) ProtoMessage() {} func (x *StopLogStreamingResponse) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -263,11 +256,9 @@ type SubscribeLogStreamingRawRequest struct { func (x *SubscribeLogStreamingRawRequest) Reset() { *x = SubscribeLogStreamingRawRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeLogStreamingRawRequest) String() string { @@ -278,7 +269,7 @@ func (*SubscribeLogStreamingRawRequest) ProtoMessage() {} func (x *SubscribeLogStreamingRawRequest) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -303,11 +294,9 @@ type LogStreamingRawResponse struct { func (x *LogStreamingRawResponse) Reset() { *x = LogStreamingRawResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LogStreamingRawResponse) String() string { @@ -318,7 +307,7 @@ func (*LogStreamingRawResponse) ProtoMessage() {} func (x *LogStreamingRawResponse) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -351,11 +340,9 @@ type LogStreamingRaw struct { func (x *LogStreamingRaw) Reset() { *x = LogStreamingRaw{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LogStreamingRaw) String() string { @@ -366,7 +353,7 @@ func (*LogStreamingRaw) ProtoMessage() {} func (x *LogStreamingRaw) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -400,11 +387,9 @@ type LogStreamingResult struct { func (x *LogStreamingResult) Reset() { *x = LogStreamingResult{} - if protoimpl.UnsafeEnabled { - mi := &file_log_streaming_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_log_streaming_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LogStreamingResult) String() string { @@ -415,7 +400,7 @@ func (*LogStreamingResult) ProtoMessage() {} func (x *LogStreamingResult) ProtoReflect() protoreflect.Message { mi := &file_log_streaming_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -581,105 +566,6 @@ func file_log_streaming_proto_init() { if File_log_streaming_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_log_streaming_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*StartLogStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*StartLogStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*StopLogStreamingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*StopLogStreamingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeLogStreamingRawRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*LogStreamingRawResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*LogStreamingRaw); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_log_streaming_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*LogStreamingResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/log_streaming/log_streaming_grpc.pb.go b/Sources/log_streaming/log_streaming_grpc.pb.go index ca86c65..4c1ce55 100644 --- a/Sources/log_streaming/log_streaming_grpc.pb.go +++ b/Sources/log_streaming/log_streaming_grpc.pb.go @@ -8,6 +8,7 @@ package log_streaming import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/manual_control/manual_control.go b/Sources/manual_control/manual_control.go index 8d8d528..d806406 100644 --- a/Sources/manual_control/manual_control.go +++ b/Sources/manual_control/manual_control.go @@ -9,16 +9,15 @@ type ServiceImpl struct { } /* - Start position control using e.g. joystick input. - - Requires manual control input to be sent regularly already. - Requires a valid position using e.g. GPS, external vision, or optical flow. - +StartPositionControl Start position control using e.g. joystick input. + Requires manual control input to be sent regularly already. + Requires a valid position using e.g. GPS, external vision, or optical flow. */ +func (s *ServiceImpl) StartPositionControl( + ctx context.Context, -func (s *ServiceImpl) StartPositionControl(ctx context.Context) (*StartPositionControlResponse, error) { - +) (*StartPositionControlResponse, error) { request := &StartPositionControlRequest{} response, err := s.Client.StartPositionControl(ctx, request) if err != nil { @@ -28,16 +27,15 @@ func (s *ServiceImpl) StartPositionControl(ctx context.Context) (*StartPositionC } /* - Start altitude control - - Requires manual control input to be sent regularly already. - Does not require a valid position e.g. GPS. - +StartAltitudeControl Start altitude control + Requires manual control input to be sent regularly already. + Does not require a valid position e.g. GPS. */ +func (s *ServiceImpl) StartAltitudeControl( + ctx context.Context, -func (s *ServiceImpl) StartAltitudeControl(ctx context.Context) (*StartAltitudeControlResponse, error) { - +) (*StartAltitudeControlResponse, error) { request := &StartAltitudeControlRequest{} response, err := s.Client.StartAltitudeControl(ctx, request) if err != nil { @@ -47,31 +45,25 @@ func (s *ServiceImpl) StartAltitudeControl(ctx context.Context) (*StartAltitudeC } /* - Set manual control input - - The manual control input needs to be sent at a rate high enough to prevent - triggering of RC loss, a good minimum rate is 10 Hz. - - Parameters - ---------- - x float32 - - y float32 - - z float32 - - r float32 - +SetManualControlInput Set manual control input + The manual control input needs to be sent at a rate high enough to prevent + triggering of RC loss, a good minimum rate is 10 Hz. */ - -func (s *ServiceImpl) SetManualControlInput(ctx context.Context, x float32, y float32, z float32, r float32) (*SetManualControlInputResponse, error) { - - request := &SetManualControlInputRequest{} - request.X = x - request.Y = y - request.Z = z - request.R = r +func (s *ServiceImpl) SetManualControlInput( + ctx context.Context, + x float32, + y float32, + z float32, + r float32, + +) (*SetManualControlInputResponse, error) { + request := &SetManualControlInputRequest{ + X: x, + Y: y, + Z: z, + R: r, + } response, err := s.Client.SetManualControlInput(ctx, request) if err != nil { return nil, err diff --git a/Sources/manual_control/manual_control.pb.go b/Sources/manual_control/manual_control.pb.go index 0c01800..31f597f 100644 --- a/Sources/manual_control/manual_control.pb.go +++ b/Sources/manual_control/manual_control.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: manual_control.proto package manual_control import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -96,11 +97,9 @@ type StartPositionControlRequest struct { func (x *StartPositionControlRequest) Reset() { *x = StartPositionControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartPositionControlRequest) String() string { @@ -111,7 +110,7 @@ func (*StartPositionControlRequest) ProtoMessage() {} func (x *StartPositionControlRequest) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -136,11 +135,9 @@ type StartPositionControlResponse struct { func (x *StartPositionControlResponse) Reset() { *x = StartPositionControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartPositionControlResponse) String() string { @@ -151,7 +148,7 @@ func (*StartPositionControlResponse) ProtoMessage() {} func (x *StartPositionControlResponse) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -181,11 +178,9 @@ type StartAltitudeControlRequest struct { func (x *StartAltitudeControlRequest) Reset() { *x = StartAltitudeControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartAltitudeControlRequest) String() string { @@ -196,7 +191,7 @@ func (*StartAltitudeControlRequest) ProtoMessage() {} func (x *StartAltitudeControlRequest) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -221,11 +216,9 @@ type StartAltitudeControlResponse struct { func (x *StartAltitudeControlResponse) Reset() { *x = StartAltitudeControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartAltitudeControlResponse) String() string { @@ -236,7 +229,7 @@ func (*StartAltitudeControlResponse) ProtoMessage() {} func (x *StartAltitudeControlResponse) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -271,11 +264,9 @@ type SetManualControlInputRequest struct { func (x *SetManualControlInputRequest) Reset() { *x = SetManualControlInputRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetManualControlInputRequest) String() string { @@ -286,7 +277,7 @@ func (*SetManualControlInputRequest) ProtoMessage() {} func (x *SetManualControlInputRequest) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -339,11 +330,9 @@ type SetManualControlInputResponse struct { func (x *SetManualControlInputResponse) Reset() { *x = SetManualControlInputResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetManualControlInputResponse) String() string { @@ -354,7 +343,7 @@ func (*SetManualControlInputResponse) ProtoMessage() {} func (x *SetManualControlInputResponse) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -388,11 +377,9 @@ type ManualControlResult struct { func (x *ManualControlResult) Reset() { *x = ManualControlResult{} - if protoimpl.UnsafeEnabled { - mi := &file_manual_control_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_manual_control_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ManualControlResult) String() string { @@ -403,7 +390,7 @@ func (*ManualControlResult) ProtoMessage() {} func (x *ManualControlResult) ProtoReflect() protoreflect.Message { mi := &file_manual_control_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -577,93 +564,6 @@ func file_manual_control_proto_init() { if File_manual_control_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_manual_control_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*StartPositionControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_manual_control_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*StartPositionControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_manual_control_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*StartAltitudeControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_manual_control_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*StartAltitudeControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_manual_control_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SetManualControlInputRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_manual_control_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*SetManualControlInputResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_manual_control_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*ManualControlResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/manual_control/manual_control_grpc.pb.go b/Sources/manual_control/manual_control_grpc.pb.go index 698a23e..d238f67 100644 --- a/Sources/manual_control/manual_control_grpc.pb.go +++ b/Sources/manual_control/manual_control_grpc.pb.go @@ -8,6 +8,7 @@ package manual_control import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/mission/mission.go b/Sources/mission/mission.go index 8275bbb..5f6787f 100644 --- a/Sources/mission/mission.go +++ b/Sources/mission/mission.go @@ -2,11 +2,11 @@ package mission import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,24 +14,19 @@ type ServiceImpl struct { } /* - Upload a list of mission items to the system. - - The mission items are uploaded to a drone. Once uploaded the mission can be started and - executed even if the connection is lost. - - Parameters - ---------- - missionPlan *MissionPlan - - +UploadMission Upload a list of mission items to the system. + The mission items are uploaded to a drone. Once uploaded the mission can be started and + executed even if the connection is lost. */ +func (s *ServiceImpl) UploadMission( + ctx context.Context, + missionPlan *MissionPlan, -func (s *ServiceImpl) UploadMission(ctx context.Context, missionPlan *MissionPlan) (*UploadMissionResponse, error) { - - request := &UploadMissionRequest{} - request.MissionPlan = missionPlan - +) (*UploadMissionResponse, error) { + request := &UploadMissionRequest{ + MissionPlan: missionPlan, + } response, err := s.Client.UploadMission(ctx, request) if err != nil { return nil, err @@ -40,21 +35,20 @@ func (s *ServiceImpl) UploadMission(ctx context.Context, missionPlan *MissionPla } /* - Upload a list of mission items to the system and report upload progress. - - The mission items are uploaded to a drone. Once uploaded the mission can be started and - executed even if the connection is lost. +UploadMissionWithProgress Upload a list of mission items to the system and report upload progress. - Parameters - ---------- - missionPlan *MissionPlan + The mission items are uploaded to a drone. Once uploaded the mission can be started and + executed even if the connection is lost. */ +func (a *ServiceImpl) UploadMissionWithProgress( + ctx context.Context, + missionPlan *MissionPlan, -func (a *ServiceImpl) UploadMissionWithProgress(ctx context.Context, missionPlan *MissionPlan) (<-chan *ProgressData, error) { +) (<-chan *ProgressData, error) { ch := make(chan *ProgressData) - request := &SubscribeUploadMissionWithProgressRequest{} - request.MissionPlan = missionPlan - + request := &SubscribeUploadMissionWithProgressRequest{ + MissionPlan: missionPlan, + } stream, err := a.Client.SubscribeUploadMissionWithProgress(ctx, request) if err != nil { return nil, err @@ -71,8 +65,7 @@ func (a *ServiceImpl) UploadMissionWithProgress(ctx context.Context, missionPlan if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive UploadMissionWithProgress messages, err: %v\n", err) - break + log.Fatalf("Unable to receive UploadMissionWithProgress messages, err: %v", err) } ch <- m.GetProgressData() } @@ -81,13 +74,12 @@ func (a *ServiceImpl) UploadMissionWithProgress(ctx context.Context, missionPlan } /* - Cancel an ongoing mission upload. - - +CancelMissionUpload Cancel an ongoing mission upload. */ +func (s *ServiceImpl) CancelMissionUpload( + ctx context.Context, -func (s *ServiceImpl) CancelMissionUpload(ctx context.Context) (*CancelMissionUploadResponse, error) { - +) (*CancelMissionUploadResponse, error) { request := &CancelMissionUploadRequest{} response, err := s.Client.CancelMissionUpload(ctx, request) if err != nil { @@ -97,42 +89,33 @@ func (s *ServiceImpl) CancelMissionUpload(ctx context.Context) (*CancelMissionUp } /* - Download a list of mission items from the system (asynchronous). - - Will fail if any of the downloaded mission items are not supported - by the MAVSDK API. - - - - Returns - ------- - False - MissionPlan : MissionPlan - The mission plan - +DownloadMission Download a list of mission items from the system (asynchronous). + Will fail if any of the downloaded mission items are not supported + by the MAVSDK API. */ +func (s *ServiceImpl) DownloadMission( + ctx context.Context, -func (s *ServiceImpl) DownloadMission(ctx context.Context) (*DownloadMissionResponse, error) { +) (*DownloadMissionResponse, error) { request := &DownloadMissionRequest{} response, err := s.Client.DownloadMission(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Download a list of mission items from the system (asynchronous) and report progress. - - Will fail if any of the downloaded mission items are not supported - by the MAVSDK API. - +DownloadMissionWithProgress Download a list of mission items from the system (asynchronous) and report progress. + Will fail if any of the downloaded mission items are not supported + by the MAVSDK API. */ +func (a *ServiceImpl) DownloadMissionWithProgress( + ctx context.Context, -func (a *ServiceImpl) DownloadMissionWithProgress(ctx context.Context) (<-chan *ProgressDataOrMission, error) { +) (<-chan *ProgressDataOrMission, error) { ch := make(chan *ProgressDataOrMission) request := &SubscribeDownloadMissionWithProgressRequest{} stream, err := a.Client.SubscribeDownloadMissionWithProgress(ctx, request) @@ -151,8 +134,7 @@ func (a *ServiceImpl) DownloadMissionWithProgress(ctx context.Context) (<-chan * if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive DownloadMissionWithProgress messages, err: %v\n", err) - break + log.Fatalf("Unable to receive DownloadMissionWithProgress messages, err: %v", err) } ch <- m.GetProgressData() } @@ -161,13 +143,12 @@ func (a *ServiceImpl) DownloadMissionWithProgress(ctx context.Context) (<-chan * } /* - Cancel an ongoing mission download. - - +CancelMissionDownload Cancel an ongoing mission download. */ +func (s *ServiceImpl) CancelMissionDownload( + ctx context.Context, -func (s *ServiceImpl) CancelMissionDownload(ctx context.Context) (*CancelMissionDownloadResponse, error) { - +) (*CancelMissionDownloadResponse, error) { request := &CancelMissionDownloadRequest{} response, err := s.Client.CancelMissionDownload(ctx, request) if err != nil { @@ -177,15 +158,14 @@ func (s *ServiceImpl) CancelMissionDownload(ctx context.Context) (*CancelMission } /* - Start the mission. - - A mission must be uploaded to the vehicle before this can be called. - +StartMission Start the mission. + A mission must be uploaded to the vehicle before this can be called. */ +func (s *ServiceImpl) StartMission( + ctx context.Context, -func (s *ServiceImpl) StartMission(ctx context.Context) (*StartMissionResponse, error) { - +) (*StartMissionResponse, error) { request := &StartMissionRequest{} response, err := s.Client.StartMission(ctx, request) if err != nil { @@ -195,18 +175,17 @@ func (s *ServiceImpl) StartMission(ctx context.Context) (*StartMissionResponse, } /* - Pause the mission. - - Pausing the mission puts the vehicle into - [HOLD mode](https://docs.px4.io/en/flight_modes/hold.html). - A multicopter should just hover at the spot while a fixedwing vehicle should loiter - around the location where it paused. - +PauseMission Pause the mission. + Pausing the mission puts the vehicle into + [HOLD mode](https://docs.px4.io/en/flight_modes/hold.html). + A multicopter should just hover at the spot while a fixedwing vehicle should loiter + around the location where it paused. */ +func (s *ServiceImpl) PauseMission( + ctx context.Context, -func (s *ServiceImpl) PauseMission(ctx context.Context) (*PauseMissionResponse, error) { - +) (*PauseMissionResponse, error) { request := &PauseMissionRequest{} response, err := s.Client.PauseMission(ctx, request) if err != nil { @@ -216,13 +195,12 @@ func (s *ServiceImpl) PauseMission(ctx context.Context) (*PauseMissionResponse, } /* - Clear the mission saved on the vehicle. - - +ClearMission Clear the mission saved on the vehicle. */ +func (s *ServiceImpl) ClearMission( + ctx context.Context, -func (s *ServiceImpl) ClearMission(ctx context.Context) (*ClearMissionResponse, error) { - +) (*ClearMissionResponse, error) { request := &ClearMissionRequest{} response, err := s.Client.ClearMission(ctx, request) if err != nil { @@ -232,25 +210,22 @@ func (s *ServiceImpl) ClearMission(ctx context.Context) (*ClearMissionResponse, } /* - Sets the mission item index to go to. - - By setting the current index to 0, the mission is restarted from the beginning. If it is set - to a specific index of a mission item, the mission will be set to this item. - - Note that this is not necessarily true for general missions using MAVLink if loop counters - are used. - - Parameters - ---------- - index int32 +SetCurrentMissionItem Sets the mission item index to go to. + By setting the current index to 0, the mission is restarted from the beginning. If it is set + to a specific index of a mission item, the mission will be set to this item. + Note that this is not necessarily true for general missions using MAVLink if loop counters + are used. */ +func (s *ServiceImpl) SetCurrentMissionItem( + ctx context.Context, + index int32, -func (s *ServiceImpl) SetCurrentMissionItem(ctx context.Context, index int32) (*SetCurrentMissionItemResponse, error) { - - request := &SetCurrentMissionItemRequest{} - request.Index = index +) (*SetCurrentMissionItemResponse, error) { + request := &SetCurrentMissionItemRequest{ + Index: index, + } response, err := s.Client.SetCurrentMissionItem(ctx, request) if err != nil { return nil, err @@ -259,36 +234,27 @@ func (s *ServiceImpl) SetCurrentMissionItem(ctx context.Context, index int32) (* } /* - Check if the mission has been finished. - - - - Returns - ------- - False - IsFinished : bool - True if the mission is finished and the last mission item has been reached - - +IsMissionFinished Check if the mission has been finished. */ +func (s *ServiceImpl) IsMissionFinished( + ctx context.Context, -func (s *ServiceImpl) IsMissionFinished(ctx context.Context) (*IsMissionFinishedResponse, error) { +) (*IsMissionFinishedResponse, error) { request := &IsMissionFinishedRequest{} response, err := s.Client.IsMissionFinished(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Subscribe to mission progress updates. - - +MissionProgress Subscribe to mission progress updates. */ +func (a *ServiceImpl) MissionProgress( + ctx context.Context, -func (a *ServiceImpl) MissionProgress(ctx context.Context) (<-chan *MissionProgress, error) { +) (<-chan *MissionProgress, error) { ch := make(chan *MissionProgress) request := &SubscribeMissionProgressRequest{} stream, err := a.Client.SubscribeMissionProgress(ctx, request) @@ -307,8 +273,7 @@ func (a *ServiceImpl) MissionProgress(ctx context.Context) (<-chan *MissionProgr if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive MissionProgress messages, err: %v\n", err) - break + log.Fatalf("Unable to receive MissionProgress messages, err: %v", err) } ch <- m.GetMissionProgress() } @@ -317,49 +282,37 @@ func (a *ServiceImpl) MissionProgress(ctx context.Context) (<-chan *MissionProgr } /* - Get whether to trigger Return-to-Launch (RTL) after mission is complete. - - Before getting this option, it needs to be set, or a mission - needs to be downloaded. - - - - Returns - ------- - False - Enable : bool - If true, trigger an RTL at the end of the mission - +GetReturnToLaunchAfterMission Get whether to trigger Return-to-Launch (RTL) after mission is complete. + Before getting this option, it needs to be set, or a mission + needs to be downloaded. */ +func (s *ServiceImpl) GetReturnToLaunchAfterMission( + ctx context.Context, -func (s *ServiceImpl) GetReturnToLaunchAfterMission(ctx context.Context) (*GetReturnToLaunchAfterMissionResponse, error) { +) (*GetReturnToLaunchAfterMissionResponse, error) { request := &GetReturnToLaunchAfterMissionRequest{} response, err := s.Client.GetReturnToLaunchAfterMission(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set whether to trigger Return-to-Launch (RTL) after the mission is complete. - - This will only take effect for the next mission upload, meaning that - the mission may have to be uploaded again. - - Parameters - ---------- - enable bool - +SetReturnToLaunchAfterMission Set whether to trigger Return-to-Launch (RTL) after the mission is complete. + This will only take effect for the next mission upload, meaning that + the mission may have to be uploaded again. */ +func (s *ServiceImpl) SetReturnToLaunchAfterMission( + ctx context.Context, + enable bool, -func (s *ServiceImpl) SetReturnToLaunchAfterMission(ctx context.Context, enable bool) (*SetReturnToLaunchAfterMissionResponse, error) { - - request := &SetReturnToLaunchAfterMissionRequest{} - request.Enable = enable +) (*SetReturnToLaunchAfterMissionResponse, error) { + request := &SetReturnToLaunchAfterMissionRequest{ + Enable: enable, + } response, err := s.Client.SetReturnToLaunchAfterMission(ctx, request) if err != nil { return nil, err diff --git a/Sources/mission/mission.pb.go b/Sources/mission/mission.pb.go index e896d0c..56879b1 100644 --- a/Sources/mission/mission.pb.go +++ b/Sources/mission/mission.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: mission.proto package mission import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -240,11 +241,9 @@ type UploadMissionRequest struct { func (x *UploadMissionRequest) Reset() { *x = UploadMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadMissionRequest) String() string { @@ -255,7 +254,7 @@ func (*UploadMissionRequest) ProtoMessage() {} func (x *UploadMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -287,11 +286,9 @@ type UploadMissionResponse struct { func (x *UploadMissionResponse) Reset() { *x = UploadMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadMissionResponse) String() string { @@ -302,7 +299,7 @@ func (*UploadMissionResponse) ProtoMessage() {} func (x *UploadMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -334,11 +331,9 @@ type SubscribeUploadMissionWithProgressRequest struct { func (x *SubscribeUploadMissionWithProgressRequest) Reset() { *x = SubscribeUploadMissionWithProgressRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeUploadMissionWithProgressRequest) String() string { @@ -349,7 +344,7 @@ func (*SubscribeUploadMissionWithProgressRequest) ProtoMessage() {} func (x *SubscribeUploadMissionWithProgressRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -382,11 +377,9 @@ type UploadMissionWithProgressResponse struct { func (x *UploadMissionWithProgressResponse) Reset() { *x = UploadMissionWithProgressResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadMissionWithProgressResponse) String() string { @@ -397,7 +390,7 @@ func (*UploadMissionWithProgressResponse) ProtoMessage() {} func (x *UploadMissionWithProgressResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -434,11 +427,9 @@ type CancelMissionUploadRequest struct { func (x *CancelMissionUploadRequest) Reset() { *x = CancelMissionUploadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionUploadRequest) String() string { @@ -449,7 +440,7 @@ func (*CancelMissionUploadRequest) ProtoMessage() {} func (x *CancelMissionUploadRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -474,11 +465,9 @@ type CancelMissionUploadResponse struct { func (x *CancelMissionUploadResponse) Reset() { *x = CancelMissionUploadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionUploadResponse) String() string { @@ -489,7 +478,7 @@ func (*CancelMissionUploadResponse) ProtoMessage() {} func (x *CancelMissionUploadResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -519,11 +508,9 @@ type DownloadMissionRequest struct { func (x *DownloadMissionRequest) Reset() { *x = DownloadMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadMissionRequest) String() string { @@ -534,7 +521,7 @@ func (*DownloadMissionRequest) ProtoMessage() {} func (x *DownloadMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -560,11 +547,9 @@ type DownloadMissionResponse struct { func (x *DownloadMissionResponse) Reset() { *x = DownloadMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadMissionResponse) String() string { @@ -575,7 +560,7 @@ func (*DownloadMissionResponse) ProtoMessage() {} func (x *DownloadMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -612,11 +597,9 @@ type SubscribeDownloadMissionWithProgressRequest struct { func (x *SubscribeDownloadMissionWithProgressRequest) Reset() { *x = SubscribeDownloadMissionWithProgressRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeDownloadMissionWithProgressRequest) String() string { @@ -627,7 +610,7 @@ func (*SubscribeDownloadMissionWithProgressRequest) ProtoMessage() {} func (x *SubscribeDownloadMissionWithProgressRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -653,11 +636,9 @@ type DownloadMissionWithProgressResponse struct { func (x *DownloadMissionWithProgressResponse) Reset() { *x = DownloadMissionWithProgressResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadMissionWithProgressResponse) String() string { @@ -668,7 +649,7 @@ func (*DownloadMissionWithProgressResponse) ProtoMessage() {} func (x *DownloadMissionWithProgressResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -705,11 +686,9 @@ type CancelMissionDownloadRequest struct { func (x *CancelMissionDownloadRequest) Reset() { *x = CancelMissionDownloadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionDownloadRequest) String() string { @@ -720,7 +699,7 @@ func (*CancelMissionDownloadRequest) ProtoMessage() {} func (x *CancelMissionDownloadRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -745,11 +724,9 @@ type CancelMissionDownloadResponse struct { func (x *CancelMissionDownloadResponse) Reset() { *x = CancelMissionDownloadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionDownloadResponse) String() string { @@ -760,7 +737,7 @@ func (*CancelMissionDownloadResponse) ProtoMessage() {} func (x *CancelMissionDownloadResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -790,11 +767,9 @@ type StartMissionRequest struct { func (x *StartMissionRequest) Reset() { *x = StartMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartMissionRequest) String() string { @@ -805,7 +780,7 @@ func (*StartMissionRequest) ProtoMessage() {} func (x *StartMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -830,11 +805,9 @@ type StartMissionResponse struct { func (x *StartMissionResponse) Reset() { *x = StartMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartMissionResponse) String() string { @@ -845,7 +818,7 @@ func (*StartMissionResponse) ProtoMessage() {} func (x *StartMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -875,11 +848,9 @@ type PauseMissionRequest struct { func (x *PauseMissionRequest) Reset() { *x = PauseMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PauseMissionRequest) String() string { @@ -890,7 +861,7 @@ func (*PauseMissionRequest) ProtoMessage() {} func (x *PauseMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -915,11 +886,9 @@ type PauseMissionResponse struct { func (x *PauseMissionResponse) Reset() { *x = PauseMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PauseMissionResponse) String() string { @@ -930,7 +899,7 @@ func (*PauseMissionResponse) ProtoMessage() {} func (x *PauseMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -960,11 +929,9 @@ type ClearMissionRequest struct { func (x *ClearMissionRequest) Reset() { *x = ClearMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearMissionRequest) String() string { @@ -975,7 +942,7 @@ func (*ClearMissionRequest) ProtoMessage() {} func (x *ClearMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1000,11 +967,9 @@ type ClearMissionResponse struct { func (x *ClearMissionResponse) Reset() { *x = ClearMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearMissionResponse) String() string { @@ -1015,7 +980,7 @@ func (*ClearMissionResponse) ProtoMessage() {} func (x *ClearMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1047,11 +1012,9 @@ type SetCurrentMissionItemRequest struct { func (x *SetCurrentMissionItemRequest) Reset() { *x = SetCurrentMissionItemRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentMissionItemRequest) String() string { @@ -1062,7 +1025,7 @@ func (*SetCurrentMissionItemRequest) ProtoMessage() {} func (x *SetCurrentMissionItemRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1094,11 +1057,9 @@ type SetCurrentMissionItemResponse struct { func (x *SetCurrentMissionItemResponse) Reset() { *x = SetCurrentMissionItemResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentMissionItemResponse) String() string { @@ -1109,7 +1070,7 @@ func (*SetCurrentMissionItemResponse) ProtoMessage() {} func (x *SetCurrentMissionItemResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1139,11 +1100,9 @@ type IsMissionFinishedRequest struct { func (x *IsMissionFinishedRequest) Reset() { *x = IsMissionFinishedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IsMissionFinishedRequest) String() string { @@ -1154,7 +1113,7 @@ func (*IsMissionFinishedRequest) ProtoMessage() {} func (x *IsMissionFinishedRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1180,11 +1139,9 @@ type IsMissionFinishedResponse struct { func (x *IsMissionFinishedResponse) Reset() { *x = IsMissionFinishedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IsMissionFinishedResponse) String() string { @@ -1195,7 +1152,7 @@ func (*IsMissionFinishedResponse) ProtoMessage() {} func (x *IsMissionFinishedResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1232,11 +1189,9 @@ type SubscribeMissionProgressRequest struct { func (x *SubscribeMissionProgressRequest) Reset() { *x = SubscribeMissionProgressRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeMissionProgressRequest) String() string { @@ -1247,7 +1202,7 @@ func (*SubscribeMissionProgressRequest) ProtoMessage() {} func (x *SubscribeMissionProgressRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1272,11 +1227,9 @@ type MissionProgressResponse struct { func (x *MissionProgressResponse) Reset() { *x = MissionProgressResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionProgressResponse) String() string { @@ -1287,7 +1240,7 @@ func (*MissionProgressResponse) ProtoMessage() {} func (x *MissionProgressResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1317,11 +1270,9 @@ type GetReturnToLaunchAfterMissionRequest struct { func (x *GetReturnToLaunchAfterMissionRequest) Reset() { *x = GetReturnToLaunchAfterMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetReturnToLaunchAfterMissionRequest) String() string { @@ -1332,7 +1283,7 @@ func (*GetReturnToLaunchAfterMissionRequest) ProtoMessage() {} func (x *GetReturnToLaunchAfterMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1358,11 +1309,9 @@ type GetReturnToLaunchAfterMissionResponse struct { func (x *GetReturnToLaunchAfterMissionResponse) Reset() { *x = GetReturnToLaunchAfterMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetReturnToLaunchAfterMissionResponse) String() string { @@ -1373,7 +1322,7 @@ func (*GetReturnToLaunchAfterMissionResponse) ProtoMessage() {} func (x *GetReturnToLaunchAfterMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1412,11 +1361,9 @@ type SetReturnToLaunchAfterMissionRequest struct { func (x *SetReturnToLaunchAfterMissionRequest) Reset() { *x = SetReturnToLaunchAfterMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetReturnToLaunchAfterMissionRequest) String() string { @@ -1427,7 +1374,7 @@ func (*SetReturnToLaunchAfterMissionRequest) ProtoMessage() {} func (x *SetReturnToLaunchAfterMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1459,11 +1406,9 @@ type SetReturnToLaunchAfterMissionResponse struct { func (x *SetReturnToLaunchAfterMissionResponse) Reset() { *x = SetReturnToLaunchAfterMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetReturnToLaunchAfterMissionResponse) String() string { @@ -1474,7 +1419,7 @@ func (*SetReturnToLaunchAfterMissionResponse) ProtoMessage() {} func (x *SetReturnToLaunchAfterMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1525,11 +1470,9 @@ type MissionItem struct { func (x *MissionItem) Reset() { *x = MissionItem{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionItem) String() string { @@ -1540,7 +1483,7 @@ func (*MissionItem) ProtoMessage() {} func (x *MissionItem) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1664,11 +1607,9 @@ type MissionPlan struct { func (x *MissionPlan) Reset() { *x = MissionPlan{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionPlan) String() string { @@ -1679,7 +1620,7 @@ func (*MissionPlan) ProtoMessage() {} func (x *MissionPlan) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1713,11 +1654,9 @@ type MissionProgress struct { func (x *MissionProgress) Reset() { *x = MissionProgress{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionProgress) String() string { @@ -1728,7 +1667,7 @@ func (*MissionProgress) ProtoMessage() {} func (x *MissionProgress) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1769,11 +1708,9 @@ type MissionResult struct { func (x *MissionResult) Reset() { *x = MissionResult{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionResult) String() string { @@ -1784,7 +1721,7 @@ func (*MissionResult) ProtoMessage() {} func (x *MissionResult) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1824,11 +1761,9 @@ type ProgressData struct { func (x *ProgressData) Reset() { *x = ProgressData{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProgressData) String() string { @@ -1839,7 +1774,7 @@ func (*ProgressData) ProtoMessage() {} func (x *ProgressData) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1875,11 +1810,9 @@ type ProgressDataOrMission struct { func (x *ProgressDataOrMission) Reset() { *x = ProgressDataOrMission{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProgressDataOrMission) String() string { @@ -1890,7 +1823,7 @@ func (*ProgressDataOrMission) ProtoMessage() {} func (x *ProgressDataOrMission) ProtoReflect() protoreflect.Message { mi := &file_mission_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2465,417 +2398,6 @@ func file_mission_proto_init() { if File_mission_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_mission_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*UploadMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*UploadMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeUploadMissionWithProgressRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*UploadMissionWithProgressResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionUploadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionUploadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*DownloadMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*DownloadMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeDownloadMissionWithProgressRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*DownloadMissionWithProgressResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionDownloadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionDownloadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*StartMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*StartMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*PauseMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*PauseMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*ClearMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*ClearMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentMissionItemRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentMissionItemResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*IsMissionFinishedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*IsMissionFinishedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeMissionProgressRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*MissionProgressResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*GetReturnToLaunchAfterMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*GetReturnToLaunchAfterMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*SetReturnToLaunchAfterMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*SetReturnToLaunchAfterMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*MissionItem); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*MissionPlan); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*MissionProgress); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*MissionResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*ProgressData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*ProgressDataOrMission); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/mission/mission_grpc.pb.go b/Sources/mission/mission_grpc.pb.go index c8bac09..28bed75 100644 --- a/Sources/mission/mission_grpc.pb.go +++ b/Sources/mission/mission_grpc.pb.go @@ -8,6 +8,7 @@ package mission import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/mission_raw/mission_raw.go b/Sources/mission_raw/mission_raw.go index f543346..d1c2ff6 100644 --- a/Sources/mission_raw/mission_raw.go +++ b/Sources/mission_raw/mission_raw.go @@ -2,11 +2,11 @@ package mission_raw import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,23 +14,19 @@ type ServiceImpl struct { } /* - Upload a list of raw mission items to the system. - - The raw mission items are uploaded to a drone. Once uploaded the mission - can be started and executed even if the connection is lost. - - Parameters - ---------- - missionItems []*MissionItem - +UploadMission Upload a list of raw mission items to the system. + The raw mission items are uploaded to a drone. Once uploaded the mission + can be started and executed even if the connection is lost. */ +func (s *ServiceImpl) UploadMission( + ctx context.Context, + missionItems []*MissionItem, -func (s *ServiceImpl) UploadMission(ctx context.Context, missionItems []*MissionItem) (*UploadMissionResponse, error) { - - request := &UploadMissionRequest{} - request.MissionItems = missionItems - +) (*UploadMissionResponse, error) { + request := &UploadMissionRequest{ + MissionItems: missionItems, + } response, err := s.Client.UploadMission(ctx, request) if err != nil { return nil, err @@ -39,20 +35,16 @@ func (s *ServiceImpl) UploadMission(ctx context.Context, missionItems []*Mission } /* - Upload a list of geofence items to the system. - - Parameters - ---------- - missionItems []*MissionItem - - +UploadGeofence Upload a list of geofence items to the system. */ +func (s *ServiceImpl) UploadGeofence( + ctx context.Context, + missionItems []*MissionItem, -func (s *ServiceImpl) UploadGeofence(ctx context.Context, missionItems []*MissionItem) (*UploadGeofenceResponse, error) { - - request := &UploadGeofenceRequest{} - request.MissionItems = missionItems - +) (*UploadGeofenceResponse, error) { + request := &UploadGeofenceRequest{ + MissionItems: missionItems, + } response, err := s.Client.UploadGeofence(ctx, request) if err != nil { return nil, err @@ -61,20 +53,16 @@ func (s *ServiceImpl) UploadGeofence(ctx context.Context, missionItems []*Missio } /* - Upload a list of rally point items to the system. - - Parameters - ---------- - missionItems []*MissionItem - - +UploadRallyPoints Upload a list of rally point items to the system. */ +func (s *ServiceImpl) UploadRallyPoints( + ctx context.Context, + missionItems []*MissionItem, -func (s *ServiceImpl) UploadRallyPoints(ctx context.Context, missionItems []*MissionItem) (*UploadRallyPointsResponse, error) { - - request := &UploadRallyPointsRequest{} - request.MissionItems = missionItems - +) (*UploadRallyPointsResponse, error) { + request := &UploadRallyPointsRequest{ + MissionItems: missionItems, + } response, err := s.Client.UploadRallyPoints(ctx, request) if err != nil { return nil, err @@ -83,13 +71,12 @@ func (s *ServiceImpl) UploadRallyPoints(ctx context.Context, missionItems []*Mis } /* - Cancel an ongoing mission upload. - - +CancelMissionUpload Cancel an ongoing mission upload. */ +func (s *ServiceImpl) CancelMissionUpload( + ctx context.Context, -func (s *ServiceImpl) CancelMissionUpload(ctx context.Context) (*CancelMissionUploadResponse, error) { - +) (*CancelMissionUploadResponse, error) { request := &CancelMissionUploadRequest{} response, err := s.Client.CancelMissionUpload(ctx, request) if err != nil { @@ -99,37 +86,27 @@ func (s *ServiceImpl) CancelMissionUpload(ctx context.Context) (*CancelMissionUp } /* - Download a list of raw mission items from the system (asynchronous). - - - - Returns - ------- - True - MissionItems : []*MissionItem - The mission items - - +DownloadMission Download a list of raw mission items from the system (asynchronous). */ +func (s *ServiceImpl) DownloadMission( + ctx context.Context, -func (s *ServiceImpl) DownloadMission(ctx context.Context) (*DownloadMissionResponse, error) { +) (*DownloadMissionResponse, error) { request := &DownloadMissionRequest{} response, err := s.Client.DownloadMission(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Cancel an ongoing mission download. - - +CancelMissionDownload Cancel an ongoing mission download. */ +func (s *ServiceImpl) CancelMissionDownload( + ctx context.Context, -func (s *ServiceImpl) CancelMissionDownload(ctx context.Context) (*CancelMissionDownloadResponse, error) { - +) (*CancelMissionDownloadResponse, error) { request := &CancelMissionDownloadRequest{} response, err := s.Client.CancelMissionDownload(ctx, request) if err != nil { @@ -139,15 +116,14 @@ func (s *ServiceImpl) CancelMissionDownload(ctx context.Context) (*CancelMission } /* - Start the mission. - - A mission must be uploaded to the vehicle before this can be called. - +StartMission Start the mission. + A mission must be uploaded to the vehicle before this can be called. */ +func (s *ServiceImpl) StartMission( + ctx context.Context, -func (s *ServiceImpl) StartMission(ctx context.Context) (*StartMissionResponse, error) { - +) (*StartMissionResponse, error) { request := &StartMissionRequest{} response, err := s.Client.StartMission(ctx, request) if err != nil { @@ -157,18 +133,17 @@ func (s *ServiceImpl) StartMission(ctx context.Context) (*StartMissionResponse, } /* - Pause the mission. - - Pausing the mission puts the vehicle into - [HOLD mode](https://docs.px4.io/en/flight_modes/hold.html). - A multicopter should just hover at the spot while a fixedwing vehicle should loiter - around the location where it paused. - +PauseMission Pause the mission. + Pausing the mission puts the vehicle into + [HOLD mode](https://docs.px4.io/en/flight_modes/hold.html). + A multicopter should just hover at the spot while a fixedwing vehicle should loiter + around the location where it paused. */ +func (s *ServiceImpl) PauseMission( + ctx context.Context, -func (s *ServiceImpl) PauseMission(ctx context.Context) (*PauseMissionResponse, error) { - +) (*PauseMissionResponse, error) { request := &PauseMissionRequest{} response, err := s.Client.PauseMission(ctx, request) if err != nil { @@ -178,13 +153,12 @@ func (s *ServiceImpl) PauseMission(ctx context.Context) (*PauseMissionResponse, } /* - Clear the mission saved on the vehicle. - - +ClearMission Clear the mission saved on the vehicle. */ +func (s *ServiceImpl) ClearMission( + ctx context.Context, -func (s *ServiceImpl) ClearMission(ctx context.Context) (*ClearMissionResponse, error) { - +) (*ClearMissionResponse, error) { request := &ClearMissionRequest{} response, err := s.Client.ClearMission(ctx, request) if err != nil { @@ -194,22 +168,19 @@ func (s *ServiceImpl) ClearMission(ctx context.Context) (*ClearMissionResponse, } /* - Sets the raw mission item index to go to. - - By setting the current index to 0, the mission is restarted from the beginning. If it is set - to a specific index of a raw mission item, the mission will be set to this item. - - Parameters - ---------- - index int32 - +SetCurrentMissionItem Sets the raw mission item index to go to. + By setting the current index to 0, the mission is restarted from the beginning. If it is set + to a specific index of a raw mission item, the mission will be set to this item. */ +func (s *ServiceImpl) SetCurrentMissionItem( + ctx context.Context, + index int32, -func (s *ServiceImpl) SetCurrentMissionItem(ctx context.Context, index int32) (*SetCurrentMissionItemResponse, error) { - - request := &SetCurrentMissionItemRequest{} - request.Index = index +) (*SetCurrentMissionItemResponse, error) { + request := &SetCurrentMissionItemRequest{ + Index: index, + } response, err := s.Client.SetCurrentMissionItem(ctx, request) if err != nil { return nil, err @@ -218,12 +189,12 @@ func (s *ServiceImpl) SetCurrentMissionItem(ctx context.Context, index int32) (* } /* - Subscribe to mission progress updates. - - +MissionProgress Subscribe to mission progress updates. */ +func (a *ServiceImpl) MissionProgress( + ctx context.Context, -func (a *ServiceImpl) MissionProgress(ctx context.Context) (<-chan *MissionProgress, error) { +) (<-chan *MissionProgress, error) { ch := make(chan *MissionProgress) request := &SubscribeMissionProgressRequest{} stream, err := a.Client.SubscribeMissionProgress(ctx, request) @@ -242,8 +213,7 @@ func (a *ServiceImpl) MissionProgress(ctx context.Context) (<-chan *MissionProgr if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive MissionProgress messages, err: %v\n", err) - break + log.Fatalf("Unable to receive MissionProgress messages, err: %v", err) } ch <- m.GetMissionProgress() } @@ -252,18 +222,19 @@ func (a *ServiceImpl) MissionProgress(ctx context.Context) (<-chan *MissionProgr } /* - * - Subscribes to mission changed. - - This notification can be used to be informed if a ground station has - been uploaded or changed by a ground station or companion computer. +MissionChanged * - @param callback Callback to notify about change. + Subscribes to mission changed. + This notification can be used to be informed if a ground station has + been uploaded or changed by a ground station or companion computer. + @param callback Callback to notify about change. */ +func (a *ServiceImpl) MissionChanged( + ctx context.Context, -func (a *ServiceImpl) MissionChanged(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeMissionChangedRequest{} stream, err := a.Client.SubscribeMissionChanged(ctx, request) @@ -282,8 +253,7 @@ func (a *ServiceImpl) MissionChanged(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive MissionChanged messages, err: %v\n", err) - break + log.Fatalf("Unable to receive MissionChanged messages, err: %v", err) } ch <- m.GetMissionChanged() } @@ -292,67 +262,49 @@ func (a *ServiceImpl) MissionChanged(ctx context.Context) (<-chan bool, error) { } /* - Import a QGroundControl missions in JSON .plan format, from a file. - - Supported: - - Waypoints - - Survey - Not supported: - - Structure Scan - - Parameters - ---------- - qgcPlanPath string - - Returns - ------- - False - MissionImportData : MissionImportData - The imported mission data - +ImportQgroundcontrolMission Import a QGroundControl missions in JSON .plan format, from a file. + Supported: + - Waypoints + - Survey + Not supported: + - Structure Scan */ +func (s *ServiceImpl) ImportQgroundcontrolMission( + ctx context.Context, + qgcPlanPath string, -func (s *ServiceImpl) ImportQgroundcontrolMission(ctx context.Context, qgcPlanPath string) (*ImportQgroundcontrolMissionResponse, error) { - request := &ImportQgroundcontrolMissionRequest{} - request.QgcPlanPath = qgcPlanPath +) (*ImportQgroundcontrolMissionResponse, error) { + request := &ImportQgroundcontrolMissionRequest{ + QgcPlanPath: qgcPlanPath, + } response, err := s.Client.ImportQgroundcontrolMission(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Import a QGroundControl missions in JSON .plan format, from a string. - - Supported: - - Waypoints - - Survey - Not supported: - - Structure Scan - - Parameters - ---------- - qgcPlan string - - Returns - ------- - False - MissionImportData : MissionImportData - The imported mission data - +ImportQgroundcontrolMissionFromString Import a QGroundControl missions in JSON .plan format, from a string. + Supported: + - Waypoints + - Survey + Not supported: + - Structure Scan */ +func (s *ServiceImpl) ImportQgroundcontrolMissionFromString( + ctx context.Context, + qgcPlan string, -func (s *ServiceImpl) ImportQgroundcontrolMissionFromString(ctx context.Context, qgcPlan string) (*ImportQgroundcontrolMissionFromStringResponse, error) { - request := &ImportQgroundcontrolMissionFromStringRequest{} - request.QgcPlan = qgcPlan +) (*ImportQgroundcontrolMissionFromStringResponse, error) { + request := &ImportQgroundcontrolMissionFromStringRequest{ + QgcPlan: qgcPlan, + } response, err := s.Client.ImportQgroundcontrolMissionFromString(ctx, request) if err != nil { return nil, err } return response, nil - } diff --git a/Sources/mission_raw/mission_raw.pb.go b/Sources/mission_raw/mission_raw.pb.go index 59adb02..99ec487 100644 --- a/Sources/mission_raw/mission_raw.pb.go +++ b/Sources/mission_raw/mission_raw.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: mission_raw.proto package mission_raw import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -128,11 +129,9 @@ type UploadMissionRequest struct { func (x *UploadMissionRequest) Reset() { *x = UploadMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadMissionRequest) String() string { @@ -143,7 +142,7 @@ func (*UploadMissionRequest) ProtoMessage() {} func (x *UploadMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -175,11 +174,9 @@ type UploadMissionResponse struct { func (x *UploadMissionResponse) Reset() { *x = UploadMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadMissionResponse) String() string { @@ -190,7 +187,7 @@ func (*UploadMissionResponse) ProtoMessage() {} func (x *UploadMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -222,11 +219,9 @@ type UploadGeofenceRequest struct { func (x *UploadGeofenceRequest) Reset() { *x = UploadGeofenceRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadGeofenceRequest) String() string { @@ -237,7 +232,7 @@ func (*UploadGeofenceRequest) ProtoMessage() {} func (x *UploadGeofenceRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -269,11 +264,9 @@ type UploadGeofenceResponse struct { func (x *UploadGeofenceResponse) Reset() { *x = UploadGeofenceResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadGeofenceResponse) String() string { @@ -284,7 +277,7 @@ func (*UploadGeofenceResponse) ProtoMessage() {} func (x *UploadGeofenceResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -316,11 +309,9 @@ type UploadRallyPointsRequest struct { func (x *UploadRallyPointsRequest) Reset() { *x = UploadRallyPointsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadRallyPointsRequest) String() string { @@ -331,7 +322,7 @@ func (*UploadRallyPointsRequest) ProtoMessage() {} func (x *UploadRallyPointsRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -363,11 +354,9 @@ type UploadRallyPointsResponse struct { func (x *UploadRallyPointsResponse) Reset() { *x = UploadRallyPointsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UploadRallyPointsResponse) String() string { @@ -378,7 +367,7 @@ func (*UploadRallyPointsResponse) ProtoMessage() {} func (x *UploadRallyPointsResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -408,11 +397,9 @@ type CancelMissionUploadRequest struct { func (x *CancelMissionUploadRequest) Reset() { *x = CancelMissionUploadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionUploadRequest) String() string { @@ -423,7 +410,7 @@ func (*CancelMissionUploadRequest) ProtoMessage() {} func (x *CancelMissionUploadRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -448,11 +435,9 @@ type CancelMissionUploadResponse struct { func (x *CancelMissionUploadResponse) Reset() { *x = CancelMissionUploadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionUploadResponse) String() string { @@ -463,7 +448,7 @@ func (*CancelMissionUploadResponse) ProtoMessage() {} func (x *CancelMissionUploadResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -493,11 +478,9 @@ type DownloadMissionRequest struct { func (x *DownloadMissionRequest) Reset() { *x = DownloadMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadMissionRequest) String() string { @@ -508,7 +491,7 @@ func (*DownloadMissionRequest) ProtoMessage() {} func (x *DownloadMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -534,11 +517,9 @@ type DownloadMissionResponse struct { func (x *DownloadMissionResponse) Reset() { *x = DownloadMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DownloadMissionResponse) String() string { @@ -549,7 +530,7 @@ func (*DownloadMissionResponse) ProtoMessage() {} func (x *DownloadMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -586,11 +567,9 @@ type CancelMissionDownloadRequest struct { func (x *CancelMissionDownloadRequest) Reset() { *x = CancelMissionDownloadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionDownloadRequest) String() string { @@ -601,7 +580,7 @@ func (*CancelMissionDownloadRequest) ProtoMessage() {} func (x *CancelMissionDownloadRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -626,11 +605,9 @@ type CancelMissionDownloadResponse struct { func (x *CancelMissionDownloadResponse) Reset() { *x = CancelMissionDownloadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CancelMissionDownloadResponse) String() string { @@ -641,7 +618,7 @@ func (*CancelMissionDownloadResponse) ProtoMessage() {} func (x *CancelMissionDownloadResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -671,11 +648,9 @@ type StartMissionRequest struct { func (x *StartMissionRequest) Reset() { *x = StartMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartMissionRequest) String() string { @@ -686,7 +661,7 @@ func (*StartMissionRequest) ProtoMessage() {} func (x *StartMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -711,11 +686,9 @@ type StartMissionResponse struct { func (x *StartMissionResponse) Reset() { *x = StartMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartMissionResponse) String() string { @@ -726,7 +699,7 @@ func (*StartMissionResponse) ProtoMessage() {} func (x *StartMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -756,11 +729,9 @@ type PauseMissionRequest struct { func (x *PauseMissionRequest) Reset() { *x = PauseMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PauseMissionRequest) String() string { @@ -771,7 +742,7 @@ func (*PauseMissionRequest) ProtoMessage() {} func (x *PauseMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -796,11 +767,9 @@ type PauseMissionResponse struct { func (x *PauseMissionResponse) Reset() { *x = PauseMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PauseMissionResponse) String() string { @@ -811,7 +780,7 @@ func (*PauseMissionResponse) ProtoMessage() {} func (x *PauseMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -841,11 +810,9 @@ type ClearMissionRequest struct { func (x *ClearMissionRequest) Reset() { *x = ClearMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearMissionRequest) String() string { @@ -856,7 +823,7 @@ func (*ClearMissionRequest) ProtoMessage() {} func (x *ClearMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -881,11 +848,9 @@ type ClearMissionResponse struct { func (x *ClearMissionResponse) Reset() { *x = ClearMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearMissionResponse) String() string { @@ -896,7 +861,7 @@ func (*ClearMissionResponse) ProtoMessage() {} func (x *ClearMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -928,11 +893,9 @@ type SetCurrentMissionItemRequest struct { func (x *SetCurrentMissionItemRequest) Reset() { *x = SetCurrentMissionItemRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentMissionItemRequest) String() string { @@ -943,7 +906,7 @@ func (*SetCurrentMissionItemRequest) ProtoMessage() {} func (x *SetCurrentMissionItemRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -975,11 +938,9 @@ type SetCurrentMissionItemResponse struct { func (x *SetCurrentMissionItemResponse) Reset() { *x = SetCurrentMissionItemResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentMissionItemResponse) String() string { @@ -990,7 +951,7 @@ func (*SetCurrentMissionItemResponse) ProtoMessage() {} func (x *SetCurrentMissionItemResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1020,11 +981,9 @@ type SubscribeMissionProgressRequest struct { func (x *SubscribeMissionProgressRequest) Reset() { *x = SubscribeMissionProgressRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeMissionProgressRequest) String() string { @@ -1035,7 +994,7 @@ func (*SubscribeMissionProgressRequest) ProtoMessage() {} func (x *SubscribeMissionProgressRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1060,11 +1019,9 @@ type MissionProgressResponse struct { func (x *MissionProgressResponse) Reset() { *x = MissionProgressResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionProgressResponse) String() string { @@ -1075,7 +1032,7 @@ func (*MissionProgressResponse) ProtoMessage() {} func (x *MissionProgressResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1105,11 +1062,9 @@ type SubscribeMissionChangedRequest struct { func (x *SubscribeMissionChangedRequest) Reset() { *x = SubscribeMissionChangedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeMissionChangedRequest) String() string { @@ -1120,7 +1075,7 @@ func (*SubscribeMissionChangedRequest) ProtoMessage() {} func (x *SubscribeMissionChangedRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1145,11 +1100,9 @@ type MissionChangedResponse struct { func (x *MissionChangedResponse) Reset() { *x = MissionChangedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionChangedResponse) String() string { @@ -1160,7 +1113,7 @@ func (*MissionChangedResponse) ProtoMessage() {} func (x *MissionChangedResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1192,11 +1145,9 @@ type ImportQgroundcontrolMissionRequest struct { func (x *ImportQgroundcontrolMissionRequest) Reset() { *x = ImportQgroundcontrolMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ImportQgroundcontrolMissionRequest) String() string { @@ -1207,7 +1158,7 @@ func (*ImportQgroundcontrolMissionRequest) ProtoMessage() {} func (x *ImportQgroundcontrolMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1240,11 +1191,9 @@ type ImportQgroundcontrolMissionResponse struct { func (x *ImportQgroundcontrolMissionResponse) Reset() { *x = ImportQgroundcontrolMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ImportQgroundcontrolMissionResponse) String() string { @@ -1255,7 +1204,7 @@ func (*ImportQgroundcontrolMissionResponse) ProtoMessage() {} func (x *ImportQgroundcontrolMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1294,11 +1243,9 @@ type ImportQgroundcontrolMissionFromStringRequest struct { func (x *ImportQgroundcontrolMissionFromStringRequest) Reset() { *x = ImportQgroundcontrolMissionFromStringRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ImportQgroundcontrolMissionFromStringRequest) String() string { @@ -1309,7 +1256,7 @@ func (*ImportQgroundcontrolMissionFromStringRequest) ProtoMessage() {} func (x *ImportQgroundcontrolMissionFromStringRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1342,11 +1289,9 @@ type ImportQgroundcontrolMissionFromStringResponse struct { func (x *ImportQgroundcontrolMissionFromStringResponse) Reset() { *x = ImportQgroundcontrolMissionFromStringResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ImportQgroundcontrolMissionFromStringResponse) String() string { @@ -1357,7 +1302,7 @@ func (*ImportQgroundcontrolMissionFromStringResponse) ProtoMessage() {} func (x *ImportQgroundcontrolMissionFromStringResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1398,11 +1343,9 @@ type MissionProgress struct { func (x *MissionProgress) Reset() { *x = MissionProgress{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionProgress) String() string { @@ -1413,7 +1356,7 @@ func (*MissionProgress) ProtoMessage() {} func (x *MissionProgress) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1465,11 +1408,9 @@ type MissionItem struct { func (x *MissionItem) Reset() { *x = MissionItem{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionItem) String() string { @@ -1480,7 +1421,7 @@ func (*MissionItem) ProtoMessage() {} func (x *MissionItem) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1599,11 +1540,9 @@ type MissionImportData struct { func (x *MissionImportData) Reset() { *x = MissionImportData{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionImportData) String() string { @@ -1614,7 +1553,7 @@ func (*MissionImportData) ProtoMessage() {} func (x *MissionImportData) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1662,11 +1601,9 @@ type MissionRawResult struct { func (x *MissionRawResult) Reset() { *x = MissionRawResult{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionRawResult) String() string { @@ -1677,7 +1614,7 @@ func (*MissionRawResult) ProtoMessage() {} func (x *MissionRawResult) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2189,393 +2126,6 @@ func file_mission_raw_proto_init() { if File_mission_raw_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_mission_raw_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*UploadMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*UploadMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*UploadGeofenceRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*UploadGeofenceResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*UploadRallyPointsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*UploadRallyPointsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionUploadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionUploadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*DownloadMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*DownloadMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionDownloadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*CancelMissionDownloadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*StartMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*StartMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*PauseMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*PauseMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*ClearMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*ClearMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentMissionItemRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentMissionItemResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeMissionProgressRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*MissionProgressResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeMissionChangedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*MissionChangedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*ImportQgroundcontrolMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*ImportQgroundcontrolMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*ImportQgroundcontrolMissionFromStringRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*ImportQgroundcontrolMissionFromStringResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*MissionProgress); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*MissionItem); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*MissionImportData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*MissionRawResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/mission_raw/mission_raw_grpc.pb.go b/Sources/mission_raw/mission_raw_grpc.pb.go index 8ef4222..5c04438 100644 --- a/Sources/mission_raw/mission_raw_grpc.pb.go +++ b/Sources/mission_raw/mission_raw_grpc.pb.go @@ -8,6 +8,7 @@ package mission_raw import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/mission_raw_server/mission_raw_server.go b/Sources/mission_raw_server/mission_raw_server.go index 0b8cde0..ab6a10d 100644 --- a/Sources/mission_raw_server/mission_raw_server.go +++ b/Sources/mission_raw_server/mission_raw_server.go @@ -2,11 +2,11 @@ package mission_raw_server import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to when a new mission is uploaded (asynchronous). - - +IncomingMission Subscribe to when a new mission is uploaded (asynchronous). */ +func (a *ServiceImpl) IncomingMission( + ctx context.Context, -func (a *ServiceImpl) IncomingMission(ctx context.Context) (<-chan *MissionPlan, error) { +) (<-chan *MissionPlan, error) { ch := make(chan *MissionPlan) request := &SubscribeIncomingMissionRequest{} stream, err := a.Client.SubscribeIncomingMission(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) IncomingMission(ctx context.Context) (<-chan *MissionPlan, if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive IncomingMission messages, err: %v\n", err) - break + log.Fatalf("Unable to receive IncomingMission messages, err: %v", err) } ch <- m.GetMissionPlan() } @@ -48,12 +47,12 @@ func (a *ServiceImpl) IncomingMission(ctx context.Context) (<-chan *MissionPlan, } /* - Subscribe to when a new current item is set - - +CurrentItemChanged Subscribe to when a new current item is set */ +func (a *ServiceImpl) CurrentItemChanged( + ctx context.Context, -func (a *ServiceImpl) CurrentItemChanged(ctx context.Context) (<-chan *MissionItem, error) { +) (<-chan *MissionItem, error) { ch := make(chan *MissionItem) request := &SubscribeCurrentItemChangedRequest{} stream, err := a.Client.SubscribeCurrentItemChanged(ctx, request) @@ -72,8 +71,7 @@ func (a *ServiceImpl) CurrentItemChanged(ctx context.Context) (<-chan *MissionIt if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CurrentItemChanged messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CurrentItemChanged messages, err: %v", err) } ch <- m.GetMissionItem() } @@ -82,13 +80,12 @@ func (a *ServiceImpl) CurrentItemChanged(ctx context.Context) (<-chan *MissionIt } /* - Set Current item as completed - - +SetCurrentItemComplete Set Current item as completed */ +func (s *ServiceImpl) SetCurrentItemComplete( + ctx context.Context, -func (s *ServiceImpl) SetCurrentItemComplete(ctx context.Context) (*SetCurrentItemCompleteResponse, error) { - +) (*SetCurrentItemCompleteResponse, error) { request := &SetCurrentItemCompleteRequest{} response, err := s.Client.SetCurrentItemComplete(ctx, request) if err != nil { @@ -98,12 +95,12 @@ func (s *ServiceImpl) SetCurrentItemComplete(ctx context.Context) (*SetCurrentIt } /* - Subscribe when a MISSION_CLEAR_ALL is received - - +ClearAll Subscribe when a MISSION_CLEAR_ALL is received */ +func (a *ServiceImpl) ClearAll( + ctx context.Context, -func (a *ServiceImpl) ClearAll(ctx context.Context) (<-chan uint32, error) { +) (<-chan uint32, error) { ch := make(chan uint32) request := &SubscribeClearAllRequest{} stream, err := a.Client.SubscribeClearAll(ctx, request) @@ -122,8 +119,7 @@ func (a *ServiceImpl) ClearAll(ctx context.Context) (<-chan uint32, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ClearAll messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ClearAll messages, err: %v", err) } ch <- m.GetClearType() } diff --git a/Sources/mission_raw_server/mission_raw_server.pb.go b/Sources/mission_raw_server/mission_raw_server.pb.go index ae33a6c..dbe6619 100644 --- a/Sources/mission_raw_server/mission_raw_server.pb.go +++ b/Sources/mission_raw_server/mission_raw_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: mission_raw_server.proto package mission_raw_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -108,11 +109,9 @@ type SubscribeIncomingMissionRequest struct { func (x *SubscribeIncomingMissionRequest) Reset() { *x = SubscribeIncomingMissionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeIncomingMissionRequest) String() string { @@ -123,7 +122,7 @@ func (*SubscribeIncomingMissionRequest) ProtoMessage() {} func (x *SubscribeIncomingMissionRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -149,11 +148,9 @@ type IncomingMissionResponse struct { func (x *IncomingMissionResponse) Reset() { *x = IncomingMissionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IncomingMissionResponse) String() string { @@ -164,7 +161,7 @@ func (*IncomingMissionResponse) ProtoMessage() {} func (x *IncomingMissionResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -201,11 +198,9 @@ type SubscribeCurrentItemChangedRequest struct { func (x *SubscribeCurrentItemChangedRequest) Reset() { *x = SubscribeCurrentItemChangedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCurrentItemChangedRequest) String() string { @@ -216,7 +211,7 @@ func (*SubscribeCurrentItemChangedRequest) ProtoMessage() {} func (x *SubscribeCurrentItemChangedRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -241,11 +236,9 @@ type CurrentItemChangedResponse struct { func (x *CurrentItemChangedResponse) Reset() { *x = CurrentItemChangedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CurrentItemChangedResponse) String() string { @@ -256,7 +249,7 @@ func (*CurrentItemChangedResponse) ProtoMessage() {} func (x *CurrentItemChangedResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -286,11 +279,9 @@ type SubscribeClearAllRequest struct { func (x *SubscribeClearAllRequest) Reset() { *x = SubscribeClearAllRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeClearAllRequest) String() string { @@ -301,7 +292,7 @@ func (*SubscribeClearAllRequest) ProtoMessage() {} func (x *SubscribeClearAllRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -326,11 +317,9 @@ type ClearAllResponse struct { func (x *ClearAllResponse) Reset() { *x = ClearAllResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ClearAllResponse) String() string { @@ -341,7 +330,7 @@ func (*ClearAllResponse) ProtoMessage() {} func (x *ClearAllResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -371,11 +360,9 @@ type SetCurrentItemCompleteRequest struct { func (x *SetCurrentItemCompleteRequest) Reset() { *x = SetCurrentItemCompleteRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentItemCompleteRequest) String() string { @@ -386,7 +373,7 @@ func (*SetCurrentItemCompleteRequest) ProtoMessage() {} func (x *SetCurrentItemCompleteRequest) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -409,11 +396,9 @@ type SetCurrentItemCompleteResponse struct { func (x *SetCurrentItemCompleteResponse) Reset() { *x = SetCurrentItemCompleteResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetCurrentItemCompleteResponse) String() string { @@ -424,7 +409,7 @@ func (*SetCurrentItemCompleteResponse) ProtoMessage() {} func (x *SetCurrentItemCompleteResponse) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -462,11 +447,9 @@ type MissionItem struct { func (x *MissionItem) Reset() { *x = MissionItem{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionItem) String() string { @@ -477,7 +460,7 @@ func (*MissionItem) ProtoMessage() {} func (x *MissionItem) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -594,11 +577,9 @@ type MissionPlan struct { func (x *MissionPlan) Reset() { *x = MissionPlan{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionPlan) String() string { @@ -609,7 +590,7 @@ func (*MissionPlan) ProtoMessage() {} func (x *MissionPlan) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -643,11 +624,9 @@ type MissionProgress struct { func (x *MissionProgress) Reset() { *x = MissionProgress{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionProgress) String() string { @@ -658,7 +637,7 @@ func (*MissionProgress) ProtoMessage() {} func (x *MissionProgress) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -699,11 +678,9 @@ type MissionRawServerResult struct { func (x *MissionRawServerResult) Reset() { *x = MissionRawServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_mission_raw_server_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mission_raw_server_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MissionRawServerResult) String() string { @@ -714,7 +691,7 @@ func (*MissionRawServerResult) ProtoMessage() {} func (x *MissionRawServerResult) ProtoReflect() protoreflect.Message { mi := &file_mission_raw_server_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -946,153 +923,6 @@ func file_mission_raw_server_proto_init() { if File_mission_raw_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_mission_raw_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeIncomingMissionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*IncomingMissionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCurrentItemChangedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*CurrentItemChangedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeClearAllRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*ClearAllResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentItemCompleteRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*SetCurrentItemCompleteResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*MissionItem); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*MissionPlan); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*MissionProgress); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mission_raw_server_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*MissionRawServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/mission_raw_server/mission_raw_server_grpc.pb.go b/Sources/mission_raw_server/mission_raw_server_grpc.pb.go index 3312dd2..0c23e54 100644 --- a/Sources/mission_raw_server/mission_raw_server_grpc.pb.go +++ b/Sources/mission_raw_server/mission_raw_server_grpc.pb.go @@ -8,6 +8,7 @@ package mission_raw_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/mocap/mocap.go b/Sources/mocap/mocap.go index deec904..4b40167 100644 --- a/Sources/mocap/mocap.go +++ b/Sources/mocap/mocap.go @@ -9,21 +9,16 @@ type ServiceImpl struct { } /* - Send Global position/attitude estimate from a vision source. - - Parameters - ---------- - visionPositionEstimate *VisionPositionEstimate - - - +SetVisionPositionEstimate Send Global position/attitude estimate from a vision source. */ +func (s *ServiceImpl) SetVisionPositionEstimate( + ctx context.Context, + visionPositionEstimate *VisionPositionEstimate, -func (s *ServiceImpl) SetVisionPositionEstimate(ctx context.Context, visionPositionEstimate *VisionPositionEstimate) (*SetVisionPositionEstimateResponse, error) { - - request := &SetVisionPositionEstimateRequest{} - request.VisionPositionEstimate = visionPositionEstimate - +) (*SetVisionPositionEstimateResponse, error) { + request := &SetVisionPositionEstimateRequest{ + VisionPositionEstimate: visionPositionEstimate, + } response, err := s.Client.SetVisionPositionEstimate(ctx, request) if err != nil { return nil, err @@ -32,21 +27,16 @@ func (s *ServiceImpl) SetVisionPositionEstimate(ctx context.Context, visionPosit } /* - Send motion capture attitude and position. - - Parameters - ---------- - attitudePositionMocap *AttitudePositionMocap - - - +SetAttitudePositionMocap Send motion capture attitude and position. */ +func (s *ServiceImpl) SetAttitudePositionMocap( + ctx context.Context, + attitudePositionMocap *AttitudePositionMocap, -func (s *ServiceImpl) SetAttitudePositionMocap(ctx context.Context, attitudePositionMocap *AttitudePositionMocap) (*SetAttitudePositionMocapResponse, error) { - - request := &SetAttitudePositionMocapRequest{} - request.AttitudePositionMocap = attitudePositionMocap - +) (*SetAttitudePositionMocapResponse, error) { + request := &SetAttitudePositionMocapRequest{ + AttitudePositionMocap: attitudePositionMocap, + } response, err := s.Client.SetAttitudePositionMocap(ctx, request) if err != nil { return nil, err @@ -55,21 +45,16 @@ func (s *ServiceImpl) SetAttitudePositionMocap(ctx context.Context, attitudePosi } /* - Send odometry information with an external interface. - - Parameters - ---------- - odometry *Odometry - - - +SetOdometry Send odometry information with an external interface. */ +func (s *ServiceImpl) SetOdometry( + ctx context.Context, + odometry *Odometry, -func (s *ServiceImpl) SetOdometry(ctx context.Context, odometry *Odometry) (*SetOdometryResponse, error) { - - request := &SetOdometryRequest{} - request.Odometry = odometry - +) (*SetOdometryResponse, error) { + request := &SetOdometryRequest{ + Odometry: odometry, + } response, err := s.Client.SetOdometry(ctx, request) if err != nil { return nil, err diff --git a/Sources/mocap/mocap.pb.go b/Sources/mocap/mocap.pb.go index 726d296..ce923e1 100644 --- a/Sources/mocap/mocap.pb.go +++ b/Sources/mocap/mocap.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: mocap.proto package mocap import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -136,11 +137,9 @@ type SetVisionPositionEstimateRequest struct { func (x *SetVisionPositionEstimateRequest) Reset() { *x = SetVisionPositionEstimateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVisionPositionEstimateRequest) String() string { @@ -151,7 +150,7 @@ func (*SetVisionPositionEstimateRequest) ProtoMessage() {} func (x *SetVisionPositionEstimateRequest) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -183,11 +182,9 @@ type SetVisionPositionEstimateResponse struct { func (x *SetVisionPositionEstimateResponse) Reset() { *x = SetVisionPositionEstimateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVisionPositionEstimateResponse) String() string { @@ -198,7 +195,7 @@ func (*SetVisionPositionEstimateResponse) ProtoMessage() {} func (x *SetVisionPositionEstimateResponse) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -230,11 +227,9 @@ type SetAttitudePositionMocapRequest struct { func (x *SetAttitudePositionMocapRequest) Reset() { *x = SetAttitudePositionMocapRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAttitudePositionMocapRequest) String() string { @@ -245,7 +240,7 @@ func (*SetAttitudePositionMocapRequest) ProtoMessage() {} func (x *SetAttitudePositionMocapRequest) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -277,11 +272,9 @@ type SetAttitudePositionMocapResponse struct { func (x *SetAttitudePositionMocapResponse) Reset() { *x = SetAttitudePositionMocapResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAttitudePositionMocapResponse) String() string { @@ -292,7 +285,7 @@ func (*SetAttitudePositionMocapResponse) ProtoMessage() {} func (x *SetAttitudePositionMocapResponse) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -324,11 +317,9 @@ type SetOdometryRequest struct { func (x *SetOdometryRequest) Reset() { *x = SetOdometryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetOdometryRequest) String() string { @@ -339,7 +330,7 @@ func (*SetOdometryRequest) ProtoMessage() {} func (x *SetOdometryRequest) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -371,11 +362,9 @@ type SetOdometryResponse struct { func (x *SetOdometryResponse) Reset() { *x = SetOdometryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetOdometryResponse) String() string { @@ -386,7 +375,7 @@ func (*SetOdometryResponse) ProtoMessage() {} func (x *SetOdometryResponse) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -421,11 +410,9 @@ type PositionBody struct { func (x *PositionBody) Reset() { *x = PositionBody{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionBody) String() string { @@ -436,7 +423,7 @@ func (*PositionBody) ProtoMessage() {} func (x *PositionBody) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -485,11 +472,9 @@ type AngleBody struct { func (x *AngleBody) Reset() { *x = AngleBody{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngleBody) String() string { @@ -500,7 +485,7 @@ func (*AngleBody) ProtoMessage() {} func (x *AngleBody) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -549,11 +534,9 @@ type SpeedBody struct { func (x *SpeedBody) Reset() { *x = SpeedBody{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SpeedBody) String() string { @@ -564,7 +547,7 @@ func (*SpeedBody) ProtoMessage() {} func (x *SpeedBody) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -613,11 +596,9 @@ type AngularVelocityBody struct { func (x *AngularVelocityBody) Reset() { *x = AngularVelocityBody{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngularVelocityBody) String() string { @@ -628,7 +609,7 @@ func (*AngularVelocityBody) ProtoMessage() {} func (x *AngularVelocityBody) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -678,11 +659,9 @@ type Covariance struct { func (x *Covariance) Reset() { *x = Covariance{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Covariance) String() string { @@ -693,7 +672,7 @@ func (*Covariance) ProtoMessage() {} func (x *Covariance) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -736,11 +715,9 @@ type Quaternion struct { func (x *Quaternion) Reset() { *x = Quaternion{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Quaternion) String() string { @@ -751,7 +728,7 @@ func (*Quaternion) ProtoMessage() {} func (x *Quaternion) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -808,11 +785,9 @@ type VisionPositionEstimate struct { func (x *VisionPositionEstimate) Reset() { *x = VisionPositionEstimate{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VisionPositionEstimate) String() string { @@ -823,7 +798,7 @@ func (*VisionPositionEstimate) ProtoMessage() {} func (x *VisionPositionEstimate) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -880,11 +855,9 @@ type AttitudePositionMocap struct { func (x *AttitudePositionMocap) Reset() { *x = AttitudePositionMocap{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AttitudePositionMocap) String() string { @@ -895,7 +868,7 @@ func (*AttitudePositionMocap) ProtoMessage() {} func (x *AttitudePositionMocap) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -956,11 +929,9 @@ type Odometry struct { func (x *Odometry) Reset() { *x = Odometry{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Odometry) String() string { @@ -971,7 +942,7 @@ func (*Odometry) ProtoMessage() {} func (x *Odometry) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1054,11 +1025,9 @@ type MocapResult struct { func (x *MocapResult) Reset() { *x = MocapResult{} - if protoimpl.UnsafeEnabled { - mi := &file_mocap_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_mocap_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MocapResult) String() string { @@ -1069,7 +1038,7 @@ func (*MocapResult) ProtoMessage() {} func (x *MocapResult) ProtoReflect() protoreflect.Message { mi := &file_mocap_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1360,201 +1329,6 @@ func file_mocap_proto_init() { if File_mocap_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_mocap_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SetVisionPositionEstimateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SetVisionPositionEstimateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetAttitudePositionMocapRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetAttitudePositionMocapResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SetOdometryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*SetOdometryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*PositionBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*AngleBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SpeedBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*AngularVelocityBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*Covariance); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*Quaternion); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*VisionPositionEstimate); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*AttitudePositionMocap); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*Odometry); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_mocap_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*MocapResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/mocap/mocap_grpc.pb.go b/Sources/mocap/mocap_grpc.pb.go index 89ebd1c..dec8d4c 100644 --- a/Sources/mocap/mocap_grpc.pb.go +++ b/Sources/mocap/mocap_grpc.pb.go @@ -8,6 +8,7 @@ package mocap import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/offboard/offboard.go b/Sources/offboard/offboard.go index 0b8f41c..383f72c 100644 --- a/Sources/offboard/offboard.go +++ b/Sources/offboard/offboard.go @@ -9,13 +9,12 @@ type ServiceImpl struct { } /* - Start offboard control. - - +Start Start offboard control. */ +func (s *ServiceImpl) Start( + ctx context.Context, -func (s *ServiceImpl) Start(ctx context.Context) (*StartResponse, error) { - +) (*StartResponse, error) { request := &StartRequest{} response, err := s.Client.Start(ctx, request) if err != nil { @@ -25,15 +24,14 @@ func (s *ServiceImpl) Start(ctx context.Context) (*StartResponse, error) { } /* - Stop offboard control. - - The vehicle will be put into Hold mode: https://docs.px4.io/en/flight_modes/hold.html - +Stop Stop offboard control. + The vehicle will be put into Hold mode: https://docs.px4.io/en/flight_modes/hold.html */ +func (s *ServiceImpl) Stop( + ctx context.Context, -func (s *ServiceImpl) Stop(ctx context.Context) (*StopResponse, error) { - +) (*StopResponse, error) { request := &StopRequest{} response, err := s.Client.Stop(ctx, request) if err != nil { @@ -43,48 +41,34 @@ func (s *ServiceImpl) Stop(ctx context.Context) (*StopResponse, error) { } /* - Check if offboard control is active. - - True means that the vehicle is in offboard mode and we are actively sending - setpoints. - - - - Returns - ------- - False - IsActive : bool - True if offboard is active - +IsActive Check if offboard control is active. + True means that the vehicle is in offboard mode and we are actively sending + setpoints. */ +func (s *ServiceImpl) IsActive( + ctx context.Context, -func (s *ServiceImpl) IsActive(ctx context.Context) (*IsActiveResponse, error) { +) (*IsActiveResponse, error) { request := &IsActiveRequest{} response, err := s.Client.IsActive(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set the attitude in terms of roll, pitch and yaw in degrees with thrust. - - Parameters - ---------- - attitude *Attitude - - - +SetAttitude Set the attitude in terms of roll, pitch and yaw in degrees with thrust. */ +func (s *ServiceImpl) SetAttitude( + ctx context.Context, + attitude *Attitude, -func (s *ServiceImpl) SetAttitude(ctx context.Context, attitude *Attitude) (*SetAttitudeResponse, error) { - - request := &SetAttitudeRequest{} - request.Attitude = attitude - +) (*SetAttitudeResponse, error) { + request := &SetAttitudeRequest{ + Attitude: attitude, + } response, err := s.Client.SetAttitude(ctx, request) if err != nil { return nil, err @@ -93,24 +77,19 @@ func (s *ServiceImpl) SetAttitude(ctx context.Context, attitude *Attitude) (*Set } /* - Set direct actuator control values to groups #0 and #1. - - First 8 controls will go to control group 0, the following 8 controls to control group 1 (if - actuator_control.num_controls more than 8). - - Parameters - ---------- - actuatorControl *ActuatorControl - - +SetActuatorControl Set direct actuator control values to groups #0 and #1. + First 8 controls will go to control group 0, the following 8 controls to control group 1 (if + actuator_control.num_controls more than 8). */ +func (s *ServiceImpl) SetActuatorControl( + ctx context.Context, + actuatorControl *ActuatorControl, -func (s *ServiceImpl) SetActuatorControl(ctx context.Context, actuatorControl *ActuatorControl) (*SetActuatorControlResponse, error) { - - request := &SetActuatorControlRequest{} - request.ActuatorControl = actuatorControl - +) (*SetActuatorControlResponse, error) { + request := &SetActuatorControlRequest{ + ActuatorControl: actuatorControl, + } response, err := s.Client.SetActuatorControl(ctx, request) if err != nil { return nil, err @@ -119,21 +98,16 @@ func (s *ServiceImpl) SetActuatorControl(ctx context.Context, actuatorControl *A } /* - Set the attitude rate in terms of pitch, roll and yaw angular rate along with thrust. - - Parameters - ---------- - attitudeRate *AttitudeRate - - - +SetAttitudeRate Set the attitude rate in terms of pitch, roll and yaw angular rate along with thrust. */ +func (s *ServiceImpl) SetAttitudeRate( + ctx context.Context, + attitudeRate *AttitudeRate, -func (s *ServiceImpl) SetAttitudeRate(ctx context.Context, attitudeRate *AttitudeRate) (*SetAttitudeRateResponse, error) { - - request := &SetAttitudeRateRequest{} - request.AttitudeRate = attitudeRate - +) (*SetAttitudeRateResponse, error) { + request := &SetAttitudeRateRequest{ + AttitudeRate: attitudeRate, + } response, err := s.Client.SetAttitudeRate(ctx, request) if err != nil { return nil, err @@ -142,21 +116,16 @@ func (s *ServiceImpl) SetAttitudeRate(ctx context.Context, attitudeRate *Attitud } /* - Set the position in NED coordinates and yaw. - - Parameters - ---------- - positionNedYaw *PositionNedYaw - - - +SetPositionNed Set the position in NED coordinates and yaw. */ +func (s *ServiceImpl) SetPositionNed( + ctx context.Context, + positionNedYaw *PositionNedYaw, -func (s *ServiceImpl) SetPositionNed(ctx context.Context, positionNedYaw *PositionNedYaw) (*SetPositionNedResponse, error) { - - request := &SetPositionNedRequest{} - request.PositionNedYaw = positionNedYaw - +) (*SetPositionNedResponse, error) { + request := &SetPositionNedRequest{ + PositionNedYaw: positionNedYaw, + } response, err := s.Client.SetPositionNed(ctx, request) if err != nil { return nil, err @@ -165,21 +134,16 @@ func (s *ServiceImpl) SetPositionNed(ctx context.Context, positionNedYaw *Positi } /* - Set the position in Global coordinates (latitude, longitude, altitude) and yaw - - Parameters - ---------- - positionGlobalYaw *PositionGlobalYaw - - - +SetPositionGlobal Set the position in Global coordinates (latitude, longitude, altitude) and yaw */ +func (s *ServiceImpl) SetPositionGlobal( + ctx context.Context, + positionGlobalYaw *PositionGlobalYaw, -func (s *ServiceImpl) SetPositionGlobal(ctx context.Context, positionGlobalYaw *PositionGlobalYaw) (*SetPositionGlobalResponse, error) { - - request := &SetPositionGlobalRequest{} - request.PositionGlobalYaw = positionGlobalYaw - +) (*SetPositionGlobalResponse, error) { + request := &SetPositionGlobalRequest{ + PositionGlobalYaw: positionGlobalYaw, + } response, err := s.Client.SetPositionGlobal(ctx, request) if err != nil { return nil, err @@ -188,21 +152,16 @@ func (s *ServiceImpl) SetPositionGlobal(ctx context.Context, positionGlobalYaw * } /* - Set the velocity in body coordinates and yaw angular rate. Not available for fixed-wing aircraft. - - Parameters - ---------- - velocityBodyYawspeed *VelocityBodyYawspeed - - - +SetVelocityBody Set the velocity in body coordinates and yaw angular rate. Not available for fixed-wing aircraft. */ +func (s *ServiceImpl) SetVelocityBody( + ctx context.Context, + velocityBodyYawspeed *VelocityBodyYawspeed, -func (s *ServiceImpl) SetVelocityBody(ctx context.Context, velocityBodyYawspeed *VelocityBodyYawspeed) (*SetVelocityBodyResponse, error) { - - request := &SetVelocityBodyRequest{} - request.VelocityBodyYawspeed = velocityBodyYawspeed - +) (*SetVelocityBodyResponse, error) { + request := &SetVelocityBodyRequest{ + VelocityBodyYawspeed: velocityBodyYawspeed, + } response, err := s.Client.SetVelocityBody(ctx, request) if err != nil { return nil, err @@ -211,21 +170,16 @@ func (s *ServiceImpl) SetVelocityBody(ctx context.Context, velocityBodyYawspeed } /* - Set the velocity in NED coordinates and yaw. Not available for fixed-wing aircraft. - - Parameters - ---------- - velocityNedYaw *VelocityNedYaw - - - +SetVelocityNed Set the velocity in NED coordinates and yaw. Not available for fixed-wing aircraft. */ +func (s *ServiceImpl) SetVelocityNed( + ctx context.Context, + velocityNedYaw *VelocityNedYaw, -func (s *ServiceImpl) SetVelocityNed(ctx context.Context, velocityNedYaw *VelocityNedYaw) (*SetVelocityNedResponse, error) { - - request := &SetVelocityNedRequest{} - request.VelocityNedYaw = velocityNedYaw - +) (*SetVelocityNedResponse, error) { + request := &SetVelocityNedRequest{ + VelocityNedYaw: velocityNedYaw, + } response, err := s.Client.SetVelocityNed(ctx, request) if err != nil { return nil, err @@ -234,26 +188,20 @@ func (s *ServiceImpl) SetVelocityNed(ctx context.Context, velocityNedYaw *Veloci } /* - Set the position in NED coordinates, with the velocity to be used as feed-forward. - - Parameters - ---------- - positionNedYaw *PositionNedYaw - - - velocityNedYaw *VelocityNedYaw - - - +SetPositionVelocityNed Set the position in NED coordinates, with the velocity to be used as feed-forward. */ +func (s *ServiceImpl) SetPositionVelocityNed( + ctx context.Context, + positionNedYaw *PositionNedYaw, -func (s *ServiceImpl) SetPositionVelocityNed(ctx context.Context, positionNedYaw *PositionNedYaw, velocityNedYaw *VelocityNedYaw) (*SetPositionVelocityNedResponse, error) { + velocityNedYaw *VelocityNedYaw, - request := &SetPositionVelocityNedRequest{} - request.PositionNedYaw = positionNedYaw - - request.VelocityNedYaw = velocityNedYaw +) (*SetPositionVelocityNedResponse, error) { + request := &SetPositionVelocityNedRequest{ + PositionNedYaw: positionNedYaw, + VelocityNedYaw: velocityNedYaw, + } response, err := s.Client.SetPositionVelocityNed(ctx, request) if err != nil { return nil, err @@ -262,31 +210,24 @@ func (s *ServiceImpl) SetPositionVelocityNed(ctx context.Context, positionNedYaw } /* - Set the position, velocity and acceleration in NED coordinates, with velocity and acceleration used as feed-forward. - - Parameters - ---------- - positionNedYaw *PositionNedYaw - - - velocityNedYaw *VelocityNedYaw - - - accelerationNed *AccelerationNed - - - +SetPositionVelocityAccelerationNed Set the position, velocity and acceleration in NED coordinates, with velocity and acceleration used as feed-forward. */ +func (s *ServiceImpl) SetPositionVelocityAccelerationNed( + ctx context.Context, + positionNedYaw *PositionNedYaw, -func (s *ServiceImpl) SetPositionVelocityAccelerationNed(ctx context.Context, positionNedYaw *PositionNedYaw, velocityNedYaw *VelocityNedYaw, accelerationNed *AccelerationNed) (*SetPositionVelocityAccelerationNedResponse, error) { + velocityNedYaw *VelocityNedYaw, - request := &SetPositionVelocityAccelerationNedRequest{} - request.PositionNedYaw = positionNedYaw + accelerationNed *AccelerationNed, - request.VelocityNedYaw = velocityNedYaw +) (*SetPositionVelocityAccelerationNedResponse, error) { + request := &SetPositionVelocityAccelerationNedRequest{ + PositionNedYaw: positionNedYaw, - request.AccelerationNed = accelerationNed + VelocityNedYaw: velocityNedYaw, + AccelerationNed: accelerationNed, + } response, err := s.Client.SetPositionVelocityAccelerationNed(ctx, request) if err != nil { return nil, err @@ -295,21 +236,16 @@ func (s *ServiceImpl) SetPositionVelocityAccelerationNed(ctx context.Context, po } /* - Set the acceleration in NED coordinates. - - Parameters - ---------- - accelerationNed *AccelerationNed - - - +SetAccelerationNed Set the acceleration in NED coordinates. */ +func (s *ServiceImpl) SetAccelerationNed( + ctx context.Context, + accelerationNed *AccelerationNed, -func (s *ServiceImpl) SetAccelerationNed(ctx context.Context, accelerationNed *AccelerationNed) (*SetAccelerationNedResponse, error) { - - request := &SetAccelerationNedRequest{} - request.AccelerationNed = accelerationNed - +) (*SetAccelerationNedResponse, error) { + request := &SetAccelerationNedRequest{ + AccelerationNed: accelerationNed, + } response, err := s.Client.SetAccelerationNed(ctx, request) if err != nil { return nil, err diff --git a/Sources/offboard/offboard.pb.go b/Sources/offboard/offboard.pb.go index f0d208b..b2b6a40 100644 --- a/Sources/offboard/offboard.pb.go +++ b/Sources/offboard/offboard.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: offboard.proto package offboard import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -146,11 +147,9 @@ type StartRequest struct { func (x *StartRequest) Reset() { *x = StartRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartRequest) String() string { @@ -161,7 +160,7 @@ func (*StartRequest) ProtoMessage() {} func (x *StartRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -186,11 +185,9 @@ type StartResponse struct { func (x *StartResponse) Reset() { *x = StartResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StartResponse) String() string { @@ -201,7 +198,7 @@ func (*StartResponse) ProtoMessage() {} func (x *StartResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -231,11 +228,9 @@ type StopRequest struct { func (x *StopRequest) Reset() { *x = StopRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopRequest) String() string { @@ -246,7 +241,7 @@ func (*StopRequest) ProtoMessage() {} func (x *StopRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -271,11 +266,9 @@ type StopResponse struct { func (x *StopResponse) Reset() { *x = StopResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StopResponse) String() string { @@ -286,7 +279,7 @@ func (*StopResponse) ProtoMessage() {} func (x *StopResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -316,11 +309,9 @@ type IsActiveRequest struct { func (x *IsActiveRequest) Reset() { *x = IsActiveRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IsActiveRequest) String() string { @@ -331,7 +322,7 @@ func (*IsActiveRequest) ProtoMessage() {} func (x *IsActiveRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -356,11 +347,9 @@ type IsActiveResponse struct { func (x *IsActiveResponse) Reset() { *x = IsActiveResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IsActiveResponse) String() string { @@ -371,7 +360,7 @@ func (*IsActiveResponse) ProtoMessage() {} func (x *IsActiveResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -403,11 +392,9 @@ type SetAttitudeRequest struct { func (x *SetAttitudeRequest) Reset() { *x = SetAttitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAttitudeRequest) String() string { @@ -418,7 +405,7 @@ func (*SetAttitudeRequest) ProtoMessage() {} func (x *SetAttitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -450,11 +437,9 @@ type SetAttitudeResponse struct { func (x *SetAttitudeResponse) Reset() { *x = SetAttitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAttitudeResponse) String() string { @@ -465,7 +450,7 @@ func (*SetAttitudeResponse) ProtoMessage() {} func (x *SetAttitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -497,11 +482,9 @@ type SetActuatorControlRequest struct { func (x *SetActuatorControlRequest) Reset() { *x = SetActuatorControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetActuatorControlRequest) String() string { @@ -512,7 +495,7 @@ func (*SetActuatorControlRequest) ProtoMessage() {} func (x *SetActuatorControlRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -544,11 +527,9 @@ type SetActuatorControlResponse struct { func (x *SetActuatorControlResponse) Reset() { *x = SetActuatorControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetActuatorControlResponse) String() string { @@ -559,7 +540,7 @@ func (*SetActuatorControlResponse) ProtoMessage() {} func (x *SetActuatorControlResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -591,11 +572,9 @@ type SetAttitudeRateRequest struct { func (x *SetAttitudeRateRequest) Reset() { *x = SetAttitudeRateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAttitudeRateRequest) String() string { @@ -606,7 +585,7 @@ func (*SetAttitudeRateRequest) ProtoMessage() {} func (x *SetAttitudeRateRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -638,11 +617,9 @@ type SetAttitudeRateResponse struct { func (x *SetAttitudeRateResponse) Reset() { *x = SetAttitudeRateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAttitudeRateResponse) String() string { @@ -653,7 +630,7 @@ func (*SetAttitudeRateResponse) ProtoMessage() {} func (x *SetAttitudeRateResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -685,11 +662,9 @@ type SetPositionNedRequest struct { func (x *SetPositionNedRequest) Reset() { *x = SetPositionNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionNedRequest) String() string { @@ -700,7 +675,7 @@ func (*SetPositionNedRequest) ProtoMessage() {} func (x *SetPositionNedRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -732,11 +707,9 @@ type SetPositionNedResponse struct { func (x *SetPositionNedResponse) Reset() { *x = SetPositionNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionNedResponse) String() string { @@ -747,7 +720,7 @@ func (*SetPositionNedResponse) ProtoMessage() {} func (x *SetPositionNedResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -779,11 +752,9 @@ type SetPositionGlobalRequest struct { func (x *SetPositionGlobalRequest) Reset() { *x = SetPositionGlobalRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionGlobalRequest) String() string { @@ -794,7 +765,7 @@ func (*SetPositionGlobalRequest) ProtoMessage() {} func (x *SetPositionGlobalRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -826,11 +797,9 @@ type SetPositionGlobalResponse struct { func (x *SetPositionGlobalResponse) Reset() { *x = SetPositionGlobalResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionGlobalResponse) String() string { @@ -841,7 +810,7 @@ func (*SetPositionGlobalResponse) ProtoMessage() {} func (x *SetPositionGlobalResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -873,11 +842,9 @@ type SetVelocityBodyRequest struct { func (x *SetVelocityBodyRequest) Reset() { *x = SetVelocityBodyRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVelocityBodyRequest) String() string { @@ -888,7 +855,7 @@ func (*SetVelocityBodyRequest) ProtoMessage() {} func (x *SetVelocityBodyRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -920,11 +887,9 @@ type SetVelocityBodyResponse struct { func (x *SetVelocityBodyResponse) Reset() { *x = SetVelocityBodyResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVelocityBodyResponse) String() string { @@ -935,7 +900,7 @@ func (*SetVelocityBodyResponse) ProtoMessage() {} func (x *SetVelocityBodyResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -967,11 +932,9 @@ type SetVelocityNedRequest struct { func (x *SetVelocityNedRequest) Reset() { *x = SetVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVelocityNedRequest) String() string { @@ -982,7 +945,7 @@ func (*SetVelocityNedRequest) ProtoMessage() {} func (x *SetVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1014,11 +977,9 @@ type SetVelocityNedResponse struct { func (x *SetVelocityNedResponse) Reset() { *x = SetVelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetVelocityNedResponse) String() string { @@ -1029,7 +990,7 @@ func (*SetVelocityNedResponse) ProtoMessage() {} func (x *SetVelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1062,11 +1023,9 @@ type SetPositionVelocityNedRequest struct { func (x *SetPositionVelocityNedRequest) Reset() { *x = SetPositionVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionVelocityNedRequest) String() string { @@ -1077,7 +1036,7 @@ func (*SetPositionVelocityNedRequest) ProtoMessage() {} func (x *SetPositionVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1118,11 +1077,9 @@ type SetPositionVelocityAccelerationNedRequest struct { func (x *SetPositionVelocityAccelerationNedRequest) Reset() { *x = SetPositionVelocityAccelerationNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionVelocityAccelerationNedRequest) String() string { @@ -1133,7 +1090,7 @@ func (*SetPositionVelocityAccelerationNedRequest) ProtoMessage() {} func (x *SetPositionVelocityAccelerationNedRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1179,11 +1136,9 @@ type SetPositionVelocityNedResponse struct { func (x *SetPositionVelocityNedResponse) Reset() { *x = SetPositionVelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionVelocityNedResponse) String() string { @@ -1194,7 +1149,7 @@ func (*SetPositionVelocityNedResponse) ProtoMessage() {} func (x *SetPositionVelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1226,11 +1181,9 @@ type SetPositionVelocityAccelerationNedResponse struct { func (x *SetPositionVelocityAccelerationNedResponse) Reset() { *x = SetPositionVelocityAccelerationNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetPositionVelocityAccelerationNedResponse) String() string { @@ -1241,7 +1194,7 @@ func (*SetPositionVelocityAccelerationNedResponse) ProtoMessage() {} func (x *SetPositionVelocityAccelerationNedResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1273,11 +1226,9 @@ type SetAccelerationNedRequest struct { func (x *SetAccelerationNedRequest) Reset() { *x = SetAccelerationNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAccelerationNedRequest) String() string { @@ -1288,7 +1239,7 @@ func (*SetAccelerationNedRequest) ProtoMessage() {} func (x *SetAccelerationNedRequest) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1320,11 +1271,9 @@ type SetAccelerationNedResponse struct { func (x *SetAccelerationNedResponse) Reset() { *x = SetAccelerationNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetAccelerationNedResponse) String() string { @@ -1335,7 +1284,7 @@ func (*SetAccelerationNedResponse) ProtoMessage() {} func (x *SetAccelerationNedResponse) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1371,11 +1320,9 @@ type Attitude struct { func (x *Attitude) Reset() { *x = Attitude{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Attitude) String() string { @@ -1386,7 +1333,7 @@ func (*Attitude) ProtoMessage() {} func (x *Attitude) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1441,11 +1388,9 @@ type ActuatorControlGroup struct { func (x *ActuatorControlGroup) Reset() { *x = ActuatorControlGroup{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorControlGroup) String() string { @@ -1456,7 +1401,7 @@ func (*ActuatorControlGroup) ProtoMessage() {} func (x *ActuatorControlGroup) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1503,11 +1448,9 @@ type ActuatorControl struct { func (x *ActuatorControl) Reset() { *x = ActuatorControl{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorControl) String() string { @@ -1518,7 +1461,7 @@ func (*ActuatorControl) ProtoMessage() {} func (x *ActuatorControl) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1554,11 +1497,9 @@ type AttitudeRate struct { func (x *AttitudeRate) Reset() { *x = AttitudeRate{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AttitudeRate) String() string { @@ -1569,7 +1510,7 @@ func (*AttitudeRate) ProtoMessage() {} func (x *AttitudeRate) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1626,11 +1567,9 @@ type PositionNedYaw struct { func (x *PositionNedYaw) Reset() { *x = PositionNedYaw{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionNedYaw) String() string { @@ -1641,7 +1580,7 @@ func (*PositionNedYaw) ProtoMessage() {} func (x *PositionNedYaw) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1699,11 +1638,9 @@ type PositionGlobalYaw struct { func (x *PositionGlobalYaw) Reset() { *x = PositionGlobalYaw{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionGlobalYaw) String() string { @@ -1714,7 +1651,7 @@ func (*PositionGlobalYaw) ProtoMessage() {} func (x *PositionGlobalYaw) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1778,11 +1715,9 @@ type VelocityBodyYawspeed struct { func (x *VelocityBodyYawspeed) Reset() { *x = VelocityBodyYawspeed{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityBodyYawspeed) String() string { @@ -1793,7 +1728,7 @@ func (*VelocityBodyYawspeed) ProtoMessage() {} func (x *VelocityBodyYawspeed) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1850,11 +1785,9 @@ type VelocityNedYaw struct { func (x *VelocityNedYaw) Reset() { *x = VelocityNedYaw{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityNedYaw) String() string { @@ -1865,7 +1798,7 @@ func (*VelocityNedYaw) ProtoMessage() {} func (x *VelocityNedYaw) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1921,11 +1854,9 @@ type AccelerationNed struct { func (x *AccelerationNed) Reset() { *x = AccelerationNed{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[34] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AccelerationNed) String() string { @@ -1936,7 +1867,7 @@ func (*AccelerationNed) ProtoMessage() {} func (x *AccelerationNed) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[34] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1984,11 +1915,9 @@ type OffboardResult struct { func (x *OffboardResult) Reset() { *x = OffboardResult{} - if protoimpl.UnsafeEnabled { - mi := &file_offboard_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_offboard_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *OffboardResult) String() string { @@ -1999,7 +1928,7 @@ func (*OffboardResult) ProtoMessage() {} func (x *OffboardResult) ProtoReflect() protoreflect.Message { mi := &file_offboard_proto_msgTypes[35] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2519,441 +2448,6 @@ func file_offboard_proto_init() { if File_offboard_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_offboard_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*StartRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*StartResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*StopRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*StopResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*IsActiveRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*IsActiveResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SetAttitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*SetAttitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SetActuatorControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*SetActuatorControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SetAttitudeRateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*SetAttitudeRateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionGlobalRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionGlobalResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*SetVelocityBodyRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*SetVelocityBodyResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*SetVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*SetVelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionVelocityAccelerationNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionVelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*SetPositionVelocityAccelerationNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*SetAccelerationNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*SetAccelerationNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*Attitude); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorControlGroup); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorControl); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*AttitudeRate); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*PositionNedYaw); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*PositionGlobalYaw); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*VelocityBodyYawspeed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*VelocityNedYaw); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[34].Exporter = func(v any, i int) any { - switch v := v.(*AccelerationNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_offboard_proto_msgTypes[35].Exporter = func(v any, i int) any { - switch v := v.(*OffboardResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/offboard/offboard_grpc.pb.go b/Sources/offboard/offboard_grpc.pb.go index f75c8d8..9a24d7d 100644 --- a/Sources/offboard/offboard_grpc.pb.go +++ b/Sources/offboard/offboard_grpc.pb.go @@ -8,6 +8,7 @@ package offboard import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/param/param.go b/Sources/param/param.go index b31ab6c..35afc4b 100644 --- a/Sources/param/param.go +++ b/Sources/param/param.go @@ -9,53 +9,40 @@ type ServiceImpl struct { } /* - Get an int parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - Returns - ------- - False - Value : int32 - Value of the requested parameter - +GetParamInt Get an int parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ +func (s *ServiceImpl) GetParamInt( + ctx context.Context, + name string, -func (s *ServiceImpl) GetParamInt(ctx context.Context, name string) (*GetParamIntResponse, error) { - request := &GetParamIntRequest{} - request.Name = name +) (*GetParamIntResponse, error) { + request := &GetParamIntRequest{ + Name: name, + } response, err := s.Client.GetParamInt(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set an int parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - value int32 - +SetParamInt Set an int parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ - -func (s *ServiceImpl) SetParamInt(ctx context.Context, name string, value int32) (*SetParamIntResponse, error) { - - request := &SetParamIntRequest{} - request.Name = name - request.Value = value +func (s *ServiceImpl) SetParamInt( + ctx context.Context, + name string, + value int32, + +) (*SetParamIntResponse, error) { + request := &SetParamIntRequest{ + Name: name, + Value: value, + } response, err := s.Client.SetParamInt(ctx, request) if err != nil { return nil, err @@ -64,53 +51,40 @@ func (s *ServiceImpl) SetParamInt(ctx context.Context, name string, value int32) } /* - Get a float parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - Returns - ------- - False - Value : float32 - Value of the requested parameter - +GetParamFloat Get a float parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ +func (s *ServiceImpl) GetParamFloat( + ctx context.Context, + name string, -func (s *ServiceImpl) GetParamFloat(ctx context.Context, name string) (*GetParamFloatResponse, error) { - request := &GetParamFloatRequest{} - request.Name = name +) (*GetParamFloatResponse, error) { + request := &GetParamFloatRequest{ + Name: name, + } response, err := s.Client.GetParamFloat(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set a float parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - value float32 - +SetParamFloat Set a float parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ - -func (s *ServiceImpl) SetParamFloat(ctx context.Context, name string, value float32) (*SetParamFloatResponse, error) { - - request := &SetParamFloatRequest{} - request.Name = name - request.Value = value +func (s *ServiceImpl) SetParamFloat( + ctx context.Context, + name string, + value float32, + +) (*SetParamFloatResponse, error) { + request := &SetParamFloatRequest{ + Name: name, + Value: value, + } response, err := s.Client.SetParamFloat(ctx, request) if err != nil { return nil, err @@ -119,53 +93,40 @@ func (s *ServiceImpl) SetParamFloat(ctx context.Context, name string, value floa } /* - Get a custom parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - Returns - ------- - False - Value : string - Value of the requested parameter - +GetParamCustom Get a custom parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ +func (s *ServiceImpl) GetParamCustom( + ctx context.Context, + name string, -func (s *ServiceImpl) GetParamCustom(ctx context.Context, name string) (*GetParamCustomResponse, error) { - request := &GetParamCustomRequest{} - request.Name = name +) (*GetParamCustomResponse, error) { + request := &GetParamCustomRequest{ + Name: name, + } response, err := s.Client.GetParamCustom(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Set a custom parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - value string - +SetParamCustom Set a custom parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ - -func (s *ServiceImpl) SetParamCustom(ctx context.Context, name string, value string) (*SetParamCustomResponse, error) { - - request := &SetParamCustomRequest{} - request.Name = name - request.Value = value +func (s *ServiceImpl) SetParamCustom( + ctx context.Context, + name string, + value string, + +) (*SetParamCustomResponse, error) { + request := &SetParamCustomRequest{ + Name: name, + Value: value, + } response, err := s.Client.SetParamCustom(ctx, request) if err != nil { return nil, err @@ -174,49 +135,35 @@ func (s *ServiceImpl) SetParamCustom(ctx context.Context, name string, value str } /* - Get all parameters. - - - - Returns - ------- - False - Params : AllParams - Collection of all parameters - - +GetAllParams Get all parameters. */ +func (s *ServiceImpl) GetAllParams( + ctx context.Context, -func (s *ServiceImpl) GetAllParams(ctx context.Context) (*GetAllParamsResponse, error) { +) (*GetAllParamsResponse, error) { request := &GetAllParamsRequest{} response, err := s.Client.GetAllParams(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Select component ID of parameter component to talk to and param protocol version. - - Default is the autopilot component (1), and Version (0). - - Parameters - ---------- - componentId int32 - - protocolVersion *ProtocolVersion - - +SelectComponent Select component ID of parameter component to talk to and param protocol version. + Default is the autopilot component (1), and Version (0). */ - -func (s *ServiceImpl) SelectComponent(ctx context.Context, componentId int32, protocolVersion *ProtocolVersion) (*SelectComponentResponse, error) { - - request := &SelectComponentRequest{} - request.ComponentId = componentId - request.ProtocolVersion = *protocolVersion +func (s *ServiceImpl) SelectComponent( + ctx context.Context, + componentId int32, + protocolVersion *ProtocolVersion, + +) (*SelectComponentResponse, error) { + request := &SelectComponentRequest{ + ComponentId: componentId, + ProtocolVersion: *protocolVersion, + } response, err := s.Client.SelectComponent(ctx, request) if err != nil { return nil, err diff --git a/Sources/param/param.pb.go b/Sources/param/param.pb.go index 5e73952..112e7f8 100644 --- a/Sources/param/param.pb.go +++ b/Sources/param/param.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: param.proto package param import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -145,11 +146,9 @@ type GetParamIntRequest struct { func (x *GetParamIntRequest) Reset() { *x = GetParamIntRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetParamIntRequest) String() string { @@ -160,7 +159,7 @@ func (*GetParamIntRequest) ProtoMessage() {} func (x *GetParamIntRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -193,11 +192,9 @@ type GetParamIntResponse struct { func (x *GetParamIntResponse) Reset() { *x = GetParamIntResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetParamIntResponse) String() string { @@ -208,7 +205,7 @@ func (*GetParamIntResponse) ProtoMessage() {} func (x *GetParamIntResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -248,11 +245,9 @@ type SetParamIntRequest struct { func (x *SetParamIntRequest) Reset() { *x = SetParamIntRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetParamIntRequest) String() string { @@ -263,7 +258,7 @@ func (*SetParamIntRequest) ProtoMessage() {} func (x *SetParamIntRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -302,11 +297,9 @@ type SetParamIntResponse struct { func (x *SetParamIntResponse) Reset() { *x = SetParamIntResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetParamIntResponse) String() string { @@ -317,7 +310,7 @@ func (*SetParamIntResponse) ProtoMessage() {} func (x *SetParamIntResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -349,11 +342,9 @@ type GetParamFloatRequest struct { func (x *GetParamFloatRequest) Reset() { *x = GetParamFloatRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetParamFloatRequest) String() string { @@ -364,7 +355,7 @@ func (*GetParamFloatRequest) ProtoMessage() {} func (x *GetParamFloatRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -397,11 +388,9 @@ type GetParamFloatResponse struct { func (x *GetParamFloatResponse) Reset() { *x = GetParamFloatResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetParamFloatResponse) String() string { @@ -412,7 +401,7 @@ func (*GetParamFloatResponse) ProtoMessage() {} func (x *GetParamFloatResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -452,11 +441,9 @@ type SetParamFloatRequest struct { func (x *SetParamFloatRequest) Reset() { *x = SetParamFloatRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetParamFloatRequest) String() string { @@ -467,7 +454,7 @@ func (*SetParamFloatRequest) ProtoMessage() {} func (x *SetParamFloatRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -506,11 +493,9 @@ type SetParamFloatResponse struct { func (x *SetParamFloatResponse) Reset() { *x = SetParamFloatResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetParamFloatResponse) String() string { @@ -521,7 +506,7 @@ func (*SetParamFloatResponse) ProtoMessage() {} func (x *SetParamFloatResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -553,11 +538,9 @@ type GetParamCustomRequest struct { func (x *GetParamCustomRequest) Reset() { *x = GetParamCustomRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetParamCustomRequest) String() string { @@ -568,7 +551,7 @@ func (*GetParamCustomRequest) ProtoMessage() {} func (x *GetParamCustomRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -601,11 +584,9 @@ type GetParamCustomResponse struct { func (x *GetParamCustomResponse) Reset() { *x = GetParamCustomResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetParamCustomResponse) String() string { @@ -616,7 +597,7 @@ func (*GetParamCustomResponse) ProtoMessage() {} func (x *GetParamCustomResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -656,11 +637,9 @@ type SetParamCustomRequest struct { func (x *SetParamCustomRequest) Reset() { *x = SetParamCustomRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetParamCustomRequest) String() string { @@ -671,7 +650,7 @@ func (*SetParamCustomRequest) ProtoMessage() {} func (x *SetParamCustomRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -710,11 +689,9 @@ type SetParamCustomResponse struct { func (x *SetParamCustomResponse) Reset() { *x = SetParamCustomResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetParamCustomResponse) String() string { @@ -725,7 +702,7 @@ func (*SetParamCustomResponse) ProtoMessage() {} func (x *SetParamCustomResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -755,11 +732,9 @@ type GetAllParamsRequest struct { func (x *GetAllParamsRequest) Reset() { *x = GetAllParamsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetAllParamsRequest) String() string { @@ -770,7 +745,7 @@ func (*GetAllParamsRequest) ProtoMessage() {} func (x *GetAllParamsRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -795,11 +770,9 @@ type GetAllParamsResponse struct { func (x *GetAllParamsResponse) Reset() { *x = GetAllParamsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetAllParamsResponse) String() string { @@ -810,7 +783,7 @@ func (*GetAllParamsResponse) ProtoMessage() {} func (x *GetAllParamsResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -842,11 +815,9 @@ type SelectComponentResponse struct { func (x *SelectComponentResponse) Reset() { *x = SelectComponentResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SelectComponentResponse) String() string { @@ -857,7 +828,7 @@ func (*SelectComponentResponse) ProtoMessage() {} func (x *SelectComponentResponse) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -890,11 +861,9 @@ type SelectComponentRequest struct { func (x *SelectComponentRequest) Reset() { *x = SelectComponentRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SelectComponentRequest) String() string { @@ -905,7 +874,7 @@ func (*SelectComponentRequest) ProtoMessage() {} func (x *SelectComponentRequest) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -946,11 +915,9 @@ type IntParam struct { func (x *IntParam) Reset() { *x = IntParam{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IntParam) String() string { @@ -961,7 +928,7 @@ func (*IntParam) ProtoMessage() {} func (x *IntParam) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1002,11 +969,9 @@ type FloatParam struct { func (x *FloatParam) Reset() { *x = FloatParam{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FloatParam) String() string { @@ -1017,7 +982,7 @@ func (*FloatParam) ProtoMessage() {} func (x *FloatParam) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1058,11 +1023,9 @@ type CustomParam struct { func (x *CustomParam) Reset() { *x = CustomParam{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CustomParam) String() string { @@ -1073,7 +1036,7 @@ func (*CustomParam) ProtoMessage() {} func (x *CustomParam) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1115,11 +1078,9 @@ type AllParams struct { func (x *AllParams) Reset() { *x = AllParams{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AllParams) String() string { @@ -1130,7 +1091,7 @@ func (*AllParams) ProtoMessage() {} func (x *AllParams) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1178,11 +1139,9 @@ type ParamResult struct { func (x *ParamResult) Reset() { *x = ParamResult{} - if protoimpl.UnsafeEnabled { - mi := &file_param_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ParamResult) String() string { @@ -1193,7 +1152,7 @@ func (*ParamResult) ProtoMessage() {} func (x *ParamResult) ProtoReflect() protoreflect.Message { mi := &file_param_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1495,261 +1454,6 @@ func file_param_proto_init() { if File_param_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_param_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*GetParamIntRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*GetParamIntResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetParamIntRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetParamIntResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*GetParamFloatRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*GetParamFloatResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SetParamFloatRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*SetParamFloatResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*GetParamCustomRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*GetParamCustomResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SetParamCustomRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*SetParamCustomResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*GetAllParamsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*GetAllParamsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*SelectComponentResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*SelectComponentRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*IntParam); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*FloatParam); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*CustomParam); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*AllParams); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*ParamResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/param/param_grpc.pb.go b/Sources/param/param_grpc.pb.go index d694892..65c3c69 100644 --- a/Sources/param/param_grpc.pb.go +++ b/Sources/param/param_grpc.pb.go @@ -8,6 +8,7 @@ package param import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/param_server/param_server.go b/Sources/param_server/param_server.go index 8a1bfa1..38adf88 100644 --- a/Sources/param_server/param_server.go +++ b/Sources/param_server/param_server.go @@ -2,11 +2,11 @@ package param_server import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,53 +14,40 @@ type ServiceImpl struct { } /* - Retrieve an int parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - Returns - ------- - False - Value : int32 - Value of the requested parameter - +RetrieveParamInt Retrieve an int parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ +func (s *ServiceImpl) RetrieveParamInt( + ctx context.Context, + name string, -func (s *ServiceImpl) RetrieveParamInt(ctx context.Context, name string) (*RetrieveParamIntResponse, error) { - request := &RetrieveParamIntRequest{} - request.Name = name +) (*RetrieveParamIntResponse, error) { + request := &RetrieveParamIntRequest{ + Name: name, + } response, err := s.Client.RetrieveParamInt(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Provide an int parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - value int32 - +ProvideParamInt Provide an int parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ - -func (s *ServiceImpl) ProvideParamInt(ctx context.Context, name string, value int32) (*ProvideParamIntResponse, error) { - - request := &ProvideParamIntRequest{} - request.Name = name - request.Value = value +func (s *ServiceImpl) ProvideParamInt( + ctx context.Context, + name string, + value int32, + +) (*ProvideParamIntResponse, error) { + request := &ProvideParamIntRequest{ + Name: name, + Value: value, + } response, err := s.Client.ProvideParamInt(ctx, request) if err != nil { return nil, err @@ -69,53 +56,40 @@ func (s *ServiceImpl) ProvideParamInt(ctx context.Context, name string, value in } /* - Retrieve a float parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - Returns - ------- - False - Value : float32 - Value of the requested parameter - +RetrieveParamFloat Retrieve a float parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ +func (s *ServiceImpl) RetrieveParamFloat( + ctx context.Context, + name string, -func (s *ServiceImpl) RetrieveParamFloat(ctx context.Context, name string) (*RetrieveParamFloatResponse, error) { - request := &RetrieveParamFloatRequest{} - request.Name = name +) (*RetrieveParamFloatResponse, error) { + request := &RetrieveParamFloatRequest{ + Name: name, + } response, err := s.Client.RetrieveParamFloat(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Provide a float parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - value float32 - +ProvideParamFloat Provide a float parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ - -func (s *ServiceImpl) ProvideParamFloat(ctx context.Context, name string, value float32) (*ProvideParamFloatResponse, error) { - - request := &ProvideParamFloatRequest{} - request.Name = name - request.Value = value +func (s *ServiceImpl) ProvideParamFloat( + ctx context.Context, + name string, + value float32, + +) (*ProvideParamFloatResponse, error) { + request := &ProvideParamFloatRequest{ + Name: name, + Value: value, + } response, err := s.Client.ProvideParamFloat(ctx, request) if err != nil { return nil, err @@ -124,53 +98,40 @@ func (s *ServiceImpl) ProvideParamFloat(ctx context.Context, name string, value } /* - Retrieve a custom parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - Returns - ------- - False - Value : string - Value of the requested parameter - +RetrieveParamCustom Retrieve a custom parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ +func (s *ServiceImpl) RetrieveParamCustom( + ctx context.Context, + name string, -func (s *ServiceImpl) RetrieveParamCustom(ctx context.Context, name string) (*RetrieveParamCustomResponse, error) { - request := &RetrieveParamCustomRequest{} - request.Name = name +) (*RetrieveParamCustomResponse, error) { + request := &RetrieveParamCustomRequest{ + Name: name, + } response, err := s.Client.RetrieveParamCustom(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Provide a custom parameter. - - If the type is wrong, the result will be `WRONG_TYPE`. - - Parameters - ---------- - name string - - value string - +ProvideParamCustom Provide a custom parameter. + If the type is wrong, the result will be `WRONG_TYPE`. */ - -func (s *ServiceImpl) ProvideParamCustom(ctx context.Context, name string, value string) (*ProvideParamCustomResponse, error) { - - request := &ProvideParamCustomRequest{} - request.Name = name - request.Value = value +func (s *ServiceImpl) ProvideParamCustom( + ctx context.Context, + name string, + value string, + +) (*ProvideParamCustomResponse, error) { + request := &ProvideParamCustomRequest{ + Name: name, + Value: value, + } response, err := s.Client.ProvideParamCustom(ctx, request) if err != nil { return nil, err @@ -179,36 +140,27 @@ func (s *ServiceImpl) ProvideParamCustom(ctx context.Context, name string, value } /* - Retrieve all parameters. - - - - Returns - ------- - False - Params : AllParams - Collection of all parameters - - +RetrieveAllParams Retrieve all parameters. */ +func (s *ServiceImpl) RetrieveAllParams( + ctx context.Context, -func (s *ServiceImpl) RetrieveAllParams(ctx context.Context) (*RetrieveAllParamsResponse, error) { +) (*RetrieveAllParamsResponse, error) { request := &RetrieveAllParamsRequest{} response, err := s.Client.RetrieveAllParams(ctx, request) if err != nil { return nil, err } return response, nil - } /* - Subscribe to changed int param. - - +ChangedParamInt Subscribe to changed int param. */ +func (a *ServiceImpl) ChangedParamInt( + ctx context.Context, -func (a *ServiceImpl) ChangedParamInt(ctx context.Context) (<-chan *IntParam, error) { +) (<-chan *IntParam, error) { ch := make(chan *IntParam) request := &SubscribeChangedParamIntRequest{} stream, err := a.Client.SubscribeChangedParamInt(ctx, request) @@ -227,8 +179,7 @@ func (a *ServiceImpl) ChangedParamInt(ctx context.Context) (<-chan *IntParam, er if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ChangedParamInt messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ChangedParamInt messages, err: %v", err) } ch <- m.GetParam() } @@ -237,12 +188,12 @@ func (a *ServiceImpl) ChangedParamInt(ctx context.Context) (<-chan *IntParam, er } /* - Subscribe to changed float param. - - +ChangedParamFloat Subscribe to changed float param. */ +func (a *ServiceImpl) ChangedParamFloat( + ctx context.Context, -func (a *ServiceImpl) ChangedParamFloat(ctx context.Context) (<-chan *FloatParam, error) { +) (<-chan *FloatParam, error) { ch := make(chan *FloatParam) request := &SubscribeChangedParamFloatRequest{} stream, err := a.Client.SubscribeChangedParamFloat(ctx, request) @@ -261,8 +212,7 @@ func (a *ServiceImpl) ChangedParamFloat(ctx context.Context) (<-chan *FloatParam if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ChangedParamFloat messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ChangedParamFloat messages, err: %v", err) } ch <- m.GetParam() } @@ -271,12 +221,12 @@ func (a *ServiceImpl) ChangedParamFloat(ctx context.Context) (<-chan *FloatParam } /* - Subscribe to changed custom param. - - +ChangedParamCustom Subscribe to changed custom param. */ +func (a *ServiceImpl) ChangedParamCustom( + ctx context.Context, -func (a *ServiceImpl) ChangedParamCustom(ctx context.Context) (<-chan *CustomParam, error) { +) (<-chan *CustomParam, error) { ch := make(chan *CustomParam) request := &SubscribeChangedParamCustomRequest{} stream, err := a.Client.SubscribeChangedParamCustom(ctx, request) @@ -295,8 +245,7 @@ func (a *ServiceImpl) ChangedParamCustom(ctx context.Context) (<-chan *CustomPar if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ChangedParamCustom messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ChangedParamCustom messages, err: %v", err) } ch <- m.GetParam() } diff --git a/Sources/param_server/param_server.pb.go b/Sources/param_server/param_server.pb.go index 2884e42..c9b9870 100644 --- a/Sources/param_server/param_server.pb.go +++ b/Sources/param_server/param_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: param_server.proto package param_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -92,11 +93,9 @@ type RetrieveParamIntRequest struct { func (x *RetrieveParamIntRequest) Reset() { *x = RetrieveParamIntRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveParamIntRequest) String() string { @@ -107,7 +106,7 @@ func (*RetrieveParamIntRequest) ProtoMessage() {} func (x *RetrieveParamIntRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -140,11 +139,9 @@ type RetrieveParamIntResponse struct { func (x *RetrieveParamIntResponse) Reset() { *x = RetrieveParamIntResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveParamIntResponse) String() string { @@ -155,7 +152,7 @@ func (*RetrieveParamIntResponse) ProtoMessage() {} func (x *RetrieveParamIntResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -195,11 +192,9 @@ type ProvideParamIntRequest struct { func (x *ProvideParamIntRequest) Reset() { *x = ProvideParamIntRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProvideParamIntRequest) String() string { @@ -210,7 +205,7 @@ func (*ProvideParamIntRequest) ProtoMessage() {} func (x *ProvideParamIntRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -249,11 +244,9 @@ type ProvideParamIntResponse struct { func (x *ProvideParamIntResponse) Reset() { *x = ProvideParamIntResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProvideParamIntResponse) String() string { @@ -264,7 +257,7 @@ func (*ProvideParamIntResponse) ProtoMessage() {} func (x *ProvideParamIntResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -296,11 +289,9 @@ type RetrieveParamFloatRequest struct { func (x *RetrieveParamFloatRequest) Reset() { *x = RetrieveParamFloatRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveParamFloatRequest) String() string { @@ -311,7 +302,7 @@ func (*RetrieveParamFloatRequest) ProtoMessage() {} func (x *RetrieveParamFloatRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -344,11 +335,9 @@ type RetrieveParamFloatResponse struct { func (x *RetrieveParamFloatResponse) Reset() { *x = RetrieveParamFloatResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveParamFloatResponse) String() string { @@ -359,7 +348,7 @@ func (*RetrieveParamFloatResponse) ProtoMessage() {} func (x *RetrieveParamFloatResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -399,11 +388,9 @@ type ProvideParamFloatRequest struct { func (x *ProvideParamFloatRequest) Reset() { *x = ProvideParamFloatRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProvideParamFloatRequest) String() string { @@ -414,7 +401,7 @@ func (*ProvideParamFloatRequest) ProtoMessage() {} func (x *ProvideParamFloatRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -453,11 +440,9 @@ type ProvideParamFloatResponse struct { func (x *ProvideParamFloatResponse) Reset() { *x = ProvideParamFloatResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProvideParamFloatResponse) String() string { @@ -468,7 +453,7 @@ func (*ProvideParamFloatResponse) ProtoMessage() {} func (x *ProvideParamFloatResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -500,11 +485,9 @@ type RetrieveParamCustomRequest struct { func (x *RetrieveParamCustomRequest) Reset() { *x = RetrieveParamCustomRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveParamCustomRequest) String() string { @@ -515,7 +498,7 @@ func (*RetrieveParamCustomRequest) ProtoMessage() {} func (x *RetrieveParamCustomRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -548,11 +531,9 @@ type RetrieveParamCustomResponse struct { func (x *RetrieveParamCustomResponse) Reset() { *x = RetrieveParamCustomResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveParamCustomResponse) String() string { @@ -563,7 +544,7 @@ func (*RetrieveParamCustomResponse) ProtoMessage() {} func (x *RetrieveParamCustomResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -603,11 +584,9 @@ type ProvideParamCustomRequest struct { func (x *ProvideParamCustomRequest) Reset() { *x = ProvideParamCustomRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProvideParamCustomRequest) String() string { @@ -618,7 +597,7 @@ func (*ProvideParamCustomRequest) ProtoMessage() {} func (x *ProvideParamCustomRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -657,11 +636,9 @@ type ProvideParamCustomResponse struct { func (x *ProvideParamCustomResponse) Reset() { *x = ProvideParamCustomResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ProvideParamCustomResponse) String() string { @@ -672,7 +649,7 @@ func (*ProvideParamCustomResponse) ProtoMessage() {} func (x *ProvideParamCustomResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -702,11 +679,9 @@ type RetrieveAllParamsRequest struct { func (x *RetrieveAllParamsRequest) Reset() { *x = RetrieveAllParamsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveAllParamsRequest) String() string { @@ -717,7 +692,7 @@ func (*RetrieveAllParamsRequest) ProtoMessage() {} func (x *RetrieveAllParamsRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -742,11 +717,9 @@ type RetrieveAllParamsResponse struct { func (x *RetrieveAllParamsResponse) Reset() { *x = RetrieveAllParamsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetrieveAllParamsResponse) String() string { @@ -757,7 +730,7 @@ func (*RetrieveAllParamsResponse) ProtoMessage() {} func (x *RetrieveAllParamsResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -787,11 +760,9 @@ type SubscribeChangedParamIntRequest struct { func (x *SubscribeChangedParamIntRequest) Reset() { *x = SubscribeChangedParamIntRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeChangedParamIntRequest) String() string { @@ -802,7 +773,7 @@ func (*SubscribeChangedParamIntRequest) ProtoMessage() {} func (x *SubscribeChangedParamIntRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -827,11 +798,9 @@ type ChangedParamIntResponse struct { func (x *ChangedParamIntResponse) Reset() { *x = ChangedParamIntResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ChangedParamIntResponse) String() string { @@ -842,7 +811,7 @@ func (*ChangedParamIntResponse) ProtoMessage() {} func (x *ChangedParamIntResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -872,11 +841,9 @@ type SubscribeChangedParamFloatRequest struct { func (x *SubscribeChangedParamFloatRequest) Reset() { *x = SubscribeChangedParamFloatRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeChangedParamFloatRequest) String() string { @@ -887,7 +854,7 @@ func (*SubscribeChangedParamFloatRequest) ProtoMessage() {} func (x *SubscribeChangedParamFloatRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -912,11 +879,9 @@ type ChangedParamFloatResponse struct { func (x *ChangedParamFloatResponse) Reset() { *x = ChangedParamFloatResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ChangedParamFloatResponse) String() string { @@ -927,7 +892,7 @@ func (*ChangedParamFloatResponse) ProtoMessage() {} func (x *ChangedParamFloatResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -957,11 +922,9 @@ type SubscribeChangedParamCustomRequest struct { func (x *SubscribeChangedParamCustomRequest) Reset() { *x = SubscribeChangedParamCustomRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeChangedParamCustomRequest) String() string { @@ -972,7 +935,7 @@ func (*SubscribeChangedParamCustomRequest) ProtoMessage() {} func (x *SubscribeChangedParamCustomRequest) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -997,11 +960,9 @@ type ChangedParamCustomResponse struct { func (x *ChangedParamCustomResponse) Reset() { *x = ChangedParamCustomResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ChangedParamCustomResponse) String() string { @@ -1012,7 +973,7 @@ func (*ChangedParamCustomResponse) ProtoMessage() {} func (x *ChangedParamCustomResponse) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1046,11 +1007,9 @@ type IntParam struct { func (x *IntParam) Reset() { *x = IntParam{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *IntParam) String() string { @@ -1061,7 +1020,7 @@ func (*IntParam) ProtoMessage() {} func (x *IntParam) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1102,11 +1061,9 @@ type FloatParam struct { func (x *FloatParam) Reset() { *x = FloatParam{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FloatParam) String() string { @@ -1117,7 +1074,7 @@ func (*FloatParam) ProtoMessage() {} func (x *FloatParam) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1158,11 +1115,9 @@ type CustomParam struct { func (x *CustomParam) Reset() { *x = CustomParam{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CustomParam) String() string { @@ -1173,7 +1128,7 @@ func (*CustomParam) ProtoMessage() {} func (x *CustomParam) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1215,11 +1170,9 @@ type AllParams struct { func (x *AllParams) Reset() { *x = AllParams{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AllParams) String() string { @@ -1230,7 +1183,7 @@ func (*AllParams) ProtoMessage() {} func (x *AllParams) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1278,11 +1231,9 @@ type ParamServerResult struct { func (x *ParamServerResult) Reset() { *x = ParamServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_param_server_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_param_server_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ParamServerResult) String() string { @@ -1293,7 +1244,7 @@ func (*ParamServerResult) ProtoMessage() {} func (x *ParamServerResult) ProtoReflect() protoreflect.Message { mi := &file_param_server_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1657,309 +1608,6 @@ func file_param_server_proto_init() { if File_param_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_param_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveParamIntRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveParamIntResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*ProvideParamIntRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*ProvideParamIntResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveParamFloatRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveParamFloatResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*ProvideParamFloatRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*ProvideParamFloatResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveParamCustomRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveParamCustomResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*ProvideParamCustomRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*ProvideParamCustomResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveAllParamsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*RetrieveAllParamsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeChangedParamIntRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*ChangedParamIntResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeChangedParamFloatRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*ChangedParamFloatResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeChangedParamCustomRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*ChangedParamCustomResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*IntParam); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*FloatParam); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*CustomParam); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*AllParams); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_param_server_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*ParamServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/param_server/param_server_grpc.pb.go b/Sources/param_server/param_server_grpc.pb.go index 6836b86..6eb7c81 100644 --- a/Sources/param_server/param_server_grpc.pb.go +++ b/Sources/param_server/param_server_grpc.pb.go @@ -8,6 +8,7 @@ package param_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/rtk/rtk.go b/Sources/rtk/rtk.go index 353a5f7..d03fcfc 100644 --- a/Sources/rtk/rtk.go +++ b/Sources/rtk/rtk.go @@ -9,21 +9,16 @@ type ServiceImpl struct { } /* - Send RTCM data. - - Parameters - ---------- - rtcmData *RtcmData - - - +SendRtcmData Send RTCM data. */ +func (s *ServiceImpl) SendRtcmData( + ctx context.Context, + rtcmData *RtcmData, -func (s *ServiceImpl) SendRtcmData(ctx context.Context, rtcmData *RtcmData) (*SendRtcmDataResponse, error) { - - request := &SendRtcmDataRequest{} - request.RtcmData = rtcmData - +) (*SendRtcmDataResponse, error) { + request := &SendRtcmDataRequest{ + RtcmData: rtcmData, + } response, err := s.Client.SendRtcmData(ctx, request) if err != nil { return nil, err diff --git a/Sources/rtk/rtk.pb.go b/Sources/rtk/rtk.pb.go index 71324d7..80f7bdd 100644 --- a/Sources/rtk/rtk.pb.go +++ b/Sources/rtk/rtk.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: rtk.proto package rtk import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -87,11 +88,9 @@ type RtcmData struct { func (x *RtcmData) Reset() { *x = RtcmData{} - if protoimpl.UnsafeEnabled { - mi := &file_rtk_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_rtk_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RtcmData) String() string { @@ -102,7 +101,7 @@ func (*RtcmData) ProtoMessage() {} func (x *RtcmData) ProtoReflect() protoreflect.Message { mi := &file_rtk_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -134,11 +133,9 @@ type SendRtcmDataRequest struct { func (x *SendRtcmDataRequest) Reset() { *x = SendRtcmDataRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_rtk_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_rtk_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SendRtcmDataRequest) String() string { @@ -149,7 +146,7 @@ func (*SendRtcmDataRequest) ProtoMessage() {} func (x *SendRtcmDataRequest) ProtoReflect() protoreflect.Message { mi := &file_rtk_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -181,11 +178,9 @@ type SendRtcmDataResponse struct { func (x *SendRtcmDataResponse) Reset() { *x = SendRtcmDataResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_rtk_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_rtk_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SendRtcmDataResponse) String() string { @@ -196,7 +191,7 @@ func (*SendRtcmDataResponse) ProtoMessage() {} func (x *SendRtcmDataResponse) ProtoReflect() protoreflect.Message { mi := &file_rtk_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -229,11 +224,9 @@ type RtkResult struct { func (x *RtkResult) Reset() { *x = RtkResult{} - if protoimpl.UnsafeEnabled { - mi := &file_rtk_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_rtk_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RtkResult) String() string { @@ -244,7 +237,7 @@ func (*RtkResult) ProtoMessage() {} func (x *RtkResult) ProtoReflect() protoreflect.Message { mi := &file_rtk_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -355,57 +348,6 @@ func file_rtk_proto_init() { if File_rtk_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_rtk_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*RtcmData); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtk_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SendRtcmDataRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtk_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SendRtcmDataResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_rtk_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*RtkResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/rtk/rtk_grpc.pb.go b/Sources/rtk/rtk_grpc.pb.go index 060d092..e512684 100644 --- a/Sources/rtk/rtk_grpc.pb.go +++ b/Sources/rtk/rtk_grpc.pb.go @@ -8,6 +8,7 @@ package rtk import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/server_utility/server_utility.go b/Sources/server_utility/server_utility.go index 21e4616..98bee33 100644 --- a/Sources/server_utility/server_utility.go +++ b/Sources/server_utility/server_utility.go @@ -9,23 +9,20 @@ type ServiceImpl struct { } /* - Sends a statustext. - - Parameters - ---------- - type *StatusTextType - - - text string - - +SendStatusText Sends a statustext. */ +func (s *ServiceImpl) SendStatusText( + ctx context.Context, + + typeVar StatusTextType, + text string, -func (s *ServiceImpl) SendStatusText(ctx context.Context, statusTextType *StatusTextType, text string) (*SendStatusTextResponse, error) { +) (*SendStatusTextResponse, error) { + request := &SendStatusTextRequest{ - request := &SendStatusTextRequest{} - request.Type = *statusTextType - request.Text = text + Type: typeVar, + Text: text, + } response, err := s.Client.SendStatusText(ctx, request) if err != nil { return nil, err diff --git a/Sources/server_utility/server_utility.pb.go b/Sources/server_utility/server_utility.pb.go index 8b3da89..defc0fd 100644 --- a/Sources/server_utility/server_utility.pb.go +++ b/Sources/server_utility/server_utility.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: server_utility.proto package server_utility import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -152,11 +153,9 @@ type SendStatusTextRequest struct { func (x *SendStatusTextRequest) Reset() { *x = SendStatusTextRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_server_utility_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_server_utility_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SendStatusTextRequest) String() string { @@ -167,7 +166,7 @@ func (*SendStatusTextRequest) ProtoMessage() {} func (x *SendStatusTextRequest) ProtoReflect() protoreflect.Message { mi := &file_server_utility_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -206,11 +205,9 @@ type SendStatusTextResponse struct { func (x *SendStatusTextResponse) Reset() { *x = SendStatusTextResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_server_utility_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_server_utility_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SendStatusTextResponse) String() string { @@ -221,7 +218,7 @@ func (*SendStatusTextResponse) ProtoMessage() {} func (x *SendStatusTextResponse) ProtoReflect() protoreflect.Message { mi := &file_server_utility_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -254,11 +251,9 @@ type ServerUtilityResult struct { func (x *ServerUtilityResult) Reset() { *x = ServerUtilityResult{} - if protoimpl.UnsafeEnabled { - mi := &file_server_utility_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_server_utility_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ServerUtilityResult) String() string { @@ -269,7 +264,7 @@ func (*ServerUtilityResult) ProtoMessage() {} func (x *ServerUtilityResult) ProtoReflect() protoreflect.Message { mi := &file_server_utility_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -406,45 +401,6 @@ func file_server_utility_proto_init() { if File_server_utility_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_server_utility_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SendStatusTextRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_server_utility_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SendStatusTextResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_server_utility_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*ServerUtilityResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/server_utility/server_utility_grpc.pb.go b/Sources/server_utility/server_utility_grpc.pb.go index 28e3681..b4553bb 100644 --- a/Sources/server_utility/server_utility_grpc.pb.go +++ b/Sources/server_utility/server_utility_grpc.pb.go @@ -8,6 +8,7 @@ package server_utility import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/shell/shell.go b/Sources/shell/shell.go index 1ee8590..1773716 100644 --- a/Sources/shell/shell.go +++ b/Sources/shell/shell.go @@ -2,11 +2,11 @@ package shell import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,19 +14,16 @@ type ServiceImpl struct { } /* - Send a command line. - - Parameters - ---------- - command string - - +Send Send a command line. */ +func (s *ServiceImpl) Send( + ctx context.Context, + command string, -func (s *ServiceImpl) Send(ctx context.Context, command string) (*SendResponse, error) { - - request := &SendRequest{} - request.Command = command +) (*SendResponse, error) { + request := &SendRequest{ + Command: command, + } response, err := s.Client.Send(ctx, request) if err != nil { return nil, err @@ -35,14 +32,14 @@ func (s *ServiceImpl) Send(ctx context.Context, command string) (*SendResponse, } /* - Receive feedback from a sent command line. - - This subscription needs to be made before a command line is sent, otherwise, no response will be sent. - +Receive Receive feedback from a sent command line. + This subscription needs to be made before a command line is sent, otherwise, no response will be sent. */ +func (a *ServiceImpl) Receive( + ctx context.Context, -func (a *ServiceImpl) Receive(ctx context.Context) (<-chan string, error) { +) (<-chan string, error) { ch := make(chan string) request := &SubscribeReceiveRequest{} stream, err := a.Client.SubscribeReceive(ctx, request) @@ -61,8 +58,7 @@ func (a *ServiceImpl) Receive(ctx context.Context) (<-chan string, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Receive messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Receive messages, err: %v", err) } ch <- m.GetData() } diff --git a/Sources/shell/shell.pb.go b/Sources/shell/shell.pb.go index 87f75bc..2a856d7 100644 --- a/Sources/shell/shell.pb.go +++ b/Sources/shell/shell.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: shell.proto package shell import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -89,11 +90,9 @@ type SendRequest struct { func (x *SendRequest) Reset() { *x = SendRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_shell_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_shell_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SendRequest) String() string { @@ -104,7 +103,7 @@ func (*SendRequest) ProtoMessage() {} func (x *SendRequest) ProtoReflect() protoreflect.Message { mi := &file_shell_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -136,11 +135,9 @@ type SendResponse struct { func (x *SendResponse) Reset() { *x = SendResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_shell_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_shell_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SendResponse) String() string { @@ -151,7 +148,7 @@ func (*SendResponse) ProtoMessage() {} func (x *SendResponse) ProtoReflect() protoreflect.Message { mi := &file_shell_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -181,11 +178,9 @@ type SubscribeReceiveRequest struct { func (x *SubscribeReceiveRequest) Reset() { *x = SubscribeReceiveRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_shell_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_shell_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeReceiveRequest) String() string { @@ -196,7 +191,7 @@ func (*SubscribeReceiveRequest) ProtoMessage() {} func (x *SubscribeReceiveRequest) ProtoReflect() protoreflect.Message { mi := &file_shell_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -221,11 +216,9 @@ type ReceiveResponse struct { func (x *ReceiveResponse) Reset() { *x = ReceiveResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_shell_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_shell_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ReceiveResponse) String() string { @@ -236,7 +229,7 @@ func (*ReceiveResponse) ProtoMessage() {} func (x *ReceiveResponse) ProtoReflect() protoreflect.Message { mi := &file_shell_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -270,11 +263,9 @@ type ShellResult struct { func (x *ShellResult) Reset() { *x = ShellResult{} - if protoimpl.UnsafeEnabled { - mi := &file_shell_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_shell_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ShellResult) String() string { @@ -285,7 +276,7 @@ func (*ShellResult) ProtoMessage() {} func (x *ShellResult) ProtoReflect() protoreflect.Message { mi := &file_shell_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -406,69 +397,6 @@ func file_shell_proto_init() { if File_shell_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_shell_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SendRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_shell_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*SendResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_shell_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeReceiveRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_shell_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*ReceiveResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_shell_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*ShellResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/shell/shell_grpc.pb.go b/Sources/shell/shell_grpc.pb.go index 1f88324..e86c4ea 100644 --- a/Sources/shell/shell_grpc.pb.go +++ b/Sources/shell/shell_grpc.pb.go @@ -8,6 +8,7 @@ package shell import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/telemetry/telemetry.go b/Sources/telemetry/telemetry.go index f6b7eea..5660803 100644 --- a/Sources/telemetry/telemetry.go +++ b/Sources/telemetry/telemetry.go @@ -2,11 +2,11 @@ package telemetry import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to 'position' updates. - - +Position Subscribe to 'position' updates. */ +func (a *ServiceImpl) Position( + ctx context.Context, -func (a *ServiceImpl) Position(ctx context.Context) (<-chan *Position, error) { +) (<-chan *Position, error) { ch := make(chan *Position) request := &SubscribePositionRequest{} stream, err := a.Client.SubscribePosition(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) Position(ctx context.Context) (<-chan *Position, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Position messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Position messages, err: %v", err) } ch <- m.GetPosition() } @@ -48,12 +47,12 @@ func (a *ServiceImpl) Position(ctx context.Context) (<-chan *Position, error) { } /* - Subscribe to 'home position' updates. - - +Home Subscribe to 'home position' updates. */ +func (a *ServiceImpl) Home( + ctx context.Context, -func (a *ServiceImpl) Home(ctx context.Context) (<-chan *Position, error) { +) (<-chan *Position, error) { ch := make(chan *Position) request := &SubscribeHomeRequest{} stream, err := a.Client.SubscribeHome(ctx, request) @@ -72,8 +71,7 @@ func (a *ServiceImpl) Home(ctx context.Context) (<-chan *Position, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Home messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Home messages, err: %v", err) } ch <- m.GetHome() } @@ -82,12 +80,12 @@ func (a *ServiceImpl) Home(ctx context.Context) (<-chan *Position, error) { } /* - Subscribe to in-air updates. - - +InAir Subscribe to in-air updates. */ +func (a *ServiceImpl) InAir( + ctx context.Context, -func (a *ServiceImpl) InAir(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeInAirRequest{} stream, err := a.Client.SubscribeInAir(ctx, request) @@ -106,8 +104,7 @@ func (a *ServiceImpl) InAir(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive InAir messages, err: %v\n", err) - break + log.Fatalf("Unable to receive InAir messages, err: %v", err) } ch <- m.GetIsInAir() } @@ -116,12 +113,12 @@ func (a *ServiceImpl) InAir(ctx context.Context) (<-chan bool, error) { } /* - Subscribe to landed state updates - - +LandedState Subscribe to landed state updates */ +func (a *ServiceImpl) LandedState( + ctx context.Context, -func (a *ServiceImpl) LandedState(ctx context.Context) (<-chan LandedState, error) { +) (<-chan LandedState, error) { ch := make(chan LandedState) request := &SubscribeLandedStateRequest{} stream, err := a.Client.SubscribeLandedState(ctx, request) @@ -140,8 +137,7 @@ func (a *ServiceImpl) LandedState(ctx context.Context) (<-chan LandedState, erro if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive LandedState messages, err: %v\n", err) - break + log.Fatalf("Unable to receive LandedState messages, err: %v", err) } ch <- m.GetLandedState() } @@ -150,12 +146,12 @@ func (a *ServiceImpl) LandedState(ctx context.Context) (<-chan LandedState, erro } /* - Subscribe to armed updates. - - +Armed Subscribe to armed updates. */ +func (a *ServiceImpl) Armed( + ctx context.Context, -func (a *ServiceImpl) Armed(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeArmedRequest{} stream, err := a.Client.SubscribeArmed(ctx, request) @@ -174,8 +170,7 @@ func (a *ServiceImpl) Armed(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Armed messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Armed messages, err: %v", err) } ch <- m.GetIsArmed() } @@ -184,12 +179,12 @@ func (a *ServiceImpl) Armed(ctx context.Context) (<-chan bool, error) { } /* - subscribe to vtol state Updates - - +VtolState subscribe to vtol state Updates */ +func (a *ServiceImpl) VtolState( + ctx context.Context, -func (a *ServiceImpl) VtolState(ctx context.Context) (<-chan VtolState, error) { +) (<-chan VtolState, error) { ch := make(chan VtolState) request := &SubscribeVtolStateRequest{} stream, err := a.Client.SubscribeVtolState(ctx, request) @@ -208,8 +203,7 @@ func (a *ServiceImpl) VtolState(ctx context.Context) (<-chan VtolState, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive VtolState messages, err: %v\n", err) - break + log.Fatalf("Unable to receive VtolState messages, err: %v", err) } ch <- m.GetVtolState() } @@ -218,12 +212,12 @@ func (a *ServiceImpl) VtolState(ctx context.Context) (<-chan VtolState, error) { } /* - Subscribe to 'attitude' updates (quaternion). - - +AttitudeQuaternion Subscribe to 'attitude' updates (quaternion). */ +func (a *ServiceImpl) AttitudeQuaternion( + ctx context.Context, -func (a *ServiceImpl) AttitudeQuaternion(ctx context.Context) (<-chan *Quaternion, error) { +) (<-chan *Quaternion, error) { ch := make(chan *Quaternion) request := &SubscribeAttitudeQuaternionRequest{} stream, err := a.Client.SubscribeAttitudeQuaternion(ctx, request) @@ -242,8 +236,7 @@ func (a *ServiceImpl) AttitudeQuaternion(ctx context.Context) (<-chan *Quaternio if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive AttitudeQuaternion messages, err: %v\n", err) - break + log.Fatalf("Unable to receive AttitudeQuaternion messages, err: %v", err) } ch <- m.GetAttitudeQuaternion() } @@ -252,12 +245,12 @@ func (a *ServiceImpl) AttitudeQuaternion(ctx context.Context) (<-chan *Quaternio } /* - Subscribe to 'attitude' updates (Euler). - - +AttitudeEuler Subscribe to 'attitude' updates (Euler). */ +func (a *ServiceImpl) AttitudeEuler( + ctx context.Context, -func (a *ServiceImpl) AttitudeEuler(ctx context.Context) (<-chan *EulerAngle, error) { +) (<-chan *EulerAngle, error) { ch := make(chan *EulerAngle) request := &SubscribeAttitudeEulerRequest{} stream, err := a.Client.SubscribeAttitudeEuler(ctx, request) @@ -276,8 +269,7 @@ func (a *ServiceImpl) AttitudeEuler(ctx context.Context) (<-chan *EulerAngle, er if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive AttitudeEuler messages, err: %v\n", err) - break + log.Fatalf("Unable to receive AttitudeEuler messages, err: %v", err) } ch <- m.GetAttitudeEuler() } @@ -286,12 +278,12 @@ func (a *ServiceImpl) AttitudeEuler(ctx context.Context) (<-chan *EulerAngle, er } /* - Subscribe to 'attitude' updates (angular velocity) - - +AttitudeAngularVelocityBody Subscribe to 'attitude' updates (angular velocity) */ +func (a *ServiceImpl) AttitudeAngularVelocityBody( + ctx context.Context, -func (a *ServiceImpl) AttitudeAngularVelocityBody(ctx context.Context) (<-chan *AngularVelocityBody, error) { +) (<-chan *AngularVelocityBody, error) { ch := make(chan *AngularVelocityBody) request := &SubscribeAttitudeAngularVelocityBodyRequest{} stream, err := a.Client.SubscribeAttitudeAngularVelocityBody(ctx, request) @@ -310,8 +302,7 @@ func (a *ServiceImpl) AttitudeAngularVelocityBody(ctx context.Context) (<-chan * if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive AttitudeAngularVelocityBody messages, err: %v\n", err) - break + log.Fatalf("Unable to receive AttitudeAngularVelocityBody messages, err: %v", err) } ch <- m.GetAttitudeAngularVelocityBody() } @@ -320,12 +311,12 @@ func (a *ServiceImpl) AttitudeAngularVelocityBody(ctx context.Context) (<-chan * } /* - Subscribe to 'camera attitude' updates (quaternion). - - +CameraAttitudeQuaternion Subscribe to 'camera attitude' updates (quaternion). */ +func (a *ServiceImpl) CameraAttitudeQuaternion( + ctx context.Context, -func (a *ServiceImpl) CameraAttitudeQuaternion(ctx context.Context) (<-chan *Quaternion, error) { +) (<-chan *Quaternion, error) { ch := make(chan *Quaternion) request := &SubscribeCameraAttitudeQuaternionRequest{} stream, err := a.Client.SubscribeCameraAttitudeQuaternion(ctx, request) @@ -344,8 +335,7 @@ func (a *ServiceImpl) CameraAttitudeQuaternion(ctx context.Context) (<-chan *Qua if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CameraAttitudeQuaternion messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CameraAttitudeQuaternion messages, err: %v", err) } ch <- m.GetAttitudeQuaternion() } @@ -354,12 +344,12 @@ func (a *ServiceImpl) CameraAttitudeQuaternion(ctx context.Context) (<-chan *Qua } /* - Subscribe to 'camera attitude' updates (Euler). - - +CameraAttitudeEuler Subscribe to 'camera attitude' updates (Euler). */ +func (a *ServiceImpl) CameraAttitudeEuler( + ctx context.Context, -func (a *ServiceImpl) CameraAttitudeEuler(ctx context.Context) (<-chan *EulerAngle, error) { +) (<-chan *EulerAngle, error) { ch := make(chan *EulerAngle) request := &SubscribeCameraAttitudeEulerRequest{} stream, err := a.Client.SubscribeCameraAttitudeEuler(ctx, request) @@ -378,8 +368,7 @@ func (a *ServiceImpl) CameraAttitudeEuler(ctx context.Context) (<-chan *EulerAng if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive CameraAttitudeEuler messages, err: %v\n", err) - break + log.Fatalf("Unable to receive CameraAttitudeEuler messages, err: %v", err) } ch <- m.GetAttitudeEuler() } @@ -388,12 +377,12 @@ func (a *ServiceImpl) CameraAttitudeEuler(ctx context.Context) (<-chan *EulerAng } /* - Subscribe to 'ground speed' updates (NED). - - +VelocityNed Subscribe to 'ground speed' updates (NED). */ +func (a *ServiceImpl) VelocityNed( + ctx context.Context, -func (a *ServiceImpl) VelocityNed(ctx context.Context) (<-chan *VelocityNed, error) { +) (<-chan *VelocityNed, error) { ch := make(chan *VelocityNed) request := &SubscribeVelocityNedRequest{} stream, err := a.Client.SubscribeVelocityNed(ctx, request) @@ -412,8 +401,7 @@ func (a *ServiceImpl) VelocityNed(ctx context.Context) (<-chan *VelocityNed, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive VelocityNed messages, err: %v\n", err) - break + log.Fatalf("Unable to receive VelocityNed messages, err: %v", err) } ch <- m.GetVelocityNed() } @@ -422,12 +410,12 @@ func (a *ServiceImpl) VelocityNed(ctx context.Context) (<-chan *VelocityNed, err } /* - Subscribe to 'GPS info' updates. - - +GpsInfo Subscribe to 'GPS info' updates. */ +func (a *ServiceImpl) GpsInfo( + ctx context.Context, -func (a *ServiceImpl) GpsInfo(ctx context.Context) (<-chan *GpsInfo, error) { +) (<-chan *GpsInfo, error) { ch := make(chan *GpsInfo) request := &SubscribeGpsInfoRequest{} stream, err := a.Client.SubscribeGpsInfo(ctx, request) @@ -446,8 +434,7 @@ func (a *ServiceImpl) GpsInfo(ctx context.Context) (<-chan *GpsInfo, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive GpsInfo messages, err: %v\n", err) - break + log.Fatalf("Unable to receive GpsInfo messages, err: %v", err) } ch <- m.GetGpsInfo() } @@ -456,12 +443,12 @@ func (a *ServiceImpl) GpsInfo(ctx context.Context) (<-chan *GpsInfo, error) { } /* - Subscribe to 'Raw GPS' updates. - - +RawGps Subscribe to 'Raw GPS' updates. */ +func (a *ServiceImpl) RawGps( + ctx context.Context, -func (a *ServiceImpl) RawGps(ctx context.Context) (<-chan *RawGps, error) { +) (<-chan *RawGps, error) { ch := make(chan *RawGps) request := &SubscribeRawGpsRequest{} stream, err := a.Client.SubscribeRawGps(ctx, request) @@ -480,8 +467,7 @@ func (a *ServiceImpl) RawGps(ctx context.Context) (<-chan *RawGps, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive RawGps messages, err: %v\n", err) - break + log.Fatalf("Unable to receive RawGps messages, err: %v", err) } ch <- m.GetRawGps() } @@ -490,12 +476,12 @@ func (a *ServiceImpl) RawGps(ctx context.Context) (<-chan *RawGps, error) { } /* - Subscribe to 'battery' updates. - - +Battery Subscribe to 'battery' updates. */ +func (a *ServiceImpl) Battery( + ctx context.Context, -func (a *ServiceImpl) Battery(ctx context.Context) (<-chan *Battery, error) { +) (<-chan *Battery, error) { ch := make(chan *Battery) request := &SubscribeBatteryRequest{} stream, err := a.Client.SubscribeBattery(ctx, request) @@ -514,8 +500,7 @@ func (a *ServiceImpl) Battery(ctx context.Context) (<-chan *Battery, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Battery messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Battery messages, err: %v", err) } ch <- m.GetBattery() } @@ -524,12 +509,12 @@ func (a *ServiceImpl) Battery(ctx context.Context) (<-chan *Battery, error) { } /* - Subscribe to 'flight mode' updates. - - +FlightMode Subscribe to 'flight mode' updates. */ +func (a *ServiceImpl) FlightMode( + ctx context.Context, -func (a *ServiceImpl) FlightMode(ctx context.Context) (<-chan FlightMode, error) { +) (<-chan FlightMode, error) { ch := make(chan FlightMode) request := &SubscribeFlightModeRequest{} stream, err := a.Client.SubscribeFlightMode(ctx, request) @@ -548,8 +533,7 @@ func (a *ServiceImpl) FlightMode(ctx context.Context) (<-chan FlightMode, error) if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive FlightMode messages, err: %v\n", err) - break + log.Fatalf("Unable to receive FlightMode messages, err: %v", err) } ch <- m.GetFlightMode() } @@ -558,12 +542,12 @@ func (a *ServiceImpl) FlightMode(ctx context.Context) (<-chan FlightMode, error) } /* - Subscribe to 'health' updates. - - +Health Subscribe to 'health' updates. */ +func (a *ServiceImpl) Health( + ctx context.Context, -func (a *ServiceImpl) Health(ctx context.Context) (<-chan *Health, error) { +) (<-chan *Health, error) { ch := make(chan *Health) request := &SubscribeHealthRequest{} stream, err := a.Client.SubscribeHealth(ctx, request) @@ -582,8 +566,7 @@ func (a *ServiceImpl) Health(ctx context.Context) (<-chan *Health, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Health messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Health messages, err: %v", err) } ch <- m.GetHealth() } @@ -592,12 +575,12 @@ func (a *ServiceImpl) Health(ctx context.Context) (<-chan *Health, error) { } /* - Subscribe to 'RC status' updates. - - +RcStatus Subscribe to 'RC status' updates. */ +func (a *ServiceImpl) RcStatus( + ctx context.Context, -func (a *ServiceImpl) RcStatus(ctx context.Context) (<-chan *RcStatus, error) { +) (<-chan *RcStatus, error) { ch := make(chan *RcStatus) request := &SubscribeRcStatusRequest{} stream, err := a.Client.SubscribeRcStatus(ctx, request) @@ -616,8 +599,7 @@ func (a *ServiceImpl) RcStatus(ctx context.Context) (<-chan *RcStatus, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive RcStatus messages, err: %v\n", err) - break + log.Fatalf("Unable to receive RcStatus messages, err: %v", err) } ch <- m.GetRcStatus() } @@ -626,12 +608,12 @@ func (a *ServiceImpl) RcStatus(ctx context.Context) (<-chan *RcStatus, error) { } /* - Subscribe to 'status text' updates. - - +StatusText Subscribe to 'status text' updates. */ +func (a *ServiceImpl) StatusText( + ctx context.Context, -func (a *ServiceImpl) StatusText(ctx context.Context) (<-chan *StatusText, error) { +) (<-chan *StatusText, error) { ch := make(chan *StatusText) request := &SubscribeStatusTextRequest{} stream, err := a.Client.SubscribeStatusText(ctx, request) @@ -650,8 +632,7 @@ func (a *ServiceImpl) StatusText(ctx context.Context) (<-chan *StatusText, error if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive StatusText messages, err: %v\n", err) - break + log.Fatalf("Unable to receive StatusText messages, err: %v", err) } ch <- m.GetStatusText() } @@ -660,12 +641,12 @@ func (a *ServiceImpl) StatusText(ctx context.Context) (<-chan *StatusText, error } /* - Subscribe to 'actuator control target' updates. - - +ActuatorControlTarget Subscribe to 'actuator control target' updates. */ +func (a *ServiceImpl) ActuatorControlTarget( + ctx context.Context, -func (a *ServiceImpl) ActuatorControlTarget(ctx context.Context) (<-chan *ActuatorControlTarget, error) { +) (<-chan *ActuatorControlTarget, error) { ch := make(chan *ActuatorControlTarget) request := &SubscribeActuatorControlTargetRequest{} stream, err := a.Client.SubscribeActuatorControlTarget(ctx, request) @@ -684,8 +665,7 @@ func (a *ServiceImpl) ActuatorControlTarget(ctx context.Context) (<-chan *Actuat if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ActuatorControlTarget messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ActuatorControlTarget messages, err: %v", err) } ch <- m.GetActuatorControlTarget() } @@ -694,12 +674,12 @@ func (a *ServiceImpl) ActuatorControlTarget(ctx context.Context) (<-chan *Actuat } /* - Subscribe to 'actuator output status' updates. - - +ActuatorOutputStatus Subscribe to 'actuator output status' updates. */ +func (a *ServiceImpl) ActuatorOutputStatus( + ctx context.Context, -func (a *ServiceImpl) ActuatorOutputStatus(ctx context.Context) (<-chan *ActuatorOutputStatus, error) { +) (<-chan *ActuatorOutputStatus, error) { ch := make(chan *ActuatorOutputStatus) request := &SubscribeActuatorOutputStatusRequest{} stream, err := a.Client.SubscribeActuatorOutputStatus(ctx, request) @@ -718,8 +698,7 @@ func (a *ServiceImpl) ActuatorOutputStatus(ctx context.Context) (<-chan *Actuato if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ActuatorOutputStatus messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ActuatorOutputStatus messages, err: %v", err) } ch <- m.GetActuatorOutputStatus() } @@ -728,12 +707,12 @@ func (a *ServiceImpl) ActuatorOutputStatus(ctx context.Context) (<-chan *Actuato } /* - Subscribe to 'odometry' updates. - - +Odometry Subscribe to 'odometry' updates. */ +func (a *ServiceImpl) Odometry( + ctx context.Context, -func (a *ServiceImpl) Odometry(ctx context.Context) (<-chan *Odometry, error) { +) (<-chan *Odometry, error) { ch := make(chan *Odometry) request := &SubscribeOdometryRequest{} stream, err := a.Client.SubscribeOdometry(ctx, request) @@ -752,8 +731,7 @@ func (a *ServiceImpl) Odometry(ctx context.Context) (<-chan *Odometry, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Odometry messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Odometry messages, err: %v", err) } ch <- m.GetOdometry() } @@ -762,12 +740,12 @@ func (a *ServiceImpl) Odometry(ctx context.Context) (<-chan *Odometry, error) { } /* - Subscribe to 'position velocity' updates. - - +PositionVelocityNed Subscribe to 'position velocity' updates. */ +func (a *ServiceImpl) PositionVelocityNed( + ctx context.Context, -func (a *ServiceImpl) PositionVelocityNed(ctx context.Context) (<-chan *PositionVelocityNed, error) { +) (<-chan *PositionVelocityNed, error) { ch := make(chan *PositionVelocityNed) request := &SubscribePositionVelocityNedRequest{} stream, err := a.Client.SubscribePositionVelocityNed(ctx, request) @@ -786,8 +764,7 @@ func (a *ServiceImpl) PositionVelocityNed(ctx context.Context) (<-chan *Position if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive PositionVelocityNed messages, err: %v\n", err) - break + log.Fatalf("Unable to receive PositionVelocityNed messages, err: %v", err) } ch <- m.GetPositionVelocityNed() } @@ -796,12 +773,12 @@ func (a *ServiceImpl) PositionVelocityNed(ctx context.Context) (<-chan *Position } /* - Subscribe to 'ground truth' updates. - - +GroundTruth Subscribe to 'ground truth' updates. */ +func (a *ServiceImpl) GroundTruth( + ctx context.Context, -func (a *ServiceImpl) GroundTruth(ctx context.Context) (<-chan *GroundTruth, error) { +) (<-chan *GroundTruth, error) { ch := make(chan *GroundTruth) request := &SubscribeGroundTruthRequest{} stream, err := a.Client.SubscribeGroundTruth(ctx, request) @@ -820,8 +797,7 @@ func (a *ServiceImpl) GroundTruth(ctx context.Context) (<-chan *GroundTruth, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive GroundTruth messages, err: %v\n", err) - break + log.Fatalf("Unable to receive GroundTruth messages, err: %v", err) } ch <- m.GetGroundTruth() } @@ -830,12 +806,12 @@ func (a *ServiceImpl) GroundTruth(ctx context.Context) (<-chan *GroundTruth, err } /* - Subscribe to 'fixedwing metrics' updates. - - +FixedwingMetrics Subscribe to 'fixedwing metrics' updates. */ +func (a *ServiceImpl) FixedwingMetrics( + ctx context.Context, -func (a *ServiceImpl) FixedwingMetrics(ctx context.Context) (<-chan *FixedwingMetrics, error) { +) (<-chan *FixedwingMetrics, error) { ch := make(chan *FixedwingMetrics) request := &SubscribeFixedwingMetricsRequest{} stream, err := a.Client.SubscribeFixedwingMetrics(ctx, request) @@ -854,8 +830,7 @@ func (a *ServiceImpl) FixedwingMetrics(ctx context.Context) (<-chan *FixedwingMe if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive FixedwingMetrics messages, err: %v\n", err) - break + log.Fatalf("Unable to receive FixedwingMetrics messages, err: %v", err) } ch <- m.GetFixedwingMetrics() } @@ -864,12 +839,12 @@ func (a *ServiceImpl) FixedwingMetrics(ctx context.Context) (<-chan *FixedwingMe } /* - Subscribe to 'IMU' updates (in SI units in NED body frame). - - +Imu Subscribe to 'IMU' updates (in SI units in NED body frame). */ +func (a *ServiceImpl) Imu( + ctx context.Context, -func (a *ServiceImpl) Imu(ctx context.Context) (<-chan *Imu, error) { +) (<-chan *Imu, error) { ch := make(chan *Imu) request := &SubscribeImuRequest{} stream, err := a.Client.SubscribeImu(ctx, request) @@ -888,8 +863,7 @@ func (a *ServiceImpl) Imu(ctx context.Context) (<-chan *Imu, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Imu messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Imu messages, err: %v", err) } ch <- m.GetImu() } @@ -898,12 +872,12 @@ func (a *ServiceImpl) Imu(ctx context.Context) (<-chan *Imu, error) { } /* - Subscribe to 'Scaled IMU' updates. - - +ScaledImu Subscribe to 'Scaled IMU' updates. */ +func (a *ServiceImpl) ScaledImu( + ctx context.Context, -func (a *ServiceImpl) ScaledImu(ctx context.Context) (<-chan *Imu, error) { +) (<-chan *Imu, error) { ch := make(chan *Imu) request := &SubscribeScaledImuRequest{} stream, err := a.Client.SubscribeScaledImu(ctx, request) @@ -922,8 +896,7 @@ func (a *ServiceImpl) ScaledImu(ctx context.Context) (<-chan *Imu, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ScaledImu messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ScaledImu messages, err: %v", err) } ch <- m.GetImu() } @@ -932,12 +905,12 @@ func (a *ServiceImpl) ScaledImu(ctx context.Context) (<-chan *Imu, error) { } /* - Subscribe to 'Raw IMU' updates. - - +RawImu Subscribe to 'Raw IMU' updates. */ +func (a *ServiceImpl) RawImu( + ctx context.Context, -func (a *ServiceImpl) RawImu(ctx context.Context) (<-chan *Imu, error) { +) (<-chan *Imu, error) { ch := make(chan *Imu) request := &SubscribeRawImuRequest{} stream, err := a.Client.SubscribeRawImu(ctx, request) @@ -956,8 +929,7 @@ func (a *ServiceImpl) RawImu(ctx context.Context) (<-chan *Imu, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive RawImu messages, err: %v\n", err) - break + log.Fatalf("Unable to receive RawImu messages, err: %v", err) } ch <- m.GetImu() } @@ -966,12 +938,12 @@ func (a *ServiceImpl) RawImu(ctx context.Context) (<-chan *Imu, error) { } /* - Subscribe to 'HealthAllOk' updates. - - +HealthAllOk Subscribe to 'HealthAllOk' updates. */ +func (a *ServiceImpl) HealthAllOk( + ctx context.Context, -func (a *ServiceImpl) HealthAllOk(ctx context.Context) (<-chan bool, error) { +) (<-chan bool, error) { ch := make(chan bool) request := &SubscribeHealthAllOkRequest{} stream, err := a.Client.SubscribeHealthAllOk(ctx, request) @@ -990,8 +962,7 @@ func (a *ServiceImpl) HealthAllOk(ctx context.Context) (<-chan bool, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive HealthAllOk messages, err: %v\n", err) - break + log.Fatalf("Unable to receive HealthAllOk messages, err: %v", err) } ch <- m.GetIsHealthAllOk() } @@ -1000,12 +971,12 @@ func (a *ServiceImpl) HealthAllOk(ctx context.Context) (<-chan bool, error) { } /* - Subscribe to 'unix epoch time' updates. - - +UnixEpochTime Subscribe to 'unix epoch time' updates. */ +func (a *ServiceImpl) UnixEpochTime( + ctx context.Context, -func (a *ServiceImpl) UnixEpochTime(ctx context.Context) (<-chan uint64, error) { +) (<-chan uint64, error) { ch := make(chan uint64) request := &SubscribeUnixEpochTimeRequest{} stream, err := a.Client.SubscribeUnixEpochTime(ctx, request) @@ -1024,8 +995,7 @@ func (a *ServiceImpl) UnixEpochTime(ctx context.Context) (<-chan uint64, error) if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive UnixEpochTime messages, err: %v\n", err) - break + log.Fatalf("Unable to receive UnixEpochTime messages, err: %v", err) } ch <- m.GetTimeUs() } @@ -1034,12 +1004,12 @@ func (a *ServiceImpl) UnixEpochTime(ctx context.Context) (<-chan uint64, error) } /* - Subscribe to 'Distance Sensor' updates. - - +DistanceSensor Subscribe to 'Distance Sensor' updates. */ +func (a *ServiceImpl) DistanceSensor( + ctx context.Context, -func (a *ServiceImpl) DistanceSensor(ctx context.Context) (<-chan *DistanceSensor, error) { +) (<-chan *DistanceSensor, error) { ch := make(chan *DistanceSensor) request := &SubscribeDistanceSensorRequest{} stream, err := a.Client.SubscribeDistanceSensor(ctx, request) @@ -1058,8 +1028,7 @@ func (a *ServiceImpl) DistanceSensor(ctx context.Context) (<-chan *DistanceSenso if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive DistanceSensor messages, err: %v\n", err) - break + log.Fatalf("Unable to receive DistanceSensor messages, err: %v", err) } ch <- m.GetDistanceSensor() } @@ -1068,12 +1037,12 @@ func (a *ServiceImpl) DistanceSensor(ctx context.Context) (<-chan *DistanceSenso } /* - Subscribe to 'Scaled Pressure' updates. - - +ScaledPressure Subscribe to 'Scaled Pressure' updates. */ +func (a *ServiceImpl) ScaledPressure( + ctx context.Context, -func (a *ServiceImpl) ScaledPressure(ctx context.Context) (<-chan *ScaledPressure, error) { +) (<-chan *ScaledPressure, error) { ch := make(chan *ScaledPressure) request := &SubscribeScaledPressureRequest{} stream, err := a.Client.SubscribeScaledPressure(ctx, request) @@ -1092,8 +1061,7 @@ func (a *ServiceImpl) ScaledPressure(ctx context.Context) (<-chan *ScaledPressur if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive ScaledPressure messages, err: %v\n", err) - break + log.Fatalf("Unable to receive ScaledPressure messages, err: %v", err) } ch <- m.GetScaledPressure() } @@ -1102,12 +1070,12 @@ func (a *ServiceImpl) ScaledPressure(ctx context.Context) (<-chan *ScaledPressur } /* - Subscribe to 'Heading' updates. - - +Heading Subscribe to 'Heading' updates. */ +func (a *ServiceImpl) Heading( + ctx context.Context, -func (a *ServiceImpl) Heading(ctx context.Context) (<-chan *Heading, error) { +) (<-chan *Heading, error) { ch := make(chan *Heading) request := &SubscribeHeadingRequest{} stream, err := a.Client.SubscribeHeading(ctx, request) @@ -1126,8 +1094,7 @@ func (a *ServiceImpl) Heading(ctx context.Context) (<-chan *Heading, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Heading messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Heading messages, err: %v", err) } ch <- m.GetHeadingDeg() } @@ -1136,12 +1103,12 @@ func (a *ServiceImpl) Heading(ctx context.Context) (<-chan *Heading, error) { } /* - Subscribe to 'Altitude' updates. - - +Altitude Subscribe to 'Altitude' updates. */ +func (a *ServiceImpl) Altitude( + ctx context.Context, -func (a *ServiceImpl) Altitude(ctx context.Context) (<-chan *Altitude, error) { +) (<-chan *Altitude, error) { ch := make(chan *Altitude) request := &SubscribeAltitudeRequest{} stream, err := a.Client.SubscribeAltitude(ctx, request) @@ -1160,8 +1127,7 @@ func (a *ServiceImpl) Altitude(ctx context.Context) (<-chan *Altitude, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Altitude messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Altitude messages, err: %v", err) } ch <- m.GetAltitude() } @@ -1170,19 +1136,16 @@ func (a *ServiceImpl) Altitude(ctx context.Context) (<-chan *Altitude, error) { } /* - Set rate to 'position' updates. - - Parameters - ---------- - rateHz float64 - - +SetRatePosition Set rate to 'position' updates. */ +func (s *ServiceImpl) SetRatePosition( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRatePosition(ctx context.Context, rateHz float64) (*SetRatePositionResponse, error) { - - request := &SetRatePositionRequest{} - request.RateHz = rateHz +) (*SetRatePositionResponse, error) { + request := &SetRatePositionRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRatePosition(ctx, request) if err != nil { return nil, err @@ -1191,19 +1154,16 @@ func (s *ServiceImpl) SetRatePosition(ctx context.Context, rateHz float64) (*Set } /* - Set rate to 'home position' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateHome Set rate to 'home position' updates. */ +func (s *ServiceImpl) SetRateHome( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateHome(ctx context.Context, rateHz float64) (*SetRateHomeResponse, error) { - - request := &SetRateHomeRequest{} - request.RateHz = rateHz +) (*SetRateHomeResponse, error) { + request := &SetRateHomeRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateHome(ctx, request) if err != nil { return nil, err @@ -1212,19 +1172,16 @@ func (s *ServiceImpl) SetRateHome(ctx context.Context, rateHz float64) (*SetRate } /* - Set rate to in-air updates. - - Parameters - ---------- - rateHz float64 - - +SetRateInAir Set rate to in-air updates. */ +func (s *ServiceImpl) SetRateInAir( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateInAir(ctx context.Context, rateHz float64) (*SetRateInAirResponse, error) { - - request := &SetRateInAirRequest{} - request.RateHz = rateHz +) (*SetRateInAirResponse, error) { + request := &SetRateInAirRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateInAir(ctx, request) if err != nil { return nil, err @@ -1233,19 +1190,16 @@ func (s *ServiceImpl) SetRateInAir(ctx context.Context, rateHz float64) (*SetRat } /* - Set rate to landed state updates - - Parameters - ---------- - rateHz float64 - - +SetRateLandedState Set rate to landed state updates */ +func (s *ServiceImpl) SetRateLandedState( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateLandedState(ctx context.Context, rateHz float64) (*SetRateLandedStateResponse, error) { - - request := &SetRateLandedStateRequest{} - request.RateHz = rateHz +) (*SetRateLandedStateResponse, error) { + request := &SetRateLandedStateRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateLandedState(ctx, request) if err != nil { return nil, err @@ -1254,19 +1208,16 @@ func (s *ServiceImpl) SetRateLandedState(ctx context.Context, rateHz float64) (* } /* - Set rate to VTOL state updates - - Parameters - ---------- - rateHz float64 - - +SetRateVtolState Set rate to VTOL state updates */ +func (s *ServiceImpl) SetRateVtolState( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateVtolState(ctx context.Context, rateHz float64) (*SetRateVtolStateResponse, error) { - - request := &SetRateVtolStateRequest{} - request.RateHz = rateHz +) (*SetRateVtolStateResponse, error) { + request := &SetRateVtolStateRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateVtolState(ctx, request) if err != nil { return nil, err @@ -1275,19 +1226,16 @@ func (s *ServiceImpl) SetRateVtolState(ctx context.Context, rateHz float64) (*Se } /* - Set rate to 'attitude euler angle' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateAttitudeQuaternion Set rate to 'attitude euler angle' updates. */ +func (s *ServiceImpl) SetRateAttitudeQuaternion( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateAttitudeQuaternion(ctx context.Context, rateHz float64) (*SetRateAttitudeQuaternionResponse, error) { - - request := &SetRateAttitudeQuaternionRequest{} - request.RateHz = rateHz +) (*SetRateAttitudeQuaternionResponse, error) { + request := &SetRateAttitudeQuaternionRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateAttitudeQuaternion(ctx, request) if err != nil { return nil, err @@ -1296,19 +1244,16 @@ func (s *ServiceImpl) SetRateAttitudeQuaternion(ctx context.Context, rateHz floa } /* - Set rate to 'attitude quaternion' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateAttitudeEuler Set rate to 'attitude quaternion' updates. */ +func (s *ServiceImpl) SetRateAttitudeEuler( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateAttitudeEuler(ctx context.Context, rateHz float64) (*SetRateAttitudeEulerResponse, error) { - - request := &SetRateAttitudeEulerRequest{} - request.RateHz = rateHz +) (*SetRateAttitudeEulerResponse, error) { + request := &SetRateAttitudeEulerRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateAttitudeEuler(ctx, request) if err != nil { return nil, err @@ -1317,19 +1262,16 @@ func (s *ServiceImpl) SetRateAttitudeEuler(ctx context.Context, rateHz float64) } /* - Set rate of camera attitude updates. - - Parameters - ---------- - rateHz float64 - - +SetRateCameraAttitude Set rate of camera attitude updates. */ +func (s *ServiceImpl) SetRateCameraAttitude( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateCameraAttitude(ctx context.Context, rateHz float64) (*SetRateCameraAttitudeResponse, error) { - - request := &SetRateCameraAttitudeRequest{} - request.RateHz = rateHz +) (*SetRateCameraAttitudeResponse, error) { + request := &SetRateCameraAttitudeRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateCameraAttitude(ctx, request) if err != nil { return nil, err @@ -1338,19 +1280,16 @@ func (s *ServiceImpl) SetRateCameraAttitude(ctx context.Context, rateHz float64) } /* - Set rate to 'ground speed' updates (NED). - - Parameters - ---------- - rateHz float64 - - +SetRateVelocityNed Set rate to 'ground speed' updates (NED). */ +func (s *ServiceImpl) SetRateVelocityNed( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateVelocityNed(ctx context.Context, rateHz float64) (*SetRateVelocityNedResponse, error) { - - request := &SetRateVelocityNedRequest{} - request.RateHz = rateHz +) (*SetRateVelocityNedResponse, error) { + request := &SetRateVelocityNedRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateVelocityNed(ctx, request) if err != nil { return nil, err @@ -1359,19 +1298,16 @@ func (s *ServiceImpl) SetRateVelocityNed(ctx context.Context, rateHz float64) (* } /* - Set rate to 'GPS info' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateGpsInfo Set rate to 'GPS info' updates. */ +func (s *ServiceImpl) SetRateGpsInfo( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateGpsInfo(ctx context.Context, rateHz float64) (*SetRateGpsInfoResponse, error) { - - request := &SetRateGpsInfoRequest{} - request.RateHz = rateHz +) (*SetRateGpsInfoResponse, error) { + request := &SetRateGpsInfoRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateGpsInfo(ctx, request) if err != nil { return nil, err @@ -1380,19 +1316,16 @@ func (s *ServiceImpl) SetRateGpsInfo(ctx context.Context, rateHz float64) (*SetR } /* - Set rate to 'battery' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateBattery Set rate to 'battery' updates. */ +func (s *ServiceImpl) SetRateBattery( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateBattery(ctx context.Context, rateHz float64) (*SetRateBatteryResponse, error) { - - request := &SetRateBatteryRequest{} - request.RateHz = rateHz +) (*SetRateBatteryResponse, error) { + request := &SetRateBatteryRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateBattery(ctx, request) if err != nil { return nil, err @@ -1401,19 +1334,16 @@ func (s *ServiceImpl) SetRateBattery(ctx context.Context, rateHz float64) (*SetR } /* - Set rate to 'RC status' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateRcStatus Set rate to 'RC status' updates. */ +func (s *ServiceImpl) SetRateRcStatus( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateRcStatus(ctx context.Context, rateHz float64) (*SetRateRcStatusResponse, error) { - - request := &SetRateRcStatusRequest{} - request.RateHz = rateHz +) (*SetRateRcStatusResponse, error) { + request := &SetRateRcStatusRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateRcStatus(ctx, request) if err != nil { return nil, err @@ -1422,19 +1352,16 @@ func (s *ServiceImpl) SetRateRcStatus(ctx context.Context, rateHz float64) (*Set } /* - Set rate to 'actuator control target' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateActuatorControlTarget Set rate to 'actuator control target' updates. */ +func (s *ServiceImpl) SetRateActuatorControlTarget( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateActuatorControlTarget(ctx context.Context, rateHz float64) (*SetRateActuatorControlTargetResponse, error) { - - request := &SetRateActuatorControlTargetRequest{} - request.RateHz = rateHz +) (*SetRateActuatorControlTargetResponse, error) { + request := &SetRateActuatorControlTargetRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateActuatorControlTarget(ctx, request) if err != nil { return nil, err @@ -1443,19 +1370,16 @@ func (s *ServiceImpl) SetRateActuatorControlTarget(ctx context.Context, rateHz f } /* - Set rate to 'actuator output status' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateActuatorOutputStatus Set rate to 'actuator output status' updates. */ +func (s *ServiceImpl) SetRateActuatorOutputStatus( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateActuatorOutputStatus(ctx context.Context, rateHz float64) (*SetRateActuatorOutputStatusResponse, error) { - - request := &SetRateActuatorOutputStatusRequest{} - request.RateHz = rateHz +) (*SetRateActuatorOutputStatusResponse, error) { + request := &SetRateActuatorOutputStatusRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateActuatorOutputStatus(ctx, request) if err != nil { return nil, err @@ -1464,19 +1388,16 @@ func (s *ServiceImpl) SetRateActuatorOutputStatus(ctx context.Context, rateHz fl } /* - Set rate to 'odometry' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateOdometry Set rate to 'odometry' updates. */ +func (s *ServiceImpl) SetRateOdometry( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateOdometry(ctx context.Context, rateHz float64) (*SetRateOdometryResponse, error) { - - request := &SetRateOdometryRequest{} - request.RateHz = rateHz +) (*SetRateOdometryResponse, error) { + request := &SetRateOdometryRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateOdometry(ctx, request) if err != nil { return nil, err @@ -1485,19 +1406,16 @@ func (s *ServiceImpl) SetRateOdometry(ctx context.Context, rateHz float64) (*Set } /* - Set rate to 'position velocity' updates. - - Parameters - ---------- - rateHz float64 - - +SetRatePositionVelocityNed Set rate to 'position velocity' updates. */ +func (s *ServiceImpl) SetRatePositionVelocityNed( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRatePositionVelocityNed(ctx context.Context, rateHz float64) (*SetRatePositionVelocityNedResponse, error) { - - request := &SetRatePositionVelocityNedRequest{} - request.RateHz = rateHz +) (*SetRatePositionVelocityNedResponse, error) { + request := &SetRatePositionVelocityNedRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRatePositionVelocityNed(ctx, request) if err != nil { return nil, err @@ -1506,19 +1424,16 @@ func (s *ServiceImpl) SetRatePositionVelocityNed(ctx context.Context, rateHz flo } /* - Set rate to 'ground truth' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateGroundTruth Set rate to 'ground truth' updates. */ +func (s *ServiceImpl) SetRateGroundTruth( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateGroundTruth(ctx context.Context, rateHz float64) (*SetRateGroundTruthResponse, error) { - - request := &SetRateGroundTruthRequest{} - request.RateHz = rateHz +) (*SetRateGroundTruthResponse, error) { + request := &SetRateGroundTruthRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateGroundTruth(ctx, request) if err != nil { return nil, err @@ -1527,19 +1442,16 @@ func (s *ServiceImpl) SetRateGroundTruth(ctx context.Context, rateHz float64) (* } /* - Set rate to 'fixedwing metrics' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateFixedwingMetrics Set rate to 'fixedwing metrics' updates. */ +func (s *ServiceImpl) SetRateFixedwingMetrics( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateFixedwingMetrics(ctx context.Context, rateHz float64) (*SetRateFixedwingMetricsResponse, error) { - - request := &SetRateFixedwingMetricsRequest{} - request.RateHz = rateHz +) (*SetRateFixedwingMetricsResponse, error) { + request := &SetRateFixedwingMetricsRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateFixedwingMetrics(ctx, request) if err != nil { return nil, err @@ -1548,19 +1460,16 @@ func (s *ServiceImpl) SetRateFixedwingMetrics(ctx context.Context, rateHz float6 } /* - Set rate to 'IMU' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateImu Set rate to 'IMU' updates. */ +func (s *ServiceImpl) SetRateImu( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateImu(ctx context.Context, rateHz float64) (*SetRateImuResponse, error) { - - request := &SetRateImuRequest{} - request.RateHz = rateHz +) (*SetRateImuResponse, error) { + request := &SetRateImuRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateImu(ctx, request) if err != nil { return nil, err @@ -1569,19 +1478,16 @@ func (s *ServiceImpl) SetRateImu(ctx context.Context, rateHz float64) (*SetRateI } /* - Set rate to 'Scaled IMU' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateScaledImu Set rate to 'Scaled IMU' updates. */ +func (s *ServiceImpl) SetRateScaledImu( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateScaledImu(ctx context.Context, rateHz float64) (*SetRateScaledImuResponse, error) { - - request := &SetRateScaledImuRequest{} - request.RateHz = rateHz +) (*SetRateScaledImuResponse, error) { + request := &SetRateScaledImuRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateScaledImu(ctx, request) if err != nil { return nil, err @@ -1590,19 +1496,16 @@ func (s *ServiceImpl) SetRateScaledImu(ctx context.Context, rateHz float64) (*Se } /* - Set rate to 'Raw IMU' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateRawImu Set rate to 'Raw IMU' updates. */ +func (s *ServiceImpl) SetRateRawImu( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateRawImu(ctx context.Context, rateHz float64) (*SetRateRawImuResponse, error) { - - request := &SetRateRawImuRequest{} - request.RateHz = rateHz +) (*SetRateRawImuResponse, error) { + request := &SetRateRawImuRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateRawImu(ctx, request) if err != nil { return nil, err @@ -1611,19 +1514,16 @@ func (s *ServiceImpl) SetRateRawImu(ctx context.Context, rateHz float64) (*SetRa } /* - Set rate to 'unix epoch time' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateUnixEpochTime Set rate to 'unix epoch time' updates. */ +func (s *ServiceImpl) SetRateUnixEpochTime( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateUnixEpochTime(ctx context.Context, rateHz float64) (*SetRateUnixEpochTimeResponse, error) { - - request := &SetRateUnixEpochTimeRequest{} - request.RateHz = rateHz +) (*SetRateUnixEpochTimeResponse, error) { + request := &SetRateUnixEpochTimeRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateUnixEpochTime(ctx, request) if err != nil { return nil, err @@ -1632,19 +1532,16 @@ func (s *ServiceImpl) SetRateUnixEpochTime(ctx context.Context, rateHz float64) } /* - Set rate to 'Distance Sensor' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateDistanceSensor Set rate to 'Distance Sensor' updates. */ +func (s *ServiceImpl) SetRateDistanceSensor( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateDistanceSensor(ctx context.Context, rateHz float64) (*SetRateDistanceSensorResponse, error) { - - request := &SetRateDistanceSensorRequest{} - request.RateHz = rateHz +) (*SetRateDistanceSensorResponse, error) { + request := &SetRateDistanceSensorRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateDistanceSensor(ctx, request) if err != nil { return nil, err @@ -1653,19 +1550,16 @@ func (s *ServiceImpl) SetRateDistanceSensor(ctx context.Context, rateHz float64) } /* - Set rate to 'Altitude' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateAltitude Set rate to 'Altitude' updates. */ +func (s *ServiceImpl) SetRateAltitude( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateAltitude(ctx context.Context, rateHz float64) (*SetRateAltitudeResponse, error) { - - request := &SetRateAltitudeRequest{} - request.RateHz = rateHz +) (*SetRateAltitudeResponse, error) { + request := &SetRateAltitudeRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateAltitude(ctx, request) if err != nil { return nil, err @@ -1674,24 +1568,16 @@ func (s *ServiceImpl) SetRateAltitude(ctx context.Context, rateHz float64) (*Set } /* - Get the GPS location of where the estimator has been initialized. - - - - Returns - ------- - False - GpsGlobalOrigin : GpsGlobalOrigin - - +GetGpsGlobalOrigin Get the GPS location of where the estimator has been initialized. */ +func (s *ServiceImpl) GetGpsGlobalOrigin( + ctx context.Context, -func (s *ServiceImpl) GetGpsGlobalOrigin(ctx context.Context) (*GetGpsGlobalOriginResponse, error) { +) (*GetGpsGlobalOriginResponse, error) { request := &GetGpsGlobalOriginRequest{} response, err := s.Client.GetGpsGlobalOrigin(ctx, request) if err != nil { return nil, err } return response, nil - } diff --git a/Sources/telemetry/telemetry.pb.go b/Sources/telemetry/telemetry.pb.go index 506f728..610ca08 100644 --- a/Sources/telemetry/telemetry.pb.go +++ b/Sources/telemetry/telemetry.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: telemetry.proto package telemetry import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -474,11 +475,9 @@ type SubscribePositionRequest struct { func (x *SubscribePositionRequest) Reset() { *x = SubscribePositionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribePositionRequest) String() string { @@ -489,7 +488,7 @@ func (*SubscribePositionRequest) ProtoMessage() {} func (x *SubscribePositionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -514,11 +513,9 @@ type PositionResponse struct { func (x *PositionResponse) Reset() { *x = PositionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionResponse) String() string { @@ -529,7 +526,7 @@ func (*PositionResponse) ProtoMessage() {} func (x *PositionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -559,11 +556,9 @@ type SubscribeHomeRequest struct { func (x *SubscribeHomeRequest) Reset() { *x = SubscribeHomeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeHomeRequest) String() string { @@ -574,7 +569,7 @@ func (*SubscribeHomeRequest) ProtoMessage() {} func (x *SubscribeHomeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -599,11 +594,9 @@ type HomeResponse struct { func (x *HomeResponse) Reset() { *x = HomeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HomeResponse) String() string { @@ -614,7 +607,7 @@ func (*HomeResponse) ProtoMessage() {} func (x *HomeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -644,11 +637,9 @@ type SubscribeInAirRequest struct { func (x *SubscribeInAirRequest) Reset() { *x = SubscribeInAirRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeInAirRequest) String() string { @@ -659,7 +650,7 @@ func (*SubscribeInAirRequest) ProtoMessage() {} func (x *SubscribeInAirRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -684,11 +675,9 @@ type InAirResponse struct { func (x *InAirResponse) Reset() { *x = InAirResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *InAirResponse) String() string { @@ -699,7 +688,7 @@ func (*InAirResponse) ProtoMessage() {} func (x *InAirResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -729,11 +718,9 @@ type SubscribeLandedStateRequest struct { func (x *SubscribeLandedStateRequest) Reset() { *x = SubscribeLandedStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeLandedStateRequest) String() string { @@ -744,7 +731,7 @@ func (*SubscribeLandedStateRequest) ProtoMessage() {} func (x *SubscribeLandedStateRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -769,11 +756,9 @@ type LandedStateResponse struct { func (x *LandedStateResponse) Reset() { *x = LandedStateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LandedStateResponse) String() string { @@ -784,7 +769,7 @@ func (*LandedStateResponse) ProtoMessage() {} func (x *LandedStateResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -814,11 +799,9 @@ type SubscribeArmedRequest struct { func (x *SubscribeArmedRequest) Reset() { *x = SubscribeArmedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeArmedRequest) String() string { @@ -829,7 +812,7 @@ func (*SubscribeArmedRequest) ProtoMessage() {} func (x *SubscribeArmedRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -854,11 +837,9 @@ type ArmedResponse struct { func (x *ArmedResponse) Reset() { *x = ArmedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ArmedResponse) String() string { @@ -869,7 +850,7 @@ func (*ArmedResponse) ProtoMessage() {} func (x *ArmedResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -899,11 +880,9 @@ type SubscribeVtolStateRequest struct { func (x *SubscribeVtolStateRequest) Reset() { *x = SubscribeVtolStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeVtolStateRequest) String() string { @@ -914,7 +893,7 @@ func (*SubscribeVtolStateRequest) ProtoMessage() {} func (x *SubscribeVtolStateRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -939,11 +918,9 @@ type VtolStateResponse struct { func (x *VtolStateResponse) Reset() { *x = VtolStateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VtolStateResponse) String() string { @@ -954,7 +931,7 @@ func (*VtolStateResponse) ProtoMessage() {} func (x *VtolStateResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -984,11 +961,9 @@ type SubscribeAttitudeQuaternionRequest struct { func (x *SubscribeAttitudeQuaternionRequest) Reset() { *x = SubscribeAttitudeQuaternionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeAttitudeQuaternionRequest) String() string { @@ -999,7 +974,7 @@ func (*SubscribeAttitudeQuaternionRequest) ProtoMessage() {} func (x *SubscribeAttitudeQuaternionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1024,11 +999,9 @@ type AttitudeQuaternionResponse struct { func (x *AttitudeQuaternionResponse) Reset() { *x = AttitudeQuaternionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AttitudeQuaternionResponse) String() string { @@ -1039,7 +1012,7 @@ func (*AttitudeQuaternionResponse) ProtoMessage() {} func (x *AttitudeQuaternionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1069,11 +1042,9 @@ type SubscribeAttitudeEulerRequest struct { func (x *SubscribeAttitudeEulerRequest) Reset() { *x = SubscribeAttitudeEulerRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeAttitudeEulerRequest) String() string { @@ -1084,7 +1055,7 @@ func (*SubscribeAttitudeEulerRequest) ProtoMessage() {} func (x *SubscribeAttitudeEulerRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1109,11 +1080,9 @@ type AttitudeEulerResponse struct { func (x *AttitudeEulerResponse) Reset() { *x = AttitudeEulerResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AttitudeEulerResponse) String() string { @@ -1124,7 +1093,7 @@ func (*AttitudeEulerResponse) ProtoMessage() {} func (x *AttitudeEulerResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1154,11 +1123,9 @@ type SubscribeAttitudeAngularVelocityBodyRequest struct { func (x *SubscribeAttitudeAngularVelocityBodyRequest) Reset() { *x = SubscribeAttitudeAngularVelocityBodyRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeAttitudeAngularVelocityBodyRequest) String() string { @@ -1169,7 +1136,7 @@ func (*SubscribeAttitudeAngularVelocityBodyRequest) ProtoMessage() {} func (x *SubscribeAttitudeAngularVelocityBodyRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1194,11 +1161,9 @@ type AttitudeAngularVelocityBodyResponse struct { func (x *AttitudeAngularVelocityBodyResponse) Reset() { *x = AttitudeAngularVelocityBodyResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AttitudeAngularVelocityBodyResponse) String() string { @@ -1209,7 +1174,7 @@ func (*AttitudeAngularVelocityBodyResponse) ProtoMessage() {} func (x *AttitudeAngularVelocityBodyResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1239,11 +1204,9 @@ type SubscribeCameraAttitudeQuaternionRequest struct { func (x *SubscribeCameraAttitudeQuaternionRequest) Reset() { *x = SubscribeCameraAttitudeQuaternionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCameraAttitudeQuaternionRequest) String() string { @@ -1254,7 +1217,7 @@ func (*SubscribeCameraAttitudeQuaternionRequest) ProtoMessage() {} func (x *SubscribeCameraAttitudeQuaternionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1279,11 +1242,9 @@ type CameraAttitudeQuaternionResponse struct { func (x *CameraAttitudeQuaternionResponse) Reset() { *x = CameraAttitudeQuaternionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CameraAttitudeQuaternionResponse) String() string { @@ -1294,7 +1255,7 @@ func (*CameraAttitudeQuaternionResponse) ProtoMessage() {} func (x *CameraAttitudeQuaternionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1324,11 +1285,9 @@ type SubscribeCameraAttitudeEulerRequest struct { func (x *SubscribeCameraAttitudeEulerRequest) Reset() { *x = SubscribeCameraAttitudeEulerRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeCameraAttitudeEulerRequest) String() string { @@ -1339,7 +1298,7 @@ func (*SubscribeCameraAttitudeEulerRequest) ProtoMessage() {} func (x *SubscribeCameraAttitudeEulerRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1364,11 +1323,9 @@ type CameraAttitudeEulerResponse struct { func (x *CameraAttitudeEulerResponse) Reset() { *x = CameraAttitudeEulerResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *CameraAttitudeEulerResponse) String() string { @@ -1379,7 +1336,7 @@ func (*CameraAttitudeEulerResponse) ProtoMessage() {} func (x *CameraAttitudeEulerResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1409,11 +1366,9 @@ type SubscribeVelocityNedRequest struct { func (x *SubscribeVelocityNedRequest) Reset() { *x = SubscribeVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeVelocityNedRequest) String() string { @@ -1424,7 +1379,7 @@ func (*SubscribeVelocityNedRequest) ProtoMessage() {} func (x *SubscribeVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1449,11 +1404,9 @@ type VelocityNedResponse struct { func (x *VelocityNedResponse) Reset() { *x = VelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityNedResponse) String() string { @@ -1464,7 +1417,7 @@ func (*VelocityNedResponse) ProtoMessage() {} func (x *VelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1494,11 +1447,9 @@ type SubscribeGpsInfoRequest struct { func (x *SubscribeGpsInfoRequest) Reset() { *x = SubscribeGpsInfoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeGpsInfoRequest) String() string { @@ -1509,7 +1460,7 @@ func (*SubscribeGpsInfoRequest) ProtoMessage() {} func (x *SubscribeGpsInfoRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1534,11 +1485,9 @@ type GpsInfoResponse struct { func (x *GpsInfoResponse) Reset() { *x = GpsInfoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GpsInfoResponse) String() string { @@ -1549,7 +1498,7 @@ func (*GpsInfoResponse) ProtoMessage() {} func (x *GpsInfoResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1579,11 +1528,9 @@ type SubscribeRawGpsRequest struct { func (x *SubscribeRawGpsRequest) Reset() { *x = SubscribeRawGpsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeRawGpsRequest) String() string { @@ -1594,7 +1541,7 @@ func (*SubscribeRawGpsRequest) ProtoMessage() {} func (x *SubscribeRawGpsRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1619,11 +1566,9 @@ type RawGpsResponse struct { func (x *RawGpsResponse) Reset() { *x = RawGpsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RawGpsResponse) String() string { @@ -1634,7 +1579,7 @@ func (*RawGpsResponse) ProtoMessage() {} func (x *RawGpsResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1664,11 +1609,9 @@ type SubscribeBatteryRequest struct { func (x *SubscribeBatteryRequest) Reset() { *x = SubscribeBatteryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeBatteryRequest) String() string { @@ -1679,7 +1622,7 @@ func (*SubscribeBatteryRequest) ProtoMessage() {} func (x *SubscribeBatteryRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1704,11 +1647,9 @@ type BatteryResponse struct { func (x *BatteryResponse) Reset() { *x = BatteryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *BatteryResponse) String() string { @@ -1719,7 +1660,7 @@ func (*BatteryResponse) ProtoMessage() {} func (x *BatteryResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1749,11 +1690,9 @@ type SubscribeFlightModeRequest struct { func (x *SubscribeFlightModeRequest) Reset() { *x = SubscribeFlightModeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeFlightModeRequest) String() string { @@ -1764,7 +1703,7 @@ func (*SubscribeFlightModeRequest) ProtoMessage() {} func (x *SubscribeFlightModeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1789,11 +1728,9 @@ type FlightModeResponse struct { func (x *FlightModeResponse) Reset() { *x = FlightModeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FlightModeResponse) String() string { @@ -1804,7 +1741,7 @@ func (*FlightModeResponse) ProtoMessage() {} func (x *FlightModeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1834,11 +1771,9 @@ type SubscribeHealthRequest struct { func (x *SubscribeHealthRequest) Reset() { *x = SubscribeHealthRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeHealthRequest) String() string { @@ -1849,7 +1784,7 @@ func (*SubscribeHealthRequest) ProtoMessage() {} func (x *SubscribeHealthRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1874,11 +1809,9 @@ type HealthResponse struct { func (x *HealthResponse) Reset() { *x = HealthResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HealthResponse) String() string { @@ -1889,7 +1822,7 @@ func (*HealthResponse) ProtoMessage() {} func (x *HealthResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1919,11 +1852,9 @@ type SubscribeRcStatusRequest struct { func (x *SubscribeRcStatusRequest) Reset() { *x = SubscribeRcStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[34] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeRcStatusRequest) String() string { @@ -1934,7 +1865,7 @@ func (*SubscribeRcStatusRequest) ProtoMessage() {} func (x *SubscribeRcStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[34] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1959,11 +1890,9 @@ type RcStatusResponse struct { func (x *RcStatusResponse) Reset() { *x = RcStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RcStatusResponse) String() string { @@ -1974,7 +1903,7 @@ func (*RcStatusResponse) ProtoMessage() {} func (x *RcStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[35] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2004,11 +1933,9 @@ type SubscribeStatusTextRequest struct { func (x *SubscribeStatusTextRequest) Reset() { *x = SubscribeStatusTextRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[36] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStatusTextRequest) String() string { @@ -2019,7 +1946,7 @@ func (*SubscribeStatusTextRequest) ProtoMessage() {} func (x *SubscribeStatusTextRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[36] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2044,11 +1971,9 @@ type StatusTextResponse struct { func (x *StatusTextResponse) Reset() { *x = StatusTextResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[37] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StatusTextResponse) String() string { @@ -2059,7 +1984,7 @@ func (*StatusTextResponse) ProtoMessage() {} func (x *StatusTextResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[37] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2089,11 +2014,9 @@ type SubscribeActuatorControlTargetRequest struct { func (x *SubscribeActuatorControlTargetRequest) Reset() { *x = SubscribeActuatorControlTargetRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[38] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeActuatorControlTargetRequest) String() string { @@ -2104,7 +2027,7 @@ func (*SubscribeActuatorControlTargetRequest) ProtoMessage() {} func (x *SubscribeActuatorControlTargetRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[38] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2129,11 +2052,9 @@ type ActuatorControlTargetResponse struct { func (x *ActuatorControlTargetResponse) Reset() { *x = ActuatorControlTargetResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[39] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorControlTargetResponse) String() string { @@ -2144,7 +2065,7 @@ func (*ActuatorControlTargetResponse) ProtoMessage() {} func (x *ActuatorControlTargetResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[39] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2174,11 +2095,9 @@ type SubscribeActuatorOutputStatusRequest struct { func (x *SubscribeActuatorOutputStatusRequest) Reset() { *x = SubscribeActuatorOutputStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[40] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeActuatorOutputStatusRequest) String() string { @@ -2189,7 +2108,7 @@ func (*SubscribeActuatorOutputStatusRequest) ProtoMessage() {} func (x *SubscribeActuatorOutputStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[40] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2214,11 +2133,9 @@ type ActuatorOutputStatusResponse struct { func (x *ActuatorOutputStatusResponse) Reset() { *x = ActuatorOutputStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[41] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorOutputStatusResponse) String() string { @@ -2229,7 +2146,7 @@ func (*ActuatorOutputStatusResponse) ProtoMessage() {} func (x *ActuatorOutputStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[41] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2259,11 +2176,9 @@ type SubscribeOdometryRequest struct { func (x *SubscribeOdometryRequest) Reset() { *x = SubscribeOdometryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[42] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeOdometryRequest) String() string { @@ -2274,7 +2189,7 @@ func (*SubscribeOdometryRequest) ProtoMessage() {} func (x *SubscribeOdometryRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[42] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2299,11 +2214,9 @@ type OdometryResponse struct { func (x *OdometryResponse) Reset() { *x = OdometryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[43] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *OdometryResponse) String() string { @@ -2314,7 +2227,7 @@ func (*OdometryResponse) ProtoMessage() {} func (x *OdometryResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[43] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2344,11 +2257,9 @@ type SubscribePositionVelocityNedRequest struct { func (x *SubscribePositionVelocityNedRequest) Reset() { *x = SubscribePositionVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[44] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribePositionVelocityNedRequest) String() string { @@ -2359,7 +2270,7 @@ func (*SubscribePositionVelocityNedRequest) ProtoMessage() {} func (x *SubscribePositionVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[44] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2384,11 +2295,9 @@ type PositionVelocityNedResponse struct { func (x *PositionVelocityNedResponse) Reset() { *x = PositionVelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[45] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[45] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionVelocityNedResponse) String() string { @@ -2399,7 +2308,7 @@ func (*PositionVelocityNedResponse) ProtoMessage() {} func (x *PositionVelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[45] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2429,11 +2338,9 @@ type SubscribeGroundTruthRequest struct { func (x *SubscribeGroundTruthRequest) Reset() { *x = SubscribeGroundTruthRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[46] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[46] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeGroundTruthRequest) String() string { @@ -2444,7 +2351,7 @@ func (*SubscribeGroundTruthRequest) ProtoMessage() {} func (x *SubscribeGroundTruthRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[46] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2469,11 +2376,9 @@ type GroundTruthResponse struct { func (x *GroundTruthResponse) Reset() { *x = GroundTruthResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[47] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[47] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GroundTruthResponse) String() string { @@ -2484,7 +2389,7 @@ func (*GroundTruthResponse) ProtoMessage() {} func (x *GroundTruthResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[47] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2514,11 +2419,9 @@ type SubscribeFixedwingMetricsRequest struct { func (x *SubscribeFixedwingMetricsRequest) Reset() { *x = SubscribeFixedwingMetricsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[48] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[48] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeFixedwingMetricsRequest) String() string { @@ -2529,7 +2432,7 @@ func (*SubscribeFixedwingMetricsRequest) ProtoMessage() {} func (x *SubscribeFixedwingMetricsRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[48] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2554,11 +2457,9 @@ type FixedwingMetricsResponse struct { func (x *FixedwingMetricsResponse) Reset() { *x = FixedwingMetricsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[49] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[49] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FixedwingMetricsResponse) String() string { @@ -2569,7 +2470,7 @@ func (*FixedwingMetricsResponse) ProtoMessage() {} func (x *FixedwingMetricsResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[49] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2599,11 +2500,9 @@ type SubscribeImuRequest struct { func (x *SubscribeImuRequest) Reset() { *x = SubscribeImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[50] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[50] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeImuRequest) String() string { @@ -2614,7 +2513,7 @@ func (*SubscribeImuRequest) ProtoMessage() {} func (x *SubscribeImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[50] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2639,11 +2538,9 @@ type ImuResponse struct { func (x *ImuResponse) Reset() { *x = ImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[51] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[51] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ImuResponse) String() string { @@ -2654,7 +2551,7 @@ func (*ImuResponse) ProtoMessage() {} func (x *ImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[51] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2684,11 +2581,9 @@ type SubscribeScaledImuRequest struct { func (x *SubscribeScaledImuRequest) Reset() { *x = SubscribeScaledImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[52] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[52] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeScaledImuRequest) String() string { @@ -2699,7 +2594,7 @@ func (*SubscribeScaledImuRequest) ProtoMessage() {} func (x *SubscribeScaledImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[52] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2724,11 +2619,9 @@ type ScaledImuResponse struct { func (x *ScaledImuResponse) Reset() { *x = ScaledImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[53] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[53] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ScaledImuResponse) String() string { @@ -2739,7 +2632,7 @@ func (*ScaledImuResponse) ProtoMessage() {} func (x *ScaledImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[53] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2769,11 +2662,9 @@ type SubscribeRawImuRequest struct { func (x *SubscribeRawImuRequest) Reset() { *x = SubscribeRawImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[54] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[54] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeRawImuRequest) String() string { @@ -2784,7 +2675,7 @@ func (*SubscribeRawImuRequest) ProtoMessage() {} func (x *SubscribeRawImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[54] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2809,11 +2700,9 @@ type RawImuResponse struct { func (x *RawImuResponse) Reset() { *x = RawImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[55] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[55] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RawImuResponse) String() string { @@ -2824,7 +2713,7 @@ func (*RawImuResponse) ProtoMessage() {} func (x *RawImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[55] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2854,11 +2743,9 @@ type SubscribeHealthAllOkRequest struct { func (x *SubscribeHealthAllOkRequest) Reset() { *x = SubscribeHealthAllOkRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[56] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[56] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeHealthAllOkRequest) String() string { @@ -2869,7 +2756,7 @@ func (*SubscribeHealthAllOkRequest) ProtoMessage() {} func (x *SubscribeHealthAllOkRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[56] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2894,11 +2781,9 @@ type HealthAllOkResponse struct { func (x *HealthAllOkResponse) Reset() { *x = HealthAllOkResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[57] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[57] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HealthAllOkResponse) String() string { @@ -2909,7 +2794,7 @@ func (*HealthAllOkResponse) ProtoMessage() {} func (x *HealthAllOkResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[57] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2939,11 +2824,9 @@ type SubscribeUnixEpochTimeRequest struct { func (x *SubscribeUnixEpochTimeRequest) Reset() { *x = SubscribeUnixEpochTimeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[58] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[58] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeUnixEpochTimeRequest) String() string { @@ -2954,7 +2837,7 @@ func (*SubscribeUnixEpochTimeRequest) ProtoMessage() {} func (x *SubscribeUnixEpochTimeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[58] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2979,11 +2862,9 @@ type UnixEpochTimeResponse struct { func (x *UnixEpochTimeResponse) Reset() { *x = UnixEpochTimeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[59] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[59] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *UnixEpochTimeResponse) String() string { @@ -2994,7 +2875,7 @@ func (*UnixEpochTimeResponse) ProtoMessage() {} func (x *UnixEpochTimeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[59] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3024,11 +2905,9 @@ type SubscribeDistanceSensorRequest struct { func (x *SubscribeDistanceSensorRequest) Reset() { *x = SubscribeDistanceSensorRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[60] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[60] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeDistanceSensorRequest) String() string { @@ -3039,7 +2918,7 @@ func (*SubscribeDistanceSensorRequest) ProtoMessage() {} func (x *SubscribeDistanceSensorRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[60] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3064,11 +2943,9 @@ type DistanceSensorResponse struct { func (x *DistanceSensorResponse) Reset() { *x = DistanceSensorResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[61] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[61] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DistanceSensorResponse) String() string { @@ -3079,7 +2956,7 @@ func (*DistanceSensorResponse) ProtoMessage() {} func (x *DistanceSensorResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[61] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3109,11 +2986,9 @@ type SubscribeScaledPressureRequest struct { func (x *SubscribeScaledPressureRequest) Reset() { *x = SubscribeScaledPressureRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[62] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[62] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeScaledPressureRequest) String() string { @@ -3124,7 +2999,7 @@ func (*SubscribeScaledPressureRequest) ProtoMessage() {} func (x *SubscribeScaledPressureRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[62] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3149,11 +3024,9 @@ type ScaledPressureResponse struct { func (x *ScaledPressureResponse) Reset() { *x = ScaledPressureResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[63] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[63] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ScaledPressureResponse) String() string { @@ -3164,7 +3037,7 @@ func (*ScaledPressureResponse) ProtoMessage() {} func (x *ScaledPressureResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[63] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3194,11 +3067,9 @@ type SubscribeHeadingRequest struct { func (x *SubscribeHeadingRequest) Reset() { *x = SubscribeHeadingRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[64] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[64] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeHeadingRequest) String() string { @@ -3209,7 +3080,7 @@ func (*SubscribeHeadingRequest) ProtoMessage() {} func (x *SubscribeHeadingRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[64] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3234,11 +3105,9 @@ type HeadingResponse struct { func (x *HeadingResponse) Reset() { *x = HeadingResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[65] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[65] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HeadingResponse) String() string { @@ -3249,7 +3118,7 @@ func (*HeadingResponse) ProtoMessage() {} func (x *HeadingResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[65] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3279,11 +3148,9 @@ type SubscribeAltitudeRequest struct { func (x *SubscribeAltitudeRequest) Reset() { *x = SubscribeAltitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[66] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[66] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeAltitudeRequest) String() string { @@ -3294,7 +3161,7 @@ func (*SubscribeAltitudeRequest) ProtoMessage() {} func (x *SubscribeAltitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[66] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3319,11 +3186,9 @@ type AltitudeResponse struct { func (x *AltitudeResponse) Reset() { *x = AltitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[67] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[67] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AltitudeResponse) String() string { @@ -3334,7 +3199,7 @@ func (*AltitudeResponse) ProtoMessage() {} func (x *AltitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[67] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3366,11 +3231,9 @@ type SetRatePositionRequest struct { func (x *SetRatePositionRequest) Reset() { *x = SetRatePositionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[68] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[68] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRatePositionRequest) String() string { @@ -3381,7 +3244,7 @@ func (*SetRatePositionRequest) ProtoMessage() {} func (x *SetRatePositionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[68] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3413,11 +3276,9 @@ type SetRatePositionResponse struct { func (x *SetRatePositionResponse) Reset() { *x = SetRatePositionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[69] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[69] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRatePositionResponse) String() string { @@ -3428,7 +3289,7 @@ func (*SetRatePositionResponse) ProtoMessage() {} func (x *SetRatePositionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[69] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3460,11 +3321,9 @@ type SetRateHomeRequest struct { func (x *SetRateHomeRequest) Reset() { *x = SetRateHomeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[70] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[70] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateHomeRequest) String() string { @@ -3475,7 +3334,7 @@ func (*SetRateHomeRequest) ProtoMessage() {} func (x *SetRateHomeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[70] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3507,11 +3366,9 @@ type SetRateHomeResponse struct { func (x *SetRateHomeResponse) Reset() { *x = SetRateHomeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[71] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[71] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateHomeResponse) String() string { @@ -3522,7 +3379,7 @@ func (*SetRateHomeResponse) ProtoMessage() {} func (x *SetRateHomeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[71] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3554,11 +3411,9 @@ type SetRateInAirRequest struct { func (x *SetRateInAirRequest) Reset() { *x = SetRateInAirRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[72] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[72] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateInAirRequest) String() string { @@ -3569,7 +3424,7 @@ func (*SetRateInAirRequest) ProtoMessage() {} func (x *SetRateInAirRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[72] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3601,11 +3456,9 @@ type SetRateInAirResponse struct { func (x *SetRateInAirResponse) Reset() { *x = SetRateInAirResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[73] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[73] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateInAirResponse) String() string { @@ -3616,7 +3469,7 @@ func (*SetRateInAirResponse) ProtoMessage() {} func (x *SetRateInAirResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[73] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3648,11 +3501,9 @@ type SetRateLandedStateRequest struct { func (x *SetRateLandedStateRequest) Reset() { *x = SetRateLandedStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[74] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[74] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateLandedStateRequest) String() string { @@ -3663,7 +3514,7 @@ func (*SetRateLandedStateRequest) ProtoMessage() {} func (x *SetRateLandedStateRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[74] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3695,11 +3546,9 @@ type SetRateLandedStateResponse struct { func (x *SetRateLandedStateResponse) Reset() { *x = SetRateLandedStateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[75] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[75] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateLandedStateResponse) String() string { @@ -3710,7 +3559,7 @@ func (*SetRateLandedStateResponse) ProtoMessage() {} func (x *SetRateLandedStateResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[75] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3742,11 +3591,9 @@ type SetRateVtolStateRequest struct { func (x *SetRateVtolStateRequest) Reset() { *x = SetRateVtolStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[76] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[76] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateVtolStateRequest) String() string { @@ -3757,7 +3604,7 @@ func (*SetRateVtolStateRequest) ProtoMessage() {} func (x *SetRateVtolStateRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[76] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3789,11 +3636,9 @@ type SetRateVtolStateResponse struct { func (x *SetRateVtolStateResponse) Reset() { *x = SetRateVtolStateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[77] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[77] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateVtolStateResponse) String() string { @@ -3804,7 +3649,7 @@ func (*SetRateVtolStateResponse) ProtoMessage() {} func (x *SetRateVtolStateResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[77] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3836,11 +3681,9 @@ type SetRateAttitudeEulerRequest struct { func (x *SetRateAttitudeEulerRequest) Reset() { *x = SetRateAttitudeEulerRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[78] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[78] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAttitudeEulerRequest) String() string { @@ -3851,7 +3694,7 @@ func (*SetRateAttitudeEulerRequest) ProtoMessage() {} func (x *SetRateAttitudeEulerRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[78] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3883,11 +3726,9 @@ type SetRateAttitudeEulerResponse struct { func (x *SetRateAttitudeEulerResponse) Reset() { *x = SetRateAttitudeEulerResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[79] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[79] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAttitudeEulerResponse) String() string { @@ -3898,7 +3739,7 @@ func (*SetRateAttitudeEulerResponse) ProtoMessage() {} func (x *SetRateAttitudeEulerResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[79] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3930,11 +3771,9 @@ type SetRateAttitudeQuaternionRequest struct { func (x *SetRateAttitudeQuaternionRequest) Reset() { *x = SetRateAttitudeQuaternionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[80] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[80] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAttitudeQuaternionRequest) String() string { @@ -3945,7 +3784,7 @@ func (*SetRateAttitudeQuaternionRequest) ProtoMessage() {} func (x *SetRateAttitudeQuaternionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[80] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3977,11 +3816,9 @@ type SetRateAttitudeQuaternionResponse struct { func (x *SetRateAttitudeQuaternionResponse) Reset() { *x = SetRateAttitudeQuaternionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[81] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[81] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAttitudeQuaternionResponse) String() string { @@ -3992,7 +3829,7 @@ func (*SetRateAttitudeQuaternionResponse) ProtoMessage() {} func (x *SetRateAttitudeQuaternionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[81] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4024,11 +3861,9 @@ type SetRateAttitudeAngularVelocityBodyRequest struct { func (x *SetRateAttitudeAngularVelocityBodyRequest) Reset() { *x = SetRateAttitudeAngularVelocityBodyRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[82] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[82] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAttitudeAngularVelocityBodyRequest) String() string { @@ -4039,7 +3874,7 @@ func (*SetRateAttitudeAngularVelocityBodyRequest) ProtoMessage() {} func (x *SetRateAttitudeAngularVelocityBodyRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[82] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4071,11 +3906,9 @@ type SetRateAttitudeAngularVelocityBodyResponse struct { func (x *SetRateAttitudeAngularVelocityBodyResponse) Reset() { *x = SetRateAttitudeAngularVelocityBodyResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[83] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[83] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAttitudeAngularVelocityBodyResponse) String() string { @@ -4086,7 +3919,7 @@ func (*SetRateAttitudeAngularVelocityBodyResponse) ProtoMessage() {} func (x *SetRateAttitudeAngularVelocityBodyResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[83] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4118,11 +3951,9 @@ type SetRateCameraAttitudeQuaternionRequest struct { func (x *SetRateCameraAttitudeQuaternionRequest) Reset() { *x = SetRateCameraAttitudeQuaternionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[84] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[84] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateCameraAttitudeQuaternionRequest) String() string { @@ -4133,7 +3964,7 @@ func (*SetRateCameraAttitudeQuaternionRequest) ProtoMessage() {} func (x *SetRateCameraAttitudeQuaternionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[84] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4165,11 +3996,9 @@ type SetRateCameraAttitudeQuaternionResponse struct { func (x *SetRateCameraAttitudeQuaternionResponse) Reset() { *x = SetRateCameraAttitudeQuaternionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[85] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[85] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateCameraAttitudeQuaternionResponse) String() string { @@ -4180,7 +4009,7 @@ func (*SetRateCameraAttitudeQuaternionResponse) ProtoMessage() {} func (x *SetRateCameraAttitudeQuaternionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[85] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4212,11 +4041,9 @@ type SetRateCameraAttitudeRequest struct { func (x *SetRateCameraAttitudeRequest) Reset() { *x = SetRateCameraAttitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[86] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[86] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateCameraAttitudeRequest) String() string { @@ -4227,7 +4054,7 @@ func (*SetRateCameraAttitudeRequest) ProtoMessage() {} func (x *SetRateCameraAttitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[86] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4259,11 +4086,9 @@ type SetRateCameraAttitudeResponse struct { func (x *SetRateCameraAttitudeResponse) Reset() { *x = SetRateCameraAttitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[87] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[87] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateCameraAttitudeResponse) String() string { @@ -4274,7 +4099,7 @@ func (*SetRateCameraAttitudeResponse) ProtoMessage() {} func (x *SetRateCameraAttitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[87] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4306,11 +4131,9 @@ type SetRateVelocityNedRequest struct { func (x *SetRateVelocityNedRequest) Reset() { *x = SetRateVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[88] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[88] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateVelocityNedRequest) String() string { @@ -4321,7 +4144,7 @@ func (*SetRateVelocityNedRequest) ProtoMessage() {} func (x *SetRateVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[88] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4353,11 +4176,9 @@ type SetRateVelocityNedResponse struct { func (x *SetRateVelocityNedResponse) Reset() { *x = SetRateVelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[89] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[89] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateVelocityNedResponse) String() string { @@ -4368,7 +4189,7 @@ func (*SetRateVelocityNedResponse) ProtoMessage() {} func (x *SetRateVelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[89] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4400,11 +4221,9 @@ type SetRateGpsInfoRequest struct { func (x *SetRateGpsInfoRequest) Reset() { *x = SetRateGpsInfoRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[90] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[90] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateGpsInfoRequest) String() string { @@ -4415,7 +4234,7 @@ func (*SetRateGpsInfoRequest) ProtoMessage() {} func (x *SetRateGpsInfoRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[90] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4447,11 +4266,9 @@ type SetRateGpsInfoResponse struct { func (x *SetRateGpsInfoResponse) Reset() { *x = SetRateGpsInfoResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[91] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[91] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateGpsInfoResponse) String() string { @@ -4462,7 +4279,7 @@ func (*SetRateGpsInfoResponse) ProtoMessage() {} func (x *SetRateGpsInfoResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[91] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4494,11 +4311,9 @@ type SetRateRawGpsRequest struct { func (x *SetRateRawGpsRequest) Reset() { *x = SetRateRawGpsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[92] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[92] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateRawGpsRequest) String() string { @@ -4509,7 +4324,7 @@ func (*SetRateRawGpsRequest) ProtoMessage() {} func (x *SetRateRawGpsRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[92] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4541,11 +4356,9 @@ type SetRateBatteryRequest struct { func (x *SetRateBatteryRequest) Reset() { *x = SetRateBatteryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[93] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[93] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateBatteryRequest) String() string { @@ -4556,7 +4369,7 @@ func (*SetRateBatteryRequest) ProtoMessage() {} func (x *SetRateBatteryRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[93] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4588,11 +4401,9 @@ type SetRateBatteryResponse struct { func (x *SetRateBatteryResponse) Reset() { *x = SetRateBatteryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[94] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[94] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateBatteryResponse) String() string { @@ -4603,7 +4414,7 @@ func (*SetRateBatteryResponse) ProtoMessage() {} func (x *SetRateBatteryResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[94] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4635,11 +4446,9 @@ type SetRateRcStatusRequest struct { func (x *SetRateRcStatusRequest) Reset() { *x = SetRateRcStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[95] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[95] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateRcStatusRequest) String() string { @@ -4650,7 +4459,7 @@ func (*SetRateRcStatusRequest) ProtoMessage() {} func (x *SetRateRcStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[95] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4682,11 +4491,9 @@ type SetRateRcStatusResponse struct { func (x *SetRateRcStatusResponse) Reset() { *x = SetRateRcStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[96] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[96] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateRcStatusResponse) String() string { @@ -4697,7 +4504,7 @@ func (*SetRateRcStatusResponse) ProtoMessage() {} func (x *SetRateRcStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[96] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4729,11 +4536,9 @@ type SetRateActuatorControlTargetRequest struct { func (x *SetRateActuatorControlTargetRequest) Reset() { *x = SetRateActuatorControlTargetRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[97] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[97] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateActuatorControlTargetRequest) String() string { @@ -4744,7 +4549,7 @@ func (*SetRateActuatorControlTargetRequest) ProtoMessage() {} func (x *SetRateActuatorControlTargetRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[97] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4776,11 +4581,9 @@ type SetRateActuatorControlTargetResponse struct { func (x *SetRateActuatorControlTargetResponse) Reset() { *x = SetRateActuatorControlTargetResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[98] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[98] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateActuatorControlTargetResponse) String() string { @@ -4791,7 +4594,7 @@ func (*SetRateActuatorControlTargetResponse) ProtoMessage() {} func (x *SetRateActuatorControlTargetResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[98] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4823,11 +4626,9 @@ type SetRateActuatorOutputStatusRequest struct { func (x *SetRateActuatorOutputStatusRequest) Reset() { *x = SetRateActuatorOutputStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[99] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[99] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateActuatorOutputStatusRequest) String() string { @@ -4838,7 +4639,7 @@ func (*SetRateActuatorOutputStatusRequest) ProtoMessage() {} func (x *SetRateActuatorOutputStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[99] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4870,11 +4671,9 @@ type SetRateActuatorOutputStatusResponse struct { func (x *SetRateActuatorOutputStatusResponse) Reset() { *x = SetRateActuatorOutputStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[100] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[100] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateActuatorOutputStatusResponse) String() string { @@ -4885,7 +4684,7 @@ func (*SetRateActuatorOutputStatusResponse) ProtoMessage() {} func (x *SetRateActuatorOutputStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[100] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4917,11 +4716,9 @@ type SetRateOdometryRequest struct { func (x *SetRateOdometryRequest) Reset() { *x = SetRateOdometryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[101] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[101] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateOdometryRequest) String() string { @@ -4932,7 +4729,7 @@ func (*SetRateOdometryRequest) ProtoMessage() {} func (x *SetRateOdometryRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[101] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4964,11 +4761,9 @@ type SetRateOdometryResponse struct { func (x *SetRateOdometryResponse) Reset() { *x = SetRateOdometryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[102] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[102] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateOdometryResponse) String() string { @@ -4979,7 +4774,7 @@ func (*SetRateOdometryResponse) ProtoMessage() {} func (x *SetRateOdometryResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[102] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5011,11 +4806,9 @@ type SetRatePositionVelocityNedRequest struct { func (x *SetRatePositionVelocityNedRequest) Reset() { *x = SetRatePositionVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[103] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[103] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRatePositionVelocityNedRequest) String() string { @@ -5026,7 +4819,7 @@ func (*SetRatePositionVelocityNedRequest) ProtoMessage() {} func (x *SetRatePositionVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[103] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5058,11 +4851,9 @@ type SetRatePositionVelocityNedResponse struct { func (x *SetRatePositionVelocityNedResponse) Reset() { *x = SetRatePositionVelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[104] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[104] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRatePositionVelocityNedResponse) String() string { @@ -5073,7 +4864,7 @@ func (*SetRatePositionVelocityNedResponse) ProtoMessage() {} func (x *SetRatePositionVelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[104] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5105,11 +4896,9 @@ type SetRateGroundTruthRequest struct { func (x *SetRateGroundTruthRequest) Reset() { *x = SetRateGroundTruthRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[105] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[105] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateGroundTruthRequest) String() string { @@ -5120,7 +4909,7 @@ func (*SetRateGroundTruthRequest) ProtoMessage() {} func (x *SetRateGroundTruthRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[105] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5152,11 +4941,9 @@ type SetRateGroundTruthResponse struct { func (x *SetRateGroundTruthResponse) Reset() { *x = SetRateGroundTruthResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[106] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[106] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateGroundTruthResponse) String() string { @@ -5167,7 +4954,7 @@ func (*SetRateGroundTruthResponse) ProtoMessage() {} func (x *SetRateGroundTruthResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[106] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5199,11 +4986,9 @@ type SetRateFixedwingMetricsRequest struct { func (x *SetRateFixedwingMetricsRequest) Reset() { *x = SetRateFixedwingMetricsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[107] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[107] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateFixedwingMetricsRequest) String() string { @@ -5214,7 +4999,7 @@ func (*SetRateFixedwingMetricsRequest) ProtoMessage() {} func (x *SetRateFixedwingMetricsRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[107] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5246,11 +5031,9 @@ type SetRateFixedwingMetricsResponse struct { func (x *SetRateFixedwingMetricsResponse) Reset() { *x = SetRateFixedwingMetricsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[108] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[108] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateFixedwingMetricsResponse) String() string { @@ -5261,7 +5044,7 @@ func (*SetRateFixedwingMetricsResponse) ProtoMessage() {} func (x *SetRateFixedwingMetricsResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[108] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5293,11 +5076,9 @@ type SetRateImuRequest struct { func (x *SetRateImuRequest) Reset() { *x = SetRateImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[109] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[109] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateImuRequest) String() string { @@ -5308,7 +5089,7 @@ func (*SetRateImuRequest) ProtoMessage() {} func (x *SetRateImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[109] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5340,11 +5121,9 @@ type SetRateImuResponse struct { func (x *SetRateImuResponse) Reset() { *x = SetRateImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[110] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[110] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateImuResponse) String() string { @@ -5355,7 +5134,7 @@ func (*SetRateImuResponse) ProtoMessage() {} func (x *SetRateImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[110] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5387,11 +5166,9 @@ type SetRateScaledImuRequest struct { func (x *SetRateScaledImuRequest) Reset() { *x = SetRateScaledImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[111] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[111] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateScaledImuRequest) String() string { @@ -5402,7 +5179,7 @@ func (*SetRateScaledImuRequest) ProtoMessage() {} func (x *SetRateScaledImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[111] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5434,11 +5211,9 @@ type SetRateScaledImuResponse struct { func (x *SetRateScaledImuResponse) Reset() { *x = SetRateScaledImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[112] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[112] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateScaledImuResponse) String() string { @@ -5449,7 +5224,7 @@ func (*SetRateScaledImuResponse) ProtoMessage() {} func (x *SetRateScaledImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[112] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5481,11 +5256,9 @@ type SetRateRawImuRequest struct { func (x *SetRateRawImuRequest) Reset() { *x = SetRateRawImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[113] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[113] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateRawImuRequest) String() string { @@ -5496,7 +5269,7 @@ func (*SetRateRawImuRequest) ProtoMessage() {} func (x *SetRateRawImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[113] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5528,11 +5301,9 @@ type SetRateRawImuResponse struct { func (x *SetRateRawImuResponse) Reset() { *x = SetRateRawImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[114] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[114] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateRawImuResponse) String() string { @@ -5543,7 +5314,7 @@ func (*SetRateRawImuResponse) ProtoMessage() {} func (x *SetRateRawImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[114] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5575,11 +5346,9 @@ type SetRateUnixEpochTimeRequest struct { func (x *SetRateUnixEpochTimeRequest) Reset() { *x = SetRateUnixEpochTimeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[115] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[115] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateUnixEpochTimeRequest) String() string { @@ -5590,7 +5359,7 @@ func (*SetRateUnixEpochTimeRequest) ProtoMessage() {} func (x *SetRateUnixEpochTimeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[115] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5622,11 +5391,9 @@ type SetRateUnixEpochTimeResponse struct { func (x *SetRateUnixEpochTimeResponse) Reset() { *x = SetRateUnixEpochTimeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[116] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[116] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateUnixEpochTimeResponse) String() string { @@ -5637,7 +5404,7 @@ func (*SetRateUnixEpochTimeResponse) ProtoMessage() {} func (x *SetRateUnixEpochTimeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[116] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5669,11 +5436,9 @@ type SetRateDistanceSensorRequest struct { func (x *SetRateDistanceSensorRequest) Reset() { *x = SetRateDistanceSensorRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[117] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[117] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateDistanceSensorRequest) String() string { @@ -5684,7 +5449,7 @@ func (*SetRateDistanceSensorRequest) ProtoMessage() {} func (x *SetRateDistanceSensorRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[117] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5716,11 +5481,9 @@ type SetRateDistanceSensorResponse struct { func (x *SetRateDistanceSensorResponse) Reset() { *x = SetRateDistanceSensorResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[118] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[118] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateDistanceSensorResponse) String() string { @@ -5731,7 +5494,7 @@ func (*SetRateDistanceSensorResponse) ProtoMessage() {} func (x *SetRateDistanceSensorResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[118] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5761,11 +5524,9 @@ type GetGpsGlobalOriginRequest struct { func (x *GetGpsGlobalOriginRequest) Reset() { *x = GetGpsGlobalOriginRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[119] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[119] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetGpsGlobalOriginRequest) String() string { @@ -5776,7 +5537,7 @@ func (*GetGpsGlobalOriginRequest) ProtoMessage() {} func (x *GetGpsGlobalOriginRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[119] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5802,11 +5563,9 @@ type GetGpsGlobalOriginResponse struct { func (x *GetGpsGlobalOriginResponse) Reset() { *x = GetGpsGlobalOriginResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[120] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[120] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GetGpsGlobalOriginResponse) String() string { @@ -5817,7 +5576,7 @@ func (*GetGpsGlobalOriginResponse) ProtoMessage() {} func (x *GetGpsGlobalOriginResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[120] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5856,11 +5615,9 @@ type SetRateAltitudeRequest struct { func (x *SetRateAltitudeRequest) Reset() { *x = SetRateAltitudeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[121] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[121] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAltitudeRequest) String() string { @@ -5871,7 +5628,7 @@ func (*SetRateAltitudeRequest) ProtoMessage() {} func (x *SetRateAltitudeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[121] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5903,11 +5660,9 @@ type SetRateAltitudeResponse struct { func (x *SetRateAltitudeResponse) Reset() { *x = SetRateAltitudeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[122] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[122] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateAltitudeResponse) String() string { @@ -5918,7 +5673,7 @@ func (*SetRateAltitudeResponse) ProtoMessage() {} func (x *SetRateAltitudeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[122] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -5954,11 +5709,9 @@ type Position struct { func (x *Position) Reset() { *x = Position{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[123] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[123] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Position) String() string { @@ -5969,7 +5722,7 @@ func (*Position) ProtoMessage() {} func (x *Position) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[123] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6023,11 +5776,9 @@ type Heading struct { func (x *Heading) Reset() { *x = Heading{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[124] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[124] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Heading) String() string { @@ -6038,7 +5789,7 @@ func (*Heading) ProtoMessage() {} func (x *Heading) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[124] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6082,11 +5833,9 @@ type Quaternion struct { func (x *Quaternion) Reset() { *x = Quaternion{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[125] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[125] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Quaternion) String() string { @@ -6097,7 +5846,7 @@ func (*Quaternion) ProtoMessage() {} func (x *Quaternion) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[125] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6166,11 +5915,9 @@ type EulerAngle struct { func (x *EulerAngle) Reset() { *x = EulerAngle{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[126] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[126] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *EulerAngle) String() string { @@ -6181,7 +5928,7 @@ func (*EulerAngle) ProtoMessage() {} func (x *EulerAngle) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[126] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6237,11 +5984,9 @@ type AngularVelocityBody struct { func (x *AngularVelocityBody) Reset() { *x = AngularVelocityBody{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[127] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[127] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngularVelocityBody) String() string { @@ -6252,7 +5997,7 @@ func (*AngularVelocityBody) ProtoMessage() {} func (x *AngularVelocityBody) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[127] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6300,11 +6045,9 @@ type GpsInfo struct { func (x *GpsInfo) Reset() { *x = GpsInfo{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[128] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[128] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GpsInfo) String() string { @@ -6315,7 +6058,7 @@ func (*GpsInfo) ProtoMessage() {} func (x *GpsInfo) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[128] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6371,11 +6114,9 @@ type RawGps struct { func (x *RawGps) Reset() { *x = RawGps{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[129] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[129] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RawGps) String() string { @@ -6386,7 +6127,7 @@ func (*RawGps) ProtoMessage() {} func (x *RawGps) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[129] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6515,11 +6256,9 @@ type Battery struct { func (x *Battery) Reset() { *x = Battery{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[130] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[130] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Battery) String() string { @@ -6530,7 +6269,7 @@ func (*Battery) ProtoMessage() {} func (x *Battery) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[130] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6604,11 +6343,9 @@ type Health struct { func (x *Health) Reset() { *x = Health{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[131] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[131] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Health) String() string { @@ -6619,7 +6356,7 @@ func (*Health) ProtoMessage() {} func (x *Health) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[131] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6696,11 +6433,9 @@ type RcStatus struct { func (x *RcStatus) Reset() { *x = RcStatus{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[132] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[132] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RcStatus) String() string { @@ -6711,7 +6446,7 @@ func (*RcStatus) ProtoMessage() {} func (x *RcStatus) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[132] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6759,11 +6494,9 @@ type StatusText struct { func (x *StatusText) Reset() { *x = StatusText{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[133] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[133] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StatusText) String() string { @@ -6774,7 +6507,7 @@ func (*StatusText) ProtoMessage() {} func (x *StatusText) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[133] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6815,11 +6548,9 @@ type ActuatorControlTarget struct { func (x *ActuatorControlTarget) Reset() { *x = ActuatorControlTarget{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[134] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[134] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorControlTarget) String() string { @@ -6830,7 +6561,7 @@ func (*ActuatorControlTarget) ProtoMessage() {} func (x *ActuatorControlTarget) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[134] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6871,11 +6602,9 @@ type ActuatorOutputStatus struct { func (x *ActuatorOutputStatus) Reset() { *x = ActuatorOutputStatus{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[135] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[135] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorOutputStatus) String() string { @@ -6886,7 +6615,7 @@ func (*ActuatorOutputStatus) ProtoMessage() {} func (x *ActuatorOutputStatus) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[135] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6930,11 +6659,9 @@ type Covariance struct { func (x *Covariance) Reset() { *x = Covariance{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[136] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[136] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Covariance) String() string { @@ -6945,7 +6672,7 @@ func (*Covariance) ProtoMessage() {} func (x *Covariance) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[136] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -6980,11 +6707,9 @@ type VelocityBody struct { func (x *VelocityBody) Reset() { *x = VelocityBody{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[137] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[137] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityBody) String() string { @@ -6995,7 +6720,7 @@ func (*VelocityBody) ProtoMessage() {} func (x *VelocityBody) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[137] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7044,11 +6769,9 @@ type PositionBody struct { func (x *PositionBody) Reset() { *x = PositionBody{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[138] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[138] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionBody) String() string { @@ -7059,7 +6782,7 @@ func (*PositionBody) ProtoMessage() {} func (x *PositionBody) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[138] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7114,11 +6837,9 @@ type Odometry struct { func (x *Odometry) Reset() { *x = Odometry{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[139] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[139] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Odometry) String() string { @@ -7129,7 +6850,7 @@ func (*Odometry) ProtoMessage() {} func (x *Odometry) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[139] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7221,11 +6942,9 @@ type DistanceSensor struct { func (x *DistanceSensor) Reset() { *x = DistanceSensor{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[140] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[140] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DistanceSensor) String() string { @@ -7236,7 +6955,7 @@ func (*DistanceSensor) ProtoMessage() {} func (x *DistanceSensor) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[140] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7294,11 +7013,9 @@ type ScaledPressure struct { func (x *ScaledPressure) Reset() { *x = ScaledPressure{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[141] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[141] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ScaledPressure) String() string { @@ -7309,7 +7026,7 @@ func (*ScaledPressure) ProtoMessage() {} func (x *ScaledPressure) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[141] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7372,11 +7089,9 @@ type PositionNed struct { func (x *PositionNed) Reset() { *x = PositionNed{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[142] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[142] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionNed) String() string { @@ -7387,7 +7102,7 @@ func (*PositionNed) ProtoMessage() {} func (x *PositionNed) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[142] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7436,11 +7151,9 @@ type VelocityNed struct { func (x *VelocityNed) Reset() { *x = VelocityNed{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[143] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[143] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityNed) String() string { @@ -7451,7 +7164,7 @@ func (*VelocityNed) ProtoMessage() {} func (x *VelocityNed) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[143] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7499,11 +7212,9 @@ type PositionVelocityNed struct { func (x *PositionVelocityNed) Reset() { *x = PositionVelocityNed{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[144] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[144] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionVelocityNed) String() string { @@ -7514,7 +7225,7 @@ func (*PositionVelocityNed) ProtoMessage() {} func (x *PositionVelocityNed) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[144] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7556,11 +7267,9 @@ type GroundTruth struct { func (x *GroundTruth) Reset() { *x = GroundTruth{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[145] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[145] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GroundTruth) String() string { @@ -7571,7 +7280,7 @@ func (*GroundTruth) ProtoMessage() {} func (x *GroundTruth) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[145] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7620,11 +7329,9 @@ type FixedwingMetrics struct { func (x *FixedwingMetrics) Reset() { *x = FixedwingMetrics{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[146] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[146] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FixedwingMetrics) String() string { @@ -7635,7 +7342,7 @@ func (*FixedwingMetrics) ProtoMessage() {} func (x *FixedwingMetrics) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[146] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7684,11 +7391,9 @@ type AccelerationFrd struct { func (x *AccelerationFrd) Reset() { *x = AccelerationFrd{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[147] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[147] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AccelerationFrd) String() string { @@ -7699,7 +7404,7 @@ func (*AccelerationFrd) ProtoMessage() {} func (x *AccelerationFrd) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[147] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7748,11 +7453,9 @@ type AngularVelocityFrd struct { func (x *AngularVelocityFrd) Reset() { *x = AngularVelocityFrd{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[148] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[148] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngularVelocityFrd) String() string { @@ -7763,7 +7466,7 @@ func (*AngularVelocityFrd) ProtoMessage() {} func (x *AngularVelocityFrd) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[148] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7812,11 +7515,9 @@ type MagneticFieldFrd struct { func (x *MagneticFieldFrd) Reset() { *x = MagneticFieldFrd{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[149] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[149] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MagneticFieldFrd) String() string { @@ -7827,7 +7528,7 @@ func (*MagneticFieldFrd) ProtoMessage() {} func (x *MagneticFieldFrd) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[149] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7878,11 +7579,9 @@ type Imu struct { func (x *Imu) Reset() { *x = Imu{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[150] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[150] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Imu) String() string { @@ -7893,7 +7592,7 @@ func (*Imu) ProtoMessage() {} func (x *Imu) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[150] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -7956,11 +7655,9 @@ type GpsGlobalOrigin struct { func (x *GpsGlobalOrigin) Reset() { *x = GpsGlobalOrigin{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[151] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[151] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GpsGlobalOrigin) String() string { @@ -7971,7 +7668,7 @@ func (*GpsGlobalOrigin) ProtoMessage() {} func (x *GpsGlobalOrigin) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[151] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -8023,11 +7720,9 @@ type Altitude struct { func (x *Altitude) Reset() { *x = Altitude{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[152] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[152] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Altitude) String() string { @@ -8038,7 +7733,7 @@ func (*Altitude) ProtoMessage() {} func (x *Altitude) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[152] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -8107,11 +7802,9 @@ type TelemetryResult struct { func (x *TelemetryResult) Reset() { *x = TelemetryResult{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_proto_msgTypes[153] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_proto_msgTypes[153] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TelemetryResult) String() string { @@ -8122,7 +7815,7 @@ func (*TelemetryResult) ProtoMessage() {} func (x *TelemetryResult) ProtoReflect() protoreflect.Message { mi := &file_telemetry_proto_msgTypes[153] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -10013,1857 +9706,6 @@ func file_telemetry_proto_init() { if File_telemetry_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_telemetry_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribePositionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*PositionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeHomeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*HomeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeInAirRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*InAirResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeLandedStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*LandedStateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeArmedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*ArmedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeVtolStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*VtolStateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeAttitudeQuaternionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*AttitudeQuaternionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeAttitudeEulerRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*AttitudeEulerResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeAttitudeAngularVelocityBodyRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*AttitudeAngularVelocityBodyResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCameraAttitudeQuaternionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*CameraAttitudeQuaternionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeCameraAttitudeEulerRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*CameraAttitudeEulerResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*VelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeGpsInfoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*GpsInfoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeRawGpsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*RawGpsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeBatteryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*BatteryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeFlightModeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*FlightModeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeHealthRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*HealthResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[34].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeRcStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[35].Exporter = func(v any, i int) any { - switch v := v.(*RcStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[36].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStatusTextRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[37].Exporter = func(v any, i int) any { - switch v := v.(*StatusTextResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[38].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeActuatorControlTargetRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[39].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorControlTargetResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[40].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeActuatorOutputStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[41].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorOutputStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[42].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeOdometryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[43].Exporter = func(v any, i int) any { - switch v := v.(*OdometryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[44].Exporter = func(v any, i int) any { - switch v := v.(*SubscribePositionVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[45].Exporter = func(v any, i int) any { - switch v := v.(*PositionVelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[46].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeGroundTruthRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[47].Exporter = func(v any, i int) any { - switch v := v.(*GroundTruthResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[48].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeFixedwingMetricsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[49].Exporter = func(v any, i int) any { - switch v := v.(*FixedwingMetricsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[50].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[51].Exporter = func(v any, i int) any { - switch v := v.(*ImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[52].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeScaledImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[53].Exporter = func(v any, i int) any { - switch v := v.(*ScaledImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[54].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeRawImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[55].Exporter = func(v any, i int) any { - switch v := v.(*RawImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[56].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeHealthAllOkRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[57].Exporter = func(v any, i int) any { - switch v := v.(*HealthAllOkResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[58].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeUnixEpochTimeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[59].Exporter = func(v any, i int) any { - switch v := v.(*UnixEpochTimeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[60].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeDistanceSensorRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[61].Exporter = func(v any, i int) any { - switch v := v.(*DistanceSensorResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[62].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeScaledPressureRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[63].Exporter = func(v any, i int) any { - switch v := v.(*ScaledPressureResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[64].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeHeadingRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[65].Exporter = func(v any, i int) any { - switch v := v.(*HeadingResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[66].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeAltitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[67].Exporter = func(v any, i int) any { - switch v := v.(*AltitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[68].Exporter = func(v any, i int) any { - switch v := v.(*SetRatePositionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[69].Exporter = func(v any, i int) any { - switch v := v.(*SetRatePositionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[70].Exporter = func(v any, i int) any { - switch v := v.(*SetRateHomeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[71].Exporter = func(v any, i int) any { - switch v := v.(*SetRateHomeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[72].Exporter = func(v any, i int) any { - switch v := v.(*SetRateInAirRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[73].Exporter = func(v any, i int) any { - switch v := v.(*SetRateInAirResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[74].Exporter = func(v any, i int) any { - switch v := v.(*SetRateLandedStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[75].Exporter = func(v any, i int) any { - switch v := v.(*SetRateLandedStateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[76].Exporter = func(v any, i int) any { - switch v := v.(*SetRateVtolStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[77].Exporter = func(v any, i int) any { - switch v := v.(*SetRateVtolStateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[78].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAttitudeEulerRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[79].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAttitudeEulerResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[80].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAttitudeQuaternionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[81].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAttitudeQuaternionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[82].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAttitudeAngularVelocityBodyRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[83].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAttitudeAngularVelocityBodyResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[84].Exporter = func(v any, i int) any { - switch v := v.(*SetRateCameraAttitudeQuaternionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[85].Exporter = func(v any, i int) any { - switch v := v.(*SetRateCameraAttitudeQuaternionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[86].Exporter = func(v any, i int) any { - switch v := v.(*SetRateCameraAttitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[87].Exporter = func(v any, i int) any { - switch v := v.(*SetRateCameraAttitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[88].Exporter = func(v any, i int) any { - switch v := v.(*SetRateVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[89].Exporter = func(v any, i int) any { - switch v := v.(*SetRateVelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[90].Exporter = func(v any, i int) any { - switch v := v.(*SetRateGpsInfoRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[91].Exporter = func(v any, i int) any { - switch v := v.(*SetRateGpsInfoResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[92].Exporter = func(v any, i int) any { - switch v := v.(*SetRateRawGpsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[93].Exporter = func(v any, i int) any { - switch v := v.(*SetRateBatteryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[94].Exporter = func(v any, i int) any { - switch v := v.(*SetRateBatteryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[95].Exporter = func(v any, i int) any { - switch v := v.(*SetRateRcStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[96].Exporter = func(v any, i int) any { - switch v := v.(*SetRateRcStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[97].Exporter = func(v any, i int) any { - switch v := v.(*SetRateActuatorControlTargetRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[98].Exporter = func(v any, i int) any { - switch v := v.(*SetRateActuatorControlTargetResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[99].Exporter = func(v any, i int) any { - switch v := v.(*SetRateActuatorOutputStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[100].Exporter = func(v any, i int) any { - switch v := v.(*SetRateActuatorOutputStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[101].Exporter = func(v any, i int) any { - switch v := v.(*SetRateOdometryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[102].Exporter = func(v any, i int) any { - switch v := v.(*SetRateOdometryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[103].Exporter = func(v any, i int) any { - switch v := v.(*SetRatePositionVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[104].Exporter = func(v any, i int) any { - switch v := v.(*SetRatePositionVelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[105].Exporter = func(v any, i int) any { - switch v := v.(*SetRateGroundTruthRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[106].Exporter = func(v any, i int) any { - switch v := v.(*SetRateGroundTruthResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[107].Exporter = func(v any, i int) any { - switch v := v.(*SetRateFixedwingMetricsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[108].Exporter = func(v any, i int) any { - switch v := v.(*SetRateFixedwingMetricsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[109].Exporter = func(v any, i int) any { - switch v := v.(*SetRateImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[110].Exporter = func(v any, i int) any { - switch v := v.(*SetRateImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[111].Exporter = func(v any, i int) any { - switch v := v.(*SetRateScaledImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[112].Exporter = func(v any, i int) any { - switch v := v.(*SetRateScaledImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[113].Exporter = func(v any, i int) any { - switch v := v.(*SetRateRawImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[114].Exporter = func(v any, i int) any { - switch v := v.(*SetRateRawImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[115].Exporter = func(v any, i int) any { - switch v := v.(*SetRateUnixEpochTimeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[116].Exporter = func(v any, i int) any { - switch v := v.(*SetRateUnixEpochTimeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[117].Exporter = func(v any, i int) any { - switch v := v.(*SetRateDistanceSensorRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[118].Exporter = func(v any, i int) any { - switch v := v.(*SetRateDistanceSensorResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[119].Exporter = func(v any, i int) any { - switch v := v.(*GetGpsGlobalOriginRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[120].Exporter = func(v any, i int) any { - switch v := v.(*GetGpsGlobalOriginResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[121].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAltitudeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[122].Exporter = func(v any, i int) any { - switch v := v.(*SetRateAltitudeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[123].Exporter = func(v any, i int) any { - switch v := v.(*Position); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[124].Exporter = func(v any, i int) any { - switch v := v.(*Heading); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[125].Exporter = func(v any, i int) any { - switch v := v.(*Quaternion); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[126].Exporter = func(v any, i int) any { - switch v := v.(*EulerAngle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[127].Exporter = func(v any, i int) any { - switch v := v.(*AngularVelocityBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[128].Exporter = func(v any, i int) any { - switch v := v.(*GpsInfo); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[129].Exporter = func(v any, i int) any { - switch v := v.(*RawGps); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[130].Exporter = func(v any, i int) any { - switch v := v.(*Battery); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[131].Exporter = func(v any, i int) any { - switch v := v.(*Health); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[132].Exporter = func(v any, i int) any { - switch v := v.(*RcStatus); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[133].Exporter = func(v any, i int) any { - switch v := v.(*StatusText); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[134].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorControlTarget); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[135].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorOutputStatus); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[136].Exporter = func(v any, i int) any { - switch v := v.(*Covariance); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[137].Exporter = func(v any, i int) any { - switch v := v.(*VelocityBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[138].Exporter = func(v any, i int) any { - switch v := v.(*PositionBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[139].Exporter = func(v any, i int) any { - switch v := v.(*Odometry); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[140].Exporter = func(v any, i int) any { - switch v := v.(*DistanceSensor); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[141].Exporter = func(v any, i int) any { - switch v := v.(*ScaledPressure); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[142].Exporter = func(v any, i int) any { - switch v := v.(*PositionNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[143].Exporter = func(v any, i int) any { - switch v := v.(*VelocityNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[144].Exporter = func(v any, i int) any { - switch v := v.(*PositionVelocityNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[145].Exporter = func(v any, i int) any { - switch v := v.(*GroundTruth); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[146].Exporter = func(v any, i int) any { - switch v := v.(*FixedwingMetrics); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[147].Exporter = func(v any, i int) any { - switch v := v.(*AccelerationFrd); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[148].Exporter = func(v any, i int) any { - switch v := v.(*AngularVelocityFrd); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[149].Exporter = func(v any, i int) any { - switch v := v.(*MagneticFieldFrd); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[150].Exporter = func(v any, i int) any { - switch v := v.(*Imu); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[151].Exporter = func(v any, i int) any { - switch v := v.(*GpsGlobalOrigin); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[152].Exporter = func(v any, i int) any { - switch v := v.(*Altitude); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_proto_msgTypes[153].Exporter = func(v any, i int) any { - switch v := v.(*TelemetryResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/telemetry/telemetry_grpc.pb.go b/Sources/telemetry/telemetry_grpc.pb.go index fbd32da..4b6ce8b 100644 --- a/Sources/telemetry/telemetry_grpc.pb.go +++ b/Sources/telemetry/telemetry_grpc.pb.go @@ -8,6 +8,7 @@ package telemetry import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/telemetry_server/telemetry_server.go b/Sources/telemetry_server/telemetry_server.go index 48cab35..c54b74c 100644 --- a/Sources/telemetry_server/telemetry_server.go +++ b/Sources/telemetry_server/telemetry_server.go @@ -9,31 +9,24 @@ type ServiceImpl struct { } /* - Publish to 'position' updates. - - Parameters - ---------- - position *Position - - - velocityNed *VelocityNed - - - heading *Heading - - - +PublishPosition Publish to 'position' updates. */ +func (s *ServiceImpl) PublishPosition( + ctx context.Context, + position *Position, -func (s *ServiceImpl) PublishPosition(ctx context.Context, position *Position, velocityNed *VelocityNed, heading *Heading) (*PublishPositionResponse, error) { + velocityNed *VelocityNed, - request := &PublishPositionRequest{} - request.Position = position + heading *Heading, - request.VelocityNed = velocityNed +) (*PublishPositionResponse, error) { + request := &PublishPositionRequest{ + Position: position, - request.Heading = heading + VelocityNed: velocityNed, + Heading: heading, + } response, err := s.Client.PublishPosition(ctx, request) if err != nil { return nil, err @@ -42,21 +35,16 @@ func (s *ServiceImpl) PublishPosition(ctx context.Context, position *Position, v } /* - Publish to 'home position' updates. - - Parameters - ---------- - home *Position - - - +PublishHome Publish to 'home position' updates. */ +func (s *ServiceImpl) PublishHome( + ctx context.Context, + home *Position, -func (s *ServiceImpl) PublishHome(ctx context.Context, home *Position) (*PublishHomeResponse, error) { - - request := &PublishHomeRequest{} - request.Home = home - +) (*PublishHomeResponse, error) { + request := &PublishHomeRequest{ + Home: home, + } response, err := s.Client.PublishHome(ctx, request) if err != nil { return nil, err @@ -65,36 +53,28 @@ func (s *ServiceImpl) PublishHome(ctx context.Context, home *Position) (*Publish } /* - Publish 'sys status' updates. - - Parameters - ---------- - battery *Battery - - - rcReceiverStatus bool - - gyroStatus bool - - accelStatus bool - - magStatus bool - - gpsStatus bool - - +PublishSysStatus Publish 'sys status' updates. */ - -func (s *ServiceImpl) PublishSysStatus(ctx context.Context, battery *Battery, rcReceiverStatus bool, gyroStatus bool, accelStatus bool, magStatus bool, gpsStatus bool) (*PublishSysStatusResponse, error) { - - request := &PublishSysStatusRequest{} - request.Battery = battery - - request.RcReceiverStatus = rcReceiverStatus - request.GyroStatus = gyroStatus - request.AccelStatus = accelStatus - request.MagStatus = magStatus - request.GpsStatus = gpsStatus +func (s *ServiceImpl) PublishSysStatus( + ctx context.Context, + battery *Battery, + + rcReceiverStatus bool, + gyroStatus bool, + accelStatus bool, + magStatus bool, + gpsStatus bool, + +) (*PublishSysStatusResponse, error) { + request := &PublishSysStatusRequest{ + Battery: battery, + + RcReceiverStatus: rcReceiverStatus, + GyroStatus: gyroStatus, + AccelStatus: accelStatus, + MagStatus: magStatus, + GpsStatus: gpsStatus, + } response, err := s.Client.PublishSysStatus(ctx, request) if err != nil { return nil, err @@ -103,24 +83,19 @@ func (s *ServiceImpl) PublishSysStatus(ctx context.Context, battery *Battery, rc } /* - Publish 'extended sys state' updates. - - Parameters - ---------- - vtolState *VtolState - - - landedState *LandedState - - - +PublishExtendedSysState Publish 'extended sys state' updates. */ +func (s *ServiceImpl) PublishExtendedSysState( + ctx context.Context, + vtolState *VtolState, -func (s *ServiceImpl) PublishExtendedSysState(ctx context.Context, vtolState *VtolState, landedState *LandedState) (*PublishExtendedSysStateResponse, error) { + landedState *LandedState, - request := &PublishExtendedSysStateRequest{} - request.VtolState = *vtolState - request.LandedState = *landedState +) (*PublishExtendedSysStateResponse, error) { + request := &PublishExtendedSysStateRequest{ + VtolState: *vtolState, + LandedState: *landedState, + } response, err := s.Client.PublishExtendedSysState(ctx, request) if err != nil { return nil, err @@ -129,26 +104,20 @@ func (s *ServiceImpl) PublishExtendedSysState(ctx context.Context, vtolState *Vt } /* - Publish to 'Raw GPS' updates. - - Parameters - ---------- - rawGps *RawGps - - - gpsInfo *GpsInfo - - - +PublishRawGps Publish to 'Raw GPS' updates. */ +func (s *ServiceImpl) PublishRawGps( + ctx context.Context, + rawGps *RawGps, -func (s *ServiceImpl) PublishRawGps(ctx context.Context, rawGps *RawGps, gpsInfo *GpsInfo) (*PublishRawGpsResponse, error) { + gpsInfo *GpsInfo, - request := &PublishRawGpsRequest{} - request.RawGps = rawGps - - request.GpsInfo = gpsInfo +) (*PublishRawGpsResponse, error) { + request := &PublishRawGpsRequest{ + RawGps: rawGps, + GpsInfo: gpsInfo, + } response, err := s.Client.PublishRawGps(ctx, request) if err != nil { return nil, err @@ -157,21 +126,16 @@ func (s *ServiceImpl) PublishRawGps(ctx context.Context, rawGps *RawGps, gpsInfo } /* - Publish to 'battery' updates. - - Parameters - ---------- - battery *Battery - - - +PublishBattery Publish to 'battery' updates. */ +func (s *ServiceImpl) PublishBattery( + ctx context.Context, + battery *Battery, -func (s *ServiceImpl) PublishBattery(ctx context.Context, battery *Battery) (*PublishBatteryResponse, error) { - - request := &PublishBatteryRequest{} - request.Battery = battery - +) (*PublishBatteryResponse, error) { + request := &PublishBatteryRequest{ + Battery: battery, + } response, err := s.Client.PublishBattery(ctx, request) if err != nil { return nil, err @@ -180,21 +144,16 @@ func (s *ServiceImpl) PublishBattery(ctx context.Context, battery *Battery) (*Pu } /* - Publish to 'status text' updates. - - Parameters - ---------- - statusText *StatusText - - - +PublishStatusText Publish to 'status text' updates. */ +func (s *ServiceImpl) PublishStatusText( + ctx context.Context, + statusText *StatusText, -func (s *ServiceImpl) PublishStatusText(ctx context.Context, statusText *StatusText) (*PublishStatusTextResponse, error) { - - request := &PublishStatusTextRequest{} - request.StatusText = statusText - +) (*PublishStatusTextResponse, error) { + request := &PublishStatusTextRequest{ + StatusText: statusText, + } response, err := s.Client.PublishStatusText(ctx, request) if err != nil { return nil, err @@ -203,21 +162,16 @@ func (s *ServiceImpl) PublishStatusText(ctx context.Context, statusText *StatusT } /* - Publish to 'odometry' updates. - - Parameters - ---------- - odometry *Odometry - - - +PublishOdometry Publish to 'odometry' updates. */ +func (s *ServiceImpl) PublishOdometry( + ctx context.Context, + odometry *Odometry, -func (s *ServiceImpl) PublishOdometry(ctx context.Context, odometry *Odometry) (*PublishOdometryResponse, error) { - - request := &PublishOdometryRequest{} - request.Odometry = odometry - +) (*PublishOdometryResponse, error) { + request := &PublishOdometryRequest{ + Odometry: odometry, + } response, err := s.Client.PublishOdometry(ctx, request) if err != nil { return nil, err @@ -226,21 +180,16 @@ func (s *ServiceImpl) PublishOdometry(ctx context.Context, odometry *Odometry) ( } /* - Publish to 'position velocity' updates. - - Parameters - ---------- - positionVelocityNed *PositionVelocityNed - - - +PublishPositionVelocityNed Publish to 'position velocity' updates. */ +func (s *ServiceImpl) PublishPositionVelocityNed( + ctx context.Context, + positionVelocityNed *PositionVelocityNed, -func (s *ServiceImpl) PublishPositionVelocityNed(ctx context.Context, positionVelocityNed *PositionVelocityNed) (*PublishPositionVelocityNedResponse, error) { - - request := &PublishPositionVelocityNedRequest{} - request.PositionVelocityNed = positionVelocityNed - +) (*PublishPositionVelocityNedResponse, error) { + request := &PublishPositionVelocityNedRequest{ + PositionVelocityNed: positionVelocityNed, + } response, err := s.Client.PublishPositionVelocityNed(ctx, request) if err != nil { return nil, err @@ -249,21 +198,16 @@ func (s *ServiceImpl) PublishPositionVelocityNed(ctx context.Context, positionVe } /* - Publish to 'ground truth' updates. - - Parameters - ---------- - groundTruth *GroundTruth - - - +PublishGroundTruth Publish to 'ground truth' updates. */ +func (s *ServiceImpl) PublishGroundTruth( + ctx context.Context, + groundTruth *GroundTruth, -func (s *ServiceImpl) PublishGroundTruth(ctx context.Context, groundTruth *GroundTruth) (*PublishGroundTruthResponse, error) { - - request := &PublishGroundTruthRequest{} - request.GroundTruth = groundTruth - +) (*PublishGroundTruthResponse, error) { + request := &PublishGroundTruthRequest{ + GroundTruth: groundTruth, + } response, err := s.Client.PublishGroundTruth(ctx, request) if err != nil { return nil, err @@ -272,21 +216,16 @@ func (s *ServiceImpl) PublishGroundTruth(ctx context.Context, groundTruth *Groun } /* - Publish to 'IMU' updates (in SI units in NED body frame). - - Parameters - ---------- - imu *Imu - - - +PublishImu Publish to 'IMU' updates (in SI units in NED body frame). */ +func (s *ServiceImpl) PublishImu( + ctx context.Context, + imu *Imu, -func (s *ServiceImpl) PublishImu(ctx context.Context, imu *Imu) (*PublishImuResponse, error) { - - request := &PublishImuRequest{} - request.Imu = imu - +) (*PublishImuResponse, error) { + request := &PublishImuRequest{ + Imu: imu, + } response, err := s.Client.PublishImu(ctx, request) if err != nil { return nil, err @@ -295,21 +234,16 @@ func (s *ServiceImpl) PublishImu(ctx context.Context, imu *Imu) (*PublishImuResp } /* - Publish to 'Scaled IMU' updates. - - Parameters - ---------- - imu *Imu - - - +PublishScaledImu Publish to 'Scaled IMU' updates. */ +func (s *ServiceImpl) PublishScaledImu( + ctx context.Context, + imu *Imu, -func (s *ServiceImpl) PublishScaledImu(ctx context.Context, imu *Imu) (*PublishScaledImuResponse, error) { - - request := &PublishScaledImuRequest{} - request.Imu = imu - +) (*PublishScaledImuResponse, error) { + request := &PublishScaledImuRequest{ + Imu: imu, + } response, err := s.Client.PublishScaledImu(ctx, request) if err != nil { return nil, err @@ -318,21 +252,16 @@ func (s *ServiceImpl) PublishScaledImu(ctx context.Context, imu *Imu) (*PublishS } /* - Publish to 'Raw IMU' updates. - - Parameters - ---------- - imu *Imu - - - +PublishRawImu Publish to 'Raw IMU' updates. */ +func (s *ServiceImpl) PublishRawImu( + ctx context.Context, + imu *Imu, -func (s *ServiceImpl) PublishRawImu(ctx context.Context, imu *Imu) (*PublishRawImuResponse, error) { - - request := &PublishRawImuRequest{} - request.Imu = imu - +) (*PublishRawImuResponse, error) { + request := &PublishRawImuRequest{ + Imu: imu, + } response, err := s.Client.PublishRawImu(ctx, request) if err != nil { return nil, err @@ -341,19 +270,16 @@ func (s *ServiceImpl) PublishRawImu(ctx context.Context, imu *Imu) (*PublishRawI } /* - Publish to 'unix epoch time' updates. - - Parameters - ---------- - timeUs uint64 - - +PublishUnixEpochTime Publish to 'unix epoch time' updates. */ +func (s *ServiceImpl) PublishUnixEpochTime( + ctx context.Context, + timeUs uint64, -func (s *ServiceImpl) PublishUnixEpochTime(ctx context.Context, timeUs uint64) (*PublishUnixEpochTimeResponse, error) { - - request := &PublishUnixEpochTimeRequest{} - request.TimeUs = timeUs +) (*PublishUnixEpochTimeResponse, error) { + request := &PublishUnixEpochTimeRequest{ + TimeUs: timeUs, + } response, err := s.Client.PublishUnixEpochTime(ctx, request) if err != nil { return nil, err @@ -362,21 +288,16 @@ func (s *ServiceImpl) PublishUnixEpochTime(ctx context.Context, timeUs uint64) ( } /* - Publish to "distance sensor" updates. - - Parameters - ---------- - distanceSensor *DistanceSensor - - - +PublishDistanceSensor Publish to "distance sensor" updates. */ +func (s *ServiceImpl) PublishDistanceSensor( + ctx context.Context, + distanceSensor *DistanceSensor, -func (s *ServiceImpl) PublishDistanceSensor(ctx context.Context, distanceSensor *DistanceSensor) (*PublishDistanceSensorResponse, error) { - - request := &PublishDistanceSensorRequest{} - request.DistanceSensor = distanceSensor - +) (*PublishDistanceSensorResponse, error) { + request := &PublishDistanceSensorRequest{ + DistanceSensor: distanceSensor, + } response, err := s.Client.PublishDistanceSensor(ctx, request) if err != nil { return nil, err diff --git a/Sources/telemetry_server/telemetry_server.pb.go b/Sources/telemetry_server/telemetry_server.pb.go index afec7b0..2696f5d 100644 --- a/Sources/telemetry_server/telemetry_server.pb.go +++ b/Sources/telemetry_server/telemetry_server.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: telemetry_server.proto package telemetry_server import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -389,11 +390,9 @@ type PublishPositionRequest struct { func (x *PublishPositionRequest) Reset() { *x = PublishPositionRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishPositionRequest) String() string { @@ -404,7 +403,7 @@ func (*PublishPositionRequest) ProtoMessage() {} func (x *PublishPositionRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -450,11 +449,9 @@ type PublishHomeRequest struct { func (x *PublishHomeRequest) Reset() { *x = PublishHomeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishHomeRequest) String() string { @@ -465,7 +462,7 @@ func (*PublishHomeRequest) ProtoMessage() {} func (x *PublishHomeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -502,11 +499,9 @@ type PublishSysStatusRequest struct { func (x *PublishSysStatusRequest) Reset() { *x = PublishSysStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishSysStatusRequest) String() string { @@ -517,7 +512,7 @@ func (*PublishSysStatusRequest) ProtoMessage() {} func (x *PublishSysStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -585,11 +580,9 @@ type PublishExtendedSysStateRequest struct { func (x *PublishExtendedSysStateRequest) Reset() { *x = PublishExtendedSysStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishExtendedSysStateRequest) String() string { @@ -600,7 +593,7 @@ func (*PublishExtendedSysStateRequest) ProtoMessage() {} func (x *PublishExtendedSysStateRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -639,11 +632,9 @@ type PublishInAirRequest struct { func (x *PublishInAirRequest) Reset() { *x = PublishInAirRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishInAirRequest) String() string { @@ -654,7 +645,7 @@ func (*PublishInAirRequest) ProtoMessage() {} func (x *PublishInAirRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -686,11 +677,9 @@ type PublishLandedStateRequest struct { func (x *PublishLandedStateRequest) Reset() { *x = PublishLandedStateRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishLandedStateRequest) String() string { @@ -701,7 +690,7 @@ func (*PublishLandedStateRequest) ProtoMessage() {} func (x *PublishLandedStateRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -734,11 +723,9 @@ type PublishRawGpsRequest struct { func (x *PublishRawGpsRequest) Reset() { *x = PublishRawGpsRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishRawGpsRequest) String() string { @@ -749,7 +736,7 @@ func (*PublishRawGpsRequest) ProtoMessage() {} func (x *PublishRawGpsRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -788,11 +775,9 @@ type PublishBatteryRequest struct { func (x *PublishBatteryRequest) Reset() { *x = PublishBatteryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishBatteryRequest) String() string { @@ -803,7 +788,7 @@ func (*PublishBatteryRequest) ProtoMessage() {} func (x *PublishBatteryRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -835,11 +820,9 @@ type PublishRcStatusRequest struct { func (x *PublishRcStatusRequest) Reset() { *x = PublishRcStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishRcStatusRequest) String() string { @@ -850,7 +833,7 @@ func (*PublishRcStatusRequest) ProtoMessage() {} func (x *PublishRcStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -882,11 +865,9 @@ type PublishStatusTextRequest struct { func (x *PublishStatusTextRequest) Reset() { *x = PublishStatusTextRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishStatusTextRequest) String() string { @@ -897,7 +878,7 @@ func (*PublishStatusTextRequest) ProtoMessage() {} func (x *PublishStatusTextRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -929,11 +910,9 @@ type PublishOdometryRequest struct { func (x *PublishOdometryRequest) Reset() { *x = PublishOdometryRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishOdometryRequest) String() string { @@ -944,7 +923,7 @@ func (*PublishOdometryRequest) ProtoMessage() {} func (x *PublishOdometryRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -976,11 +955,9 @@ type PublishPositionVelocityNedRequest struct { func (x *PublishPositionVelocityNedRequest) Reset() { *x = PublishPositionVelocityNedRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishPositionVelocityNedRequest) String() string { @@ -991,7 +968,7 @@ func (*PublishPositionVelocityNedRequest) ProtoMessage() {} func (x *PublishPositionVelocityNedRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1023,11 +1000,9 @@ type PublishGroundTruthRequest struct { func (x *PublishGroundTruthRequest) Reset() { *x = PublishGroundTruthRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishGroundTruthRequest) String() string { @@ -1038,7 +1013,7 @@ func (*PublishGroundTruthRequest) ProtoMessage() {} func (x *PublishGroundTruthRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1070,11 +1045,9 @@ type PublishImuRequest struct { func (x *PublishImuRequest) Reset() { *x = PublishImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishImuRequest) String() string { @@ -1085,7 +1058,7 @@ func (*PublishImuRequest) ProtoMessage() {} func (x *PublishImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1117,11 +1090,9 @@ type PublishScaledImuRequest struct { func (x *PublishScaledImuRequest) Reset() { *x = PublishScaledImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishScaledImuRequest) String() string { @@ -1132,7 +1103,7 @@ func (*PublishScaledImuRequest) ProtoMessage() {} func (x *PublishScaledImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1164,11 +1135,9 @@ type PublishRawImuRequest struct { func (x *PublishRawImuRequest) Reset() { *x = PublishRawImuRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishRawImuRequest) String() string { @@ -1179,7 +1148,7 @@ func (*PublishRawImuRequest) ProtoMessage() {} func (x *PublishRawImuRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1211,11 +1180,9 @@ type PublishUnixEpochTimeRequest struct { func (x *PublishUnixEpochTimeRequest) Reset() { *x = PublishUnixEpochTimeRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishUnixEpochTimeRequest) String() string { @@ -1226,7 +1193,7 @@ func (*PublishUnixEpochTimeRequest) ProtoMessage() {} func (x *PublishUnixEpochTimeRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1258,11 +1225,9 @@ type PublishDistanceSensorRequest struct { func (x *PublishDistanceSensorRequest) Reset() { *x = PublishDistanceSensorRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishDistanceSensorRequest) String() string { @@ -1273,7 +1238,7 @@ func (*PublishDistanceSensorRequest) ProtoMessage() {} func (x *PublishDistanceSensorRequest) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1305,11 +1270,9 @@ type PublishPositionResponse struct { func (x *PublishPositionResponse) Reset() { *x = PublishPositionResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishPositionResponse) String() string { @@ -1320,7 +1283,7 @@ func (*PublishPositionResponse) ProtoMessage() {} func (x *PublishPositionResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1352,11 +1315,9 @@ type PublishHomeResponse struct { func (x *PublishHomeResponse) Reset() { *x = PublishHomeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishHomeResponse) String() string { @@ -1367,7 +1328,7 @@ func (*PublishHomeResponse) ProtoMessage() {} func (x *PublishHomeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1399,11 +1360,9 @@ type PublishSysStatusResponse struct { func (x *PublishSysStatusResponse) Reset() { *x = PublishSysStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishSysStatusResponse) String() string { @@ -1414,7 +1373,7 @@ func (*PublishSysStatusResponse) ProtoMessage() {} func (x *PublishSysStatusResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1446,11 +1405,9 @@ type PublishExtendedSysStateResponse struct { func (x *PublishExtendedSysStateResponse) Reset() { *x = PublishExtendedSysStateResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishExtendedSysStateResponse) String() string { @@ -1461,7 +1418,7 @@ func (*PublishExtendedSysStateResponse) ProtoMessage() {} func (x *PublishExtendedSysStateResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1493,11 +1450,9 @@ type PublishRawGpsResponse struct { func (x *PublishRawGpsResponse) Reset() { *x = PublishRawGpsResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishRawGpsResponse) String() string { @@ -1508,7 +1463,7 @@ func (*PublishRawGpsResponse) ProtoMessage() {} func (x *PublishRawGpsResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1540,11 +1495,9 @@ type PublishBatteryResponse struct { func (x *PublishBatteryResponse) Reset() { *x = PublishBatteryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishBatteryResponse) String() string { @@ -1555,7 +1508,7 @@ func (*PublishBatteryResponse) ProtoMessage() {} func (x *PublishBatteryResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1587,11 +1540,9 @@ type PublishStatusTextResponse struct { func (x *PublishStatusTextResponse) Reset() { *x = PublishStatusTextResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishStatusTextResponse) String() string { @@ -1602,7 +1553,7 @@ func (*PublishStatusTextResponse) ProtoMessage() {} func (x *PublishStatusTextResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1634,11 +1585,9 @@ type PublishOdometryResponse struct { func (x *PublishOdometryResponse) Reset() { *x = PublishOdometryResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[25] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[25] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishOdometryResponse) String() string { @@ -1649,7 +1598,7 @@ func (*PublishOdometryResponse) ProtoMessage() {} func (x *PublishOdometryResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[25] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1681,11 +1630,9 @@ type PublishPositionVelocityNedResponse struct { func (x *PublishPositionVelocityNedResponse) Reset() { *x = PublishPositionVelocityNedResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[26] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[26] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishPositionVelocityNedResponse) String() string { @@ -1696,7 +1643,7 @@ func (*PublishPositionVelocityNedResponse) ProtoMessage() {} func (x *PublishPositionVelocityNedResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[26] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1728,11 +1675,9 @@ type PublishGroundTruthResponse struct { func (x *PublishGroundTruthResponse) Reset() { *x = PublishGroundTruthResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[27] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[27] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishGroundTruthResponse) String() string { @@ -1743,7 +1688,7 @@ func (*PublishGroundTruthResponse) ProtoMessage() {} func (x *PublishGroundTruthResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[27] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1775,11 +1720,9 @@ type PublishImuResponse struct { func (x *PublishImuResponse) Reset() { *x = PublishImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[28] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[28] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishImuResponse) String() string { @@ -1790,7 +1733,7 @@ func (*PublishImuResponse) ProtoMessage() {} func (x *PublishImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[28] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1822,11 +1765,9 @@ type PublishScaledImuResponse struct { func (x *PublishScaledImuResponse) Reset() { *x = PublishScaledImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[29] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[29] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishScaledImuResponse) String() string { @@ -1837,7 +1778,7 @@ func (*PublishScaledImuResponse) ProtoMessage() {} func (x *PublishScaledImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[29] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1869,11 +1810,9 @@ type PublishRawImuResponse struct { func (x *PublishRawImuResponse) Reset() { *x = PublishRawImuResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[30] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[30] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishRawImuResponse) String() string { @@ -1884,7 +1823,7 @@ func (*PublishRawImuResponse) ProtoMessage() {} func (x *PublishRawImuResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[30] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1916,11 +1855,9 @@ type PublishUnixEpochTimeResponse struct { func (x *PublishUnixEpochTimeResponse) Reset() { *x = PublishUnixEpochTimeResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[31] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[31] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishUnixEpochTimeResponse) String() string { @@ -1931,7 +1868,7 @@ func (*PublishUnixEpochTimeResponse) ProtoMessage() {} func (x *PublishUnixEpochTimeResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[31] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1963,11 +1900,9 @@ type PublishDistanceSensorResponse struct { func (x *PublishDistanceSensorResponse) Reset() { *x = PublishDistanceSensorResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[32] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[32] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PublishDistanceSensorResponse) String() string { @@ -1978,7 +1913,7 @@ func (*PublishDistanceSensorResponse) ProtoMessage() {} func (x *PublishDistanceSensorResponse) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[32] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2014,11 +1949,9 @@ type Position struct { func (x *Position) Reset() { *x = Position{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[33] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[33] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Position) String() string { @@ -2029,7 +1962,7 @@ func (*Position) ProtoMessage() {} func (x *Position) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[33] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2083,11 +2016,9 @@ type Heading struct { func (x *Heading) Reset() { *x = Heading{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[34] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[34] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Heading) String() string { @@ -2098,7 +2029,7 @@ func (*Heading) ProtoMessage() {} func (x *Heading) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[34] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2142,11 +2073,9 @@ type Quaternion struct { func (x *Quaternion) Reset() { *x = Quaternion{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[35] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[35] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Quaternion) String() string { @@ -2157,7 +2086,7 @@ func (*Quaternion) ProtoMessage() {} func (x *Quaternion) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[35] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2226,11 +2155,9 @@ type EulerAngle struct { func (x *EulerAngle) Reset() { *x = EulerAngle{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[36] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[36] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *EulerAngle) String() string { @@ -2241,7 +2168,7 @@ func (*EulerAngle) ProtoMessage() {} func (x *EulerAngle) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[36] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2297,11 +2224,9 @@ type AngularVelocityBody struct { func (x *AngularVelocityBody) Reset() { *x = AngularVelocityBody{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[37] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[37] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngularVelocityBody) String() string { @@ -2312,7 +2237,7 @@ func (*AngularVelocityBody) ProtoMessage() {} func (x *AngularVelocityBody) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[37] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2360,11 +2285,9 @@ type GpsInfo struct { func (x *GpsInfo) Reset() { *x = GpsInfo{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[38] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[38] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GpsInfo) String() string { @@ -2375,7 +2298,7 @@ func (*GpsInfo) ProtoMessage() {} func (x *GpsInfo) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[38] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2431,11 +2354,9 @@ type RawGps struct { func (x *RawGps) Reset() { *x = RawGps{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[39] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[39] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RawGps) String() string { @@ -2446,7 +2367,7 @@ func (*RawGps) ProtoMessage() {} func (x *RawGps) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[39] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2571,11 +2492,9 @@ type Battery struct { func (x *Battery) Reset() { *x = Battery{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[40] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[40] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Battery) String() string { @@ -2586,7 +2505,7 @@ func (*Battery) ProtoMessage() {} func (x *Battery) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[40] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2628,11 +2547,9 @@ type RcStatus struct { func (x *RcStatus) Reset() { *x = RcStatus{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[41] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[41] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RcStatus) String() string { @@ -2643,7 +2560,7 @@ func (*RcStatus) ProtoMessage() {} func (x *RcStatus) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[41] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2691,11 +2608,9 @@ type StatusText struct { func (x *StatusText) Reset() { *x = StatusText{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[42] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[42] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StatusText) String() string { @@ -2706,7 +2621,7 @@ func (*StatusText) ProtoMessage() {} func (x *StatusText) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[42] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2747,11 +2662,9 @@ type ActuatorControlTarget struct { func (x *ActuatorControlTarget) Reset() { *x = ActuatorControlTarget{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[43] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[43] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorControlTarget) String() string { @@ -2762,7 +2675,7 @@ func (*ActuatorControlTarget) ProtoMessage() {} func (x *ActuatorControlTarget) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[43] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2803,11 +2716,9 @@ type ActuatorOutputStatus struct { func (x *ActuatorOutputStatus) Reset() { *x = ActuatorOutputStatus{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[44] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[44] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ActuatorOutputStatus) String() string { @@ -2818,7 +2729,7 @@ func (*ActuatorOutputStatus) ProtoMessage() {} func (x *ActuatorOutputStatus) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[44] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2862,11 +2773,9 @@ type Covariance struct { func (x *Covariance) Reset() { *x = Covariance{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[45] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[45] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Covariance) String() string { @@ -2877,7 +2786,7 @@ func (*Covariance) ProtoMessage() {} func (x *Covariance) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[45] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2912,11 +2821,9 @@ type VelocityBody struct { func (x *VelocityBody) Reset() { *x = VelocityBody{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[46] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[46] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityBody) String() string { @@ -2927,7 +2834,7 @@ func (*VelocityBody) ProtoMessage() {} func (x *VelocityBody) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[46] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -2976,11 +2883,9 @@ type PositionBody struct { func (x *PositionBody) Reset() { *x = PositionBody{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[47] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[47] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionBody) String() string { @@ -2991,7 +2896,7 @@ func (*PositionBody) ProtoMessage() {} func (x *PositionBody) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[47] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3046,11 +2951,9 @@ type Odometry struct { func (x *Odometry) Reset() { *x = Odometry{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[48] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[48] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Odometry) String() string { @@ -3061,7 +2964,7 @@ func (*Odometry) ProtoMessage() {} func (x *Odometry) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[48] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3152,11 +3055,9 @@ type DistanceSensor struct { func (x *DistanceSensor) Reset() { *x = DistanceSensor{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[49] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[49] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DistanceSensor) String() string { @@ -3167,7 +3068,7 @@ func (*DistanceSensor) ProtoMessage() {} func (x *DistanceSensor) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[49] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3218,11 +3119,9 @@ type ScaledPressure struct { func (x *ScaledPressure) Reset() { *x = ScaledPressure{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[50] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[50] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *ScaledPressure) String() string { @@ -3233,7 +3132,7 @@ func (*ScaledPressure) ProtoMessage() {} func (x *ScaledPressure) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[50] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3296,11 +3195,9 @@ type PositionNed struct { func (x *PositionNed) Reset() { *x = PositionNed{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[51] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[51] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionNed) String() string { @@ -3311,7 +3208,7 @@ func (*PositionNed) ProtoMessage() {} func (x *PositionNed) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[51] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3360,11 +3257,9 @@ type VelocityNed struct { func (x *VelocityNed) Reset() { *x = VelocityNed{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[52] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[52] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *VelocityNed) String() string { @@ -3375,7 +3270,7 @@ func (*VelocityNed) ProtoMessage() {} func (x *VelocityNed) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[52] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3423,11 +3318,9 @@ type PositionVelocityNed struct { func (x *PositionVelocityNed) Reset() { *x = PositionVelocityNed{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[53] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[53] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PositionVelocityNed) String() string { @@ -3438,7 +3331,7 @@ func (*PositionVelocityNed) ProtoMessage() {} func (x *PositionVelocityNed) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[53] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3480,11 +3373,9 @@ type GroundTruth struct { func (x *GroundTruth) Reset() { *x = GroundTruth{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[54] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[54] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *GroundTruth) String() string { @@ -3495,7 +3386,7 @@ func (*GroundTruth) ProtoMessage() {} func (x *GroundTruth) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[54] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3544,11 +3435,9 @@ type FixedwingMetrics struct { func (x *FixedwingMetrics) Reset() { *x = FixedwingMetrics{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[55] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[55] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *FixedwingMetrics) String() string { @@ -3559,7 +3448,7 @@ func (*FixedwingMetrics) ProtoMessage() {} func (x *FixedwingMetrics) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[55] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3608,11 +3497,9 @@ type AccelerationFrd struct { func (x *AccelerationFrd) Reset() { *x = AccelerationFrd{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[56] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[56] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AccelerationFrd) String() string { @@ -3623,7 +3510,7 @@ func (*AccelerationFrd) ProtoMessage() {} func (x *AccelerationFrd) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[56] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3672,11 +3559,9 @@ type AngularVelocityFrd struct { func (x *AngularVelocityFrd) Reset() { *x = AngularVelocityFrd{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[57] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[57] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AngularVelocityFrd) String() string { @@ -3687,7 +3572,7 @@ func (*AngularVelocityFrd) ProtoMessage() {} func (x *AngularVelocityFrd) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[57] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3736,11 +3621,9 @@ type MagneticFieldFrd struct { func (x *MagneticFieldFrd) Reset() { *x = MagneticFieldFrd{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[58] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[58] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *MagneticFieldFrd) String() string { @@ -3751,7 +3634,7 @@ func (*MagneticFieldFrd) ProtoMessage() {} func (x *MagneticFieldFrd) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[58] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3802,11 +3685,9 @@ type Imu struct { func (x *Imu) Reset() { *x = Imu{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[59] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[59] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Imu) String() string { @@ -3817,7 +3698,7 @@ func (*Imu) ProtoMessage() {} func (x *Imu) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[59] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -3879,11 +3760,9 @@ type TelemetryServerResult struct { func (x *TelemetryServerResult) Reset() { *x = TelemetryServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_telemetry_server_proto_msgTypes[60] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_telemetry_server_proto_msgTypes[60] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TelemetryServerResult) String() string { @@ -3894,7 +3773,7 @@ func (*TelemetryServerResult) ProtoMessage() {} func (x *TelemetryServerResult) ProtoReflect() protoreflect.Message { mi := &file_telemetry_server_proto_msgTypes[60] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -4878,741 +4757,6 @@ func file_telemetry_server_proto_init() { if File_telemetry_server_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_telemetry_server_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*PublishPositionRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*PublishHomeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*PublishSysStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*PublishExtendedSysStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*PublishInAirRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*PublishLandedStateRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*PublishRawGpsRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*PublishBatteryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*PublishRcStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*PublishStatusTextRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*PublishOdometryRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*PublishPositionVelocityNedRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*PublishGroundTruthRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*PublishImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*PublishScaledImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*PublishRawImuRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*PublishUnixEpochTimeRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*PublishDistanceSensorRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*PublishPositionResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*PublishHomeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*PublishSysStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*PublishExtendedSysStateResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*PublishRawGpsResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*PublishBatteryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*PublishStatusTextResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[25].Exporter = func(v any, i int) any { - switch v := v.(*PublishOdometryResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[26].Exporter = func(v any, i int) any { - switch v := v.(*PublishPositionVelocityNedResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[27].Exporter = func(v any, i int) any { - switch v := v.(*PublishGroundTruthResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[28].Exporter = func(v any, i int) any { - switch v := v.(*PublishImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[29].Exporter = func(v any, i int) any { - switch v := v.(*PublishScaledImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[30].Exporter = func(v any, i int) any { - switch v := v.(*PublishRawImuResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[31].Exporter = func(v any, i int) any { - switch v := v.(*PublishUnixEpochTimeResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[32].Exporter = func(v any, i int) any { - switch v := v.(*PublishDistanceSensorResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[33].Exporter = func(v any, i int) any { - switch v := v.(*Position); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[34].Exporter = func(v any, i int) any { - switch v := v.(*Heading); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[35].Exporter = func(v any, i int) any { - switch v := v.(*Quaternion); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[36].Exporter = func(v any, i int) any { - switch v := v.(*EulerAngle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[37].Exporter = func(v any, i int) any { - switch v := v.(*AngularVelocityBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[38].Exporter = func(v any, i int) any { - switch v := v.(*GpsInfo); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[39].Exporter = func(v any, i int) any { - switch v := v.(*RawGps); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[40].Exporter = func(v any, i int) any { - switch v := v.(*Battery); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[41].Exporter = func(v any, i int) any { - switch v := v.(*RcStatus); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[42].Exporter = func(v any, i int) any { - switch v := v.(*StatusText); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[43].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorControlTarget); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[44].Exporter = func(v any, i int) any { - switch v := v.(*ActuatorOutputStatus); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[45].Exporter = func(v any, i int) any { - switch v := v.(*Covariance); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[46].Exporter = func(v any, i int) any { - switch v := v.(*VelocityBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[47].Exporter = func(v any, i int) any { - switch v := v.(*PositionBody); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[48].Exporter = func(v any, i int) any { - switch v := v.(*Odometry); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[49].Exporter = func(v any, i int) any { - switch v := v.(*DistanceSensor); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[50].Exporter = func(v any, i int) any { - switch v := v.(*ScaledPressure); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[51].Exporter = func(v any, i int) any { - switch v := v.(*PositionNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[52].Exporter = func(v any, i int) any { - switch v := v.(*VelocityNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[53].Exporter = func(v any, i int) any { - switch v := v.(*PositionVelocityNed); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[54].Exporter = func(v any, i int) any { - switch v := v.(*GroundTruth); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[55].Exporter = func(v any, i int) any { - switch v := v.(*FixedwingMetrics); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[56].Exporter = func(v any, i int) any { - switch v := v.(*AccelerationFrd); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[57].Exporter = func(v any, i int) any { - switch v := v.(*AngularVelocityFrd); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[58].Exporter = func(v any, i int) any { - switch v := v.(*MagneticFieldFrd); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[59].Exporter = func(v any, i int) any { - switch v := v.(*Imu); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_telemetry_server_proto_msgTypes[60].Exporter = func(v any, i int) any { - switch v := v.(*TelemetryServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/telemetry_server/telemetry_server_grpc.pb.go b/Sources/telemetry_server/telemetry_server_grpc.pb.go index 953bf39..cb51062 100644 --- a/Sources/telemetry_server/telemetry_server_grpc.pb.go +++ b/Sources/telemetry_server/telemetry_server_grpc.pb.go @@ -8,6 +8,7 @@ package telemetry_server import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/tracking_server/tracking_server.go b/Sources/tracking_server/tracking_server.go deleted file mode 100644 index e63b324..0000000 --- a/Sources/tracking_server/tracking_server.go +++ /dev/null @@ -1,232 +0,0 @@ -package tracking_server - -import ( - "context" - "fmt" - "io" -) - -type ServiceImpl struct { - Client TrackingServerServiceClient -} - -/* - Set/update the current point tracking status. - - Parameters - ---------- - trackedPoint *TrackPoint - - - -*/ - -func (s *ServiceImpl) SetTrackingPointStatus(ctx context.Context, trackedPoint *TrackPoint) (*SetTrackingPointStatusResponse, error) { - - request := &SetTrackingPointStatusRequest{} - request.TrackedPoint = trackedPoint - - response, err := s.Client.SetTrackingPointStatus(ctx, request) - if err != nil { - return nil, err - } - return response, nil -} - -/* - Set/update the current rectangle tracking status. - - Parameters - ---------- - trackedRectangle *TrackRectangle - - - -*/ - -func (s *ServiceImpl) SetTrackingRectangleStatus(ctx context.Context, trackedRectangle *TrackRectangle) (*SetTrackingRectangleStatusResponse, error) { - - request := &SetTrackingRectangleStatusRequest{} - request.TrackedRectangle = trackedRectangle - - response, err := s.Client.SetTrackingRectangleStatus(ctx, request) - if err != nil { - return nil, err - } - return response, nil -} - -/* - Set the current tracking status to off. - - -*/ - -func (s *ServiceImpl) SetTrackingOffStatus(ctx context.Context) (*SetTrackingOffStatusResponse, error) { - - request := &SetTrackingOffStatusRequest{} - response, err := s.Client.SetTrackingOffStatus(ctx, request) - if err != nil { - return nil, err - } - return response, nil -} - -/* - Subscribe to incoming tracking point command. - - -*/ - -func (a *ServiceImpl) TrackingPointCommand(ctx context.Context) (<-chan *TrackPoint, error) { - ch := make(chan *TrackPoint) - request := &SubscribeTrackingPointCommandRequest{} - stream, err := a.Client.SubscribeTrackingPointCommand(ctx, request) - if err != nil { - return nil, err - } - go func() { - defer close(ch) - for { - m := &TrackingPointCommandResponse{} - err := stream.RecvMsg(m) - if err == io.EOF { - break - } - if err != nil { - fmt.Printf("Unable to receive message %v", err) - break - } - ch <- m.GetTrackPoint() - } - }() - return ch, nil -} - -/* - Subscribe to incoming tracking rectangle command. - - -*/ - -func (a *ServiceImpl) TrackingRectangleCommand(ctx context.Context) (<-chan *TrackRectangle, error) { - ch := make(chan *TrackRectangle) - request := &SubscribeTrackingRectangleCommandRequest{} - stream, err := a.Client.SubscribeTrackingRectangleCommand(ctx, request) - if err != nil { - return nil, err - } - go func() { - defer close(ch) - for { - m := &TrackingRectangleCommandResponse{} - err := stream.RecvMsg(m) - if err == io.EOF { - break - } - if err != nil { - fmt.Printf("Unable to receive message %v", err) - break - } - ch <- m.GetTrackRectangle() - } - }() - return ch, nil -} - -/* - Subscribe to incoming tracking off command. - - -*/ - -func (a *ServiceImpl) TrackingOffCommand(ctx context.Context) (<-chan int32, error) { - ch := make(chan int32) - request := &SubscribeTrackingOffCommandRequest{} - stream, err := a.Client.SubscribeTrackingOffCommand(ctx, request) - if err != nil { - return nil, err - } - go func() { - defer close(ch) - for { - m := &TrackingOffCommandResponse{} - err := stream.RecvMsg(m) - if err == io.EOF { - break - } - if err != nil { - fmt.Printf("Unable to receive message %v", err) - break - } - ch <- m.GetDummy() - } - }() - return ch, nil -} - -/* - Respond to an incoming tracking point command. - - Parameters - ---------- - commandAnswer *CommandAnswer - - - -*/ - -func (s *ServiceImpl) RespondTrackingPointCommand(ctx context.Context, commandAnswer *CommandAnswer) (*RespondTrackingPointCommandResponse, error) { - - request := &RespondTrackingPointCommandRequest{} - request.CommandAnswer = *commandAnswer - response, err := s.Client.RespondTrackingPointCommand(ctx, request) - if err != nil { - return nil, err - } - return response, nil -} - -/* - Respond to an incoming tracking rectangle command. - - Parameters - ---------- - commandAnswer *CommandAnswer - - - -*/ - -func (s *ServiceImpl) RespondTrackingRectangleCommand(ctx context.Context, commandAnswer *CommandAnswer) (*RespondTrackingRectangleCommandResponse, error) { - - request := &RespondTrackingRectangleCommandRequest{} - request.CommandAnswer = *commandAnswer - response, err := s.Client.RespondTrackingRectangleCommand(ctx, request) - if err != nil { - return nil, err - } - return response, nil -} - -/* - Respond to an incoming tracking off command. - - Parameters - ---------- - commandAnswer *CommandAnswer - - - -*/ - -func (s *ServiceImpl) RespondTrackingOffCommand(ctx context.Context, commandAnswer *CommandAnswer) (*RespondTrackingOffCommandResponse, error) { - - request := &RespondTrackingOffCommandRequest{} - request.CommandAnswer = *commandAnswer - response, err := s.Client.RespondTrackingOffCommand(ctx, request) - if err != nil { - return nil, err - } - return response, nil -} diff --git a/Sources/tracking_server/tracking_server.pb.go b/Sources/tracking_server/tracking_server.pb.go deleted file mode 100644 index 468b9a4..0000000 --- a/Sources/tracking_server/tracking_server.pb.go +++ /dev/null @@ -1,1710 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.31.0 -// protoc v3.12.4 -// source: tracking_server.proto - -package tracking_server - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - reflect "reflect" - sync "sync" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -// Answer to respond to an incoming command -type CommandAnswer int32 - -const ( - CommandAnswer_COMMAND_ANSWER_ACCEPTED CommandAnswer = 0 // Command accepted - CommandAnswer_COMMAND_ANSWER_TEMPORARILY_REJECTED CommandAnswer = 1 // Command temporarily rejected - CommandAnswer_COMMAND_ANSWER_DENIED CommandAnswer = 2 // Command denied - CommandAnswer_COMMAND_ANSWER_UNSUPPORTED CommandAnswer = 3 // Command unsupported - CommandAnswer_COMMAND_ANSWER_FAILED CommandAnswer = 4 // Command failed -) - -// Enum value maps for CommandAnswer. -var ( - CommandAnswer_name = map[int32]string{ - 0: "COMMAND_ANSWER_ACCEPTED", - 1: "COMMAND_ANSWER_TEMPORARILY_REJECTED", - 2: "COMMAND_ANSWER_DENIED", - 3: "COMMAND_ANSWER_UNSUPPORTED", - 4: "COMMAND_ANSWER_FAILED", - } - CommandAnswer_value = map[string]int32{ - "COMMAND_ANSWER_ACCEPTED": 0, - "COMMAND_ANSWER_TEMPORARILY_REJECTED": 1, - "COMMAND_ANSWER_DENIED": 2, - "COMMAND_ANSWER_UNSUPPORTED": 3, - "COMMAND_ANSWER_FAILED": 4, - } -) - -func (x CommandAnswer) Enum() *CommandAnswer { - p := new(CommandAnswer) - *p = x - return p -} - -func (x CommandAnswer) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (CommandAnswer) Descriptor() protoreflect.EnumDescriptor { - return file_tracking_server_proto_enumTypes[0].Descriptor() -} - -func (CommandAnswer) Type() protoreflect.EnumType { - return &file_tracking_server_proto_enumTypes[0] -} - -func (x CommandAnswer) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use CommandAnswer.Descriptor instead. -func (CommandAnswer) EnumDescriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{0} -} - -// Possible results returned for tracking_server requests. -type TrackingServerResult_Result int32 - -const ( - TrackingServerResult_RESULT_UNKNOWN TrackingServerResult_Result = 0 // Unknown result - TrackingServerResult_RESULT_SUCCESS TrackingServerResult_Result = 1 // Request succeeded - TrackingServerResult_RESULT_NO_SYSTEM TrackingServerResult_Result = 2 // No system is connected - TrackingServerResult_RESULT_CONNECTION_ERROR TrackingServerResult_Result = 3 // Connection error -) - -// Enum value maps for TrackingServerResult_Result. -var ( - TrackingServerResult_Result_name = map[int32]string{ - 0: "RESULT_UNKNOWN", - 1: "RESULT_SUCCESS", - 2: "RESULT_NO_SYSTEM", - 3: "RESULT_CONNECTION_ERROR", - } - TrackingServerResult_Result_value = map[string]int32{ - "RESULT_UNKNOWN": 0, - "RESULT_SUCCESS": 1, - "RESULT_NO_SYSTEM": 2, - "RESULT_CONNECTION_ERROR": 3, - } -) - -func (x TrackingServerResult_Result) Enum() *TrackingServerResult_Result { - p := new(TrackingServerResult_Result) - *p = x - return p -} - -func (x TrackingServerResult_Result) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (TrackingServerResult_Result) Descriptor() protoreflect.EnumDescriptor { - return file_tracking_server_proto_enumTypes[1].Descriptor() -} - -func (TrackingServerResult_Result) Type() protoreflect.EnumType { - return &file_tracking_server_proto_enumTypes[1] -} - -func (x TrackingServerResult_Result) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use TrackingServerResult_Result.Descriptor instead. -func (TrackingServerResult_Result) EnumDescriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{20, 0} -} - -type SetTrackingPointStatusRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackedPoint *TrackPoint `protobuf:"bytes,1,opt,name=tracked_point,json=trackedPoint,proto3" json:"tracked_point,omitempty"` // The tracked point -} - -func (x *SetTrackingPointStatusRequest) Reset() { - *x = SetTrackingPointStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetTrackingPointStatusRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetTrackingPointStatusRequest) ProtoMessage() {} - -func (x *SetTrackingPointStatusRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetTrackingPointStatusRequest.ProtoReflect.Descriptor instead. -func (*SetTrackingPointStatusRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{0} -} - -func (x *SetTrackingPointStatusRequest) GetTrackedPoint() *TrackPoint { - if x != nil { - return x.TrackedPoint - } - return nil -} - -type SetTrackingPointStatusResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SetTrackingPointStatusResponse) Reset() { - *x = SetTrackingPointStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetTrackingPointStatusResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetTrackingPointStatusResponse) ProtoMessage() {} - -func (x *SetTrackingPointStatusResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetTrackingPointStatusResponse.ProtoReflect.Descriptor instead. -func (*SetTrackingPointStatusResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{1} -} - -type SetTrackingRectangleStatusRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackedRectangle *TrackRectangle `protobuf:"bytes,1,opt,name=tracked_rectangle,json=trackedRectangle,proto3" json:"tracked_rectangle,omitempty"` // The tracked rectangle -} - -func (x *SetTrackingRectangleStatusRequest) Reset() { - *x = SetTrackingRectangleStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetTrackingRectangleStatusRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetTrackingRectangleStatusRequest) ProtoMessage() {} - -func (x *SetTrackingRectangleStatusRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetTrackingRectangleStatusRequest.ProtoReflect.Descriptor instead. -func (*SetTrackingRectangleStatusRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{2} -} - -func (x *SetTrackingRectangleStatusRequest) GetTrackedRectangle() *TrackRectangle { - if x != nil { - return x.TrackedRectangle - } - return nil -} - -type SetTrackingRectangleStatusResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SetTrackingRectangleStatusResponse) Reset() { - *x = SetTrackingRectangleStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetTrackingRectangleStatusResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetTrackingRectangleStatusResponse) ProtoMessage() {} - -func (x *SetTrackingRectangleStatusResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetTrackingRectangleStatusResponse.ProtoReflect.Descriptor instead. -func (*SetTrackingRectangleStatusResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{3} -} - -type SetTrackingOffStatusRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SetTrackingOffStatusRequest) Reset() { - *x = SetTrackingOffStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetTrackingOffStatusRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetTrackingOffStatusRequest) ProtoMessage() {} - -func (x *SetTrackingOffStatusRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetTrackingOffStatusRequest.ProtoReflect.Descriptor instead. -func (*SetTrackingOffStatusRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{4} -} - -type SetTrackingOffStatusResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SetTrackingOffStatusResponse) Reset() { - *x = SetTrackingOffStatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SetTrackingOffStatusResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SetTrackingOffStatusResponse) ProtoMessage() {} - -func (x *SetTrackingOffStatusResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SetTrackingOffStatusResponse.ProtoReflect.Descriptor instead. -func (*SetTrackingOffStatusResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{5} -} - -type SubscribeTrackingPointCommandRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SubscribeTrackingPointCommandRequest) Reset() { - *x = SubscribeTrackingPointCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SubscribeTrackingPointCommandRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTrackingPointCommandRequest) ProtoMessage() {} - -func (x *SubscribeTrackingPointCommandRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTrackingPointCommandRequest.ProtoReflect.Descriptor instead. -func (*SubscribeTrackingPointCommandRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{6} -} - -type TrackingPointCommandResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackPoint *TrackPoint `protobuf:"bytes,1,opt,name=track_point,json=trackPoint,proto3" json:"track_point,omitempty"` // The point to track if a point is to be tracked -} - -func (x *TrackingPointCommandResponse) Reset() { - *x = TrackingPointCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *TrackingPointCommandResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TrackingPointCommandResponse) ProtoMessage() {} - -func (x *TrackingPointCommandResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TrackingPointCommandResponse.ProtoReflect.Descriptor instead. -func (*TrackingPointCommandResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{7} -} - -func (x *TrackingPointCommandResponse) GetTrackPoint() *TrackPoint { - if x != nil { - return x.TrackPoint - } - return nil -} - -type SubscribeTrackingRectangleCommandRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SubscribeTrackingRectangleCommandRequest) Reset() { - *x = SubscribeTrackingRectangleCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SubscribeTrackingRectangleCommandRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTrackingRectangleCommandRequest) ProtoMessage() {} - -func (x *SubscribeTrackingRectangleCommandRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTrackingRectangleCommandRequest.ProtoReflect.Descriptor instead. -func (*SubscribeTrackingRectangleCommandRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{8} -} - -type TrackingRectangleCommandResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackRectangle *TrackRectangle `protobuf:"bytes,1,opt,name=track_rectangle,json=trackRectangle,proto3" json:"track_rectangle,omitempty"` // The point to track if a point is to be tracked -} - -func (x *TrackingRectangleCommandResponse) Reset() { - *x = TrackingRectangleCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *TrackingRectangleCommandResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TrackingRectangleCommandResponse) ProtoMessage() {} - -func (x *TrackingRectangleCommandResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TrackingRectangleCommandResponse.ProtoReflect.Descriptor instead. -func (*TrackingRectangleCommandResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{9} -} - -func (x *TrackingRectangleCommandResponse) GetTrackRectangle() *TrackRectangle { - if x != nil { - return x.TrackRectangle - } - return nil -} - -type SubscribeTrackingOffCommandRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields -} - -func (x *SubscribeTrackingOffCommandRequest) Reset() { - *x = SubscribeTrackingOffCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *SubscribeTrackingOffCommandRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*SubscribeTrackingOffCommandRequest) ProtoMessage() {} - -func (x *SubscribeTrackingOffCommandRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use SubscribeTrackingOffCommandRequest.ProtoReflect.Descriptor instead. -func (*SubscribeTrackingOffCommandRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{10} -} - -type TrackingOffCommandResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Dummy int32 `protobuf:"varint,1,opt,name=dummy,proto3" json:"dummy,omitempty"` // Unused -} - -func (x *TrackingOffCommandResponse) Reset() { - *x = TrackingOffCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *TrackingOffCommandResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TrackingOffCommandResponse) ProtoMessage() {} - -func (x *TrackingOffCommandResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TrackingOffCommandResponse.ProtoReflect.Descriptor instead. -func (*TrackingOffCommandResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{11} -} - -func (x *TrackingOffCommandResponse) GetDummy() int32 { - if x != nil { - return x.Dummy - } - return 0 -} - -type RespondTrackingPointCommandRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - CommandAnswer CommandAnswer `protobuf:"varint,1,opt,name=command_answer,json=commandAnswer,proto3,enum=mavsdk.rpc.tracking_server.CommandAnswer" json:"command_answer,omitempty"` // The ack to answer to the incoming command -} - -func (x *RespondTrackingPointCommandRequest) Reset() { - *x = RespondTrackingPointCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RespondTrackingPointCommandRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RespondTrackingPointCommandRequest) ProtoMessage() {} - -func (x *RespondTrackingPointCommandRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RespondTrackingPointCommandRequest.ProtoReflect.Descriptor instead. -func (*RespondTrackingPointCommandRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{12} -} - -func (x *RespondTrackingPointCommandRequest) GetCommandAnswer() CommandAnswer { - if x != nil { - return x.CommandAnswer - } - return CommandAnswer_COMMAND_ANSWER_ACCEPTED -} - -type RespondTrackingPointCommandResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackingServerResult *TrackingServerResult `protobuf:"bytes,1,opt,name=tracking_server_result,json=trackingServerResult,proto3" json:"tracking_server_result,omitempty"` // The result of sending the response. -} - -func (x *RespondTrackingPointCommandResponse) Reset() { - *x = RespondTrackingPointCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RespondTrackingPointCommandResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RespondTrackingPointCommandResponse) ProtoMessage() {} - -func (x *RespondTrackingPointCommandResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RespondTrackingPointCommandResponse.ProtoReflect.Descriptor instead. -func (*RespondTrackingPointCommandResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{13} -} - -func (x *RespondTrackingPointCommandResponse) GetTrackingServerResult() *TrackingServerResult { - if x != nil { - return x.TrackingServerResult - } - return nil -} - -type RespondTrackingRectangleCommandRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - CommandAnswer CommandAnswer `protobuf:"varint,1,opt,name=command_answer,json=commandAnswer,proto3,enum=mavsdk.rpc.tracking_server.CommandAnswer" json:"command_answer,omitempty"` // The ack to answer to the incoming command -} - -func (x *RespondTrackingRectangleCommandRequest) Reset() { - *x = RespondTrackingRectangleCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RespondTrackingRectangleCommandRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RespondTrackingRectangleCommandRequest) ProtoMessage() {} - -func (x *RespondTrackingRectangleCommandRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RespondTrackingRectangleCommandRequest.ProtoReflect.Descriptor instead. -func (*RespondTrackingRectangleCommandRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{14} -} - -func (x *RespondTrackingRectangleCommandRequest) GetCommandAnswer() CommandAnswer { - if x != nil { - return x.CommandAnswer - } - return CommandAnswer_COMMAND_ANSWER_ACCEPTED -} - -type RespondTrackingRectangleCommandResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackingServerResult *TrackingServerResult `protobuf:"bytes,1,opt,name=tracking_server_result,json=trackingServerResult,proto3" json:"tracking_server_result,omitempty"` // The result of sending the response. -} - -func (x *RespondTrackingRectangleCommandResponse) Reset() { - *x = RespondTrackingRectangleCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RespondTrackingRectangleCommandResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RespondTrackingRectangleCommandResponse) ProtoMessage() {} - -func (x *RespondTrackingRectangleCommandResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RespondTrackingRectangleCommandResponse.ProtoReflect.Descriptor instead. -func (*RespondTrackingRectangleCommandResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{15} -} - -func (x *RespondTrackingRectangleCommandResponse) GetTrackingServerResult() *TrackingServerResult { - if x != nil { - return x.TrackingServerResult - } - return nil -} - -type RespondTrackingOffCommandRequest struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - CommandAnswer CommandAnswer `protobuf:"varint,1,opt,name=command_answer,json=commandAnswer,proto3,enum=mavsdk.rpc.tracking_server.CommandAnswer" json:"command_answer,omitempty"` // The ack to answer to the incoming command -} - -func (x *RespondTrackingOffCommandRequest) Reset() { - *x = RespondTrackingOffCommandRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RespondTrackingOffCommandRequest) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RespondTrackingOffCommandRequest) ProtoMessage() {} - -func (x *RespondTrackingOffCommandRequest) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RespondTrackingOffCommandRequest.ProtoReflect.Descriptor instead. -func (*RespondTrackingOffCommandRequest) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{16} -} - -func (x *RespondTrackingOffCommandRequest) GetCommandAnswer() CommandAnswer { - if x != nil { - return x.CommandAnswer - } - return CommandAnswer_COMMAND_ANSWER_ACCEPTED -} - -type RespondTrackingOffCommandResponse struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TrackingServerResult *TrackingServerResult `protobuf:"bytes,1,opt,name=tracking_server_result,json=trackingServerResult,proto3" json:"tracking_server_result,omitempty"` // The result of sending the response. -} - -func (x *RespondTrackingOffCommandResponse) Reset() { - *x = RespondTrackingOffCommandResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RespondTrackingOffCommandResponse) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RespondTrackingOffCommandResponse) ProtoMessage() {} - -func (x *RespondTrackingOffCommandResponse) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use RespondTrackingOffCommandResponse.ProtoReflect.Descriptor instead. -func (*RespondTrackingOffCommandResponse) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{17} -} - -func (x *RespondTrackingOffCommandResponse) GetTrackingServerResult() *TrackingServerResult { - if x != nil { - return x.TrackingServerResult - } - return nil -} - -// Point description type -type TrackPoint struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - PointX float32 `protobuf:"fixed32,1,opt,name=point_x,json=pointX,proto3" json:"point_x,omitempty"` // Point to track x value (normalized 0..1, 0 is left, 1 is right). - PointY float32 `protobuf:"fixed32,2,opt,name=point_y,json=pointY,proto3" json:"point_y,omitempty"` // Point to track y value (normalized 0..1, 0 is top, 1 is bottom). - Radius float32 `protobuf:"fixed32,3,opt,name=radius,proto3" json:"radius,omitempty"` // Point to track y value (normalized 0..1, 0 is top, 1 is bottom). -} - -func (x *TrackPoint) Reset() { - *x = TrackPoint{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *TrackPoint) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TrackPoint) ProtoMessage() {} - -func (x *TrackPoint) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TrackPoint.ProtoReflect.Descriptor instead. -func (*TrackPoint) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{18} -} - -func (x *TrackPoint) GetPointX() float32 { - if x != nil { - return x.PointX - } - return 0 -} - -func (x *TrackPoint) GetPointY() float32 { - if x != nil { - return x.PointY - } - return 0 -} - -func (x *TrackPoint) GetRadius() float32 { - if x != nil { - return x.Radius - } - return 0 -} - -// Rectangle description type -type TrackRectangle struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - TopLeftCornerX float32 `protobuf:"fixed32,1,opt,name=top_left_corner_x,json=topLeftCornerX,proto3" json:"top_left_corner_x,omitempty"` // Top left corner of rectangle x value (normalized 0..1, 0 is left, 1 is right). - TopLeftCornerY float32 `protobuf:"fixed32,2,opt,name=top_left_corner_y,json=topLeftCornerY,proto3" json:"top_left_corner_y,omitempty"` // Top left corner of rectangle y value (normalized 0..1, 0 is top, 1 is bottom). - BottomRightCornerX float32 `protobuf:"fixed32,3,opt,name=bottom_right_corner_x,json=bottomRightCornerX,proto3" json:"bottom_right_corner_x,omitempty"` // Bottom right corner of rectangle x value (normalized 0..1, 0 is left, 1 is right). - BottomRightCornerY float32 `protobuf:"fixed32,4,opt,name=bottom_right_corner_y,json=bottomRightCornerY,proto3" json:"bottom_right_corner_y,omitempty"` // Bottom right corner of rectangle y value (normalized 0..1, 0 is top, 1 is bottom). -} - -func (x *TrackRectangle) Reset() { - *x = TrackRectangle{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *TrackRectangle) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TrackRectangle) ProtoMessage() {} - -func (x *TrackRectangle) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TrackRectangle.ProtoReflect.Descriptor instead. -func (*TrackRectangle) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{19} -} - -func (x *TrackRectangle) GetTopLeftCornerX() float32 { - if x != nil { - return x.TopLeftCornerX - } - return 0 -} - -func (x *TrackRectangle) GetTopLeftCornerY() float32 { - if x != nil { - return x.TopLeftCornerY - } - return 0 -} - -func (x *TrackRectangle) GetBottomRightCornerX() float32 { - if x != nil { - return x.BottomRightCornerX - } - return 0 -} - -func (x *TrackRectangle) GetBottomRightCornerY() float32 { - if x != nil { - return x.BottomRightCornerY - } - return 0 -} - -// Result type -type TrackingServerResult struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Result TrackingServerResult_Result `protobuf:"varint,1,opt,name=result,proto3,enum=mavsdk.rpc.tracking_server.TrackingServerResult_Result" json:"result,omitempty"` // Result enum value - ResultStr string `protobuf:"bytes,2,opt,name=result_str,json=resultStr,proto3" json:"result_str,omitempty"` // Human-readable English string describing the result -} - -func (x *TrackingServerResult) Reset() { - *x = TrackingServerResult{} - if protoimpl.UnsafeEnabled { - mi := &file_tracking_server_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *TrackingServerResult) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TrackingServerResult) ProtoMessage() {} - -func (x *TrackingServerResult) ProtoReflect() protoreflect.Message { - mi := &file_tracking_server_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TrackingServerResult.ProtoReflect.Descriptor instead. -func (*TrackingServerResult) Descriptor() ([]byte, []int) { - return file_tracking_server_proto_rawDescGZIP(), []int{20} -} - -func (x *TrackingServerResult) GetResult() TrackingServerResult_Result { - if x != nil { - return x.Result - } - return TrackingServerResult_RESULT_UNKNOWN -} - -func (x *TrackingServerResult) GetResultStr() string { - if x != nil { - return x.ResultStr - } - return "" -} - -var File_tracking_server_proto protoreflect.FileDescriptor - -var file_tracking_server_proto_rawDesc = []byte{ - 0x0a, 0x15, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, - 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1a, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, - 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x1a, 0x14, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x5f, 0x6f, 0x70, 0x74, 0x69, - 0x6f, 0x6e, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x6c, 0x0a, 0x1d, 0x53, 0x65, 0x74, - 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x53, 0x74, 0x61, - 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x4b, 0x0a, 0x0d, 0x74, 0x72, - 0x61, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x26, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, - 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, - 0x72, 0x61, 0x63, 0x6b, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x52, 0x0c, 0x74, 0x72, 0x61, 0x63, 0x6b, - 0x65, 0x64, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x22, 0x20, 0x0a, 0x1e, 0x53, 0x65, 0x74, 0x54, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x7c, 0x0a, 0x21, 0x53, 0x65, 0x74, - 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, - 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x57, - 0x0a, 0x11, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x63, 0x74, 0x61, 0x6e, - 0x67, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x6d, 0x61, 0x76, 0x73, - 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, - 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x52, 0x65, 0x63, 0x74, - 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x52, 0x10, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x65, 0x64, 0x52, 0x65, - 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x22, 0x24, 0x0a, 0x22, 0x53, 0x65, 0x74, 0x54, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x53, - 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x1d, 0x0a, - 0x1b, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x53, - 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x1e, 0x0a, 0x1c, - 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x53, 0x74, - 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x26, 0x0a, 0x24, - 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x22, 0x67, 0x0a, 0x1c, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x47, 0x0a, 0x0b, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x5f, 0x70, 0x6f, - 0x69, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x6d, 0x61, 0x76, 0x73, - 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, - 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x50, 0x6f, 0x69, 0x6e, - 0x74, 0x52, 0x0a, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x22, 0x2a, 0x0a, - 0x28, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x61, - 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x77, 0x0a, 0x20, 0x54, 0x72, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, - 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x53, 0x0a, - 0x0f, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x5f, 0x72, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, - 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, - 0x6c, 0x65, 0x52, 0x0e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, - 0x6c, 0x65, 0x22, 0x24, 0x0a, 0x22, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, - 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, - 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x32, 0x0a, 0x1a, 0x54, 0x72, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x64, 0x75, 0x6d, 0x6d, 0x79, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x64, 0x75, 0x6d, 0x6d, 0x79, 0x22, 0x76, 0x0a, 0x22, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, - 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x12, 0x50, 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x5f, 0x61, 0x6e, - 0x73, 0x77, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x6d, 0x61, 0x76, - 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x41, - 0x6e, 0x73, 0x77, 0x65, 0x72, 0x52, 0x0d, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x41, 0x6e, - 0x73, 0x77, 0x65, 0x72, 0x22, 0x8d, 0x01, 0x0a, 0x23, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, - 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, - 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x16, - 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, - 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6d, - 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x14, - 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x65, - 0x73, 0x75, 0x6c, 0x74, 0x22, 0x7a, 0x0a, 0x26, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, - 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, - 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x50, - 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x5f, 0x61, 0x6e, 0x73, 0x77, 0x65, 0x72, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, - 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x41, 0x6e, 0x73, 0x77, 0x65, - 0x72, 0x52, 0x0d, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x41, 0x6e, 0x73, 0x77, 0x65, 0x72, - 0x22, 0x91, 0x01, 0x0a, 0x27, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, 0x6d, - 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x66, 0x0a, 0x16, - 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, - 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6d, - 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x52, 0x14, - 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x65, - 0x73, 0x75, 0x6c, 0x74, 0x22, 0x74, 0x0a, 0x20, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, - 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, - 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x50, 0x0a, 0x0e, 0x63, 0x6f, 0x6d, 0x6d, - 0x61, 0x6e, 0x64, 0x5f, 0x61, 0x6e, 0x73, 0x77, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, - 0x32, 0x29, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x43, 0x6f, - 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x41, 0x6e, 0x73, 0x77, 0x65, 0x72, 0x52, 0x0d, 0x63, 0x6f, 0x6d, - 0x6d, 0x61, 0x6e, 0x64, 0x41, 0x6e, 0x73, 0x77, 0x65, 0x72, 0x22, 0x8b, 0x01, 0x0a, 0x21, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, - 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x66, 0x0a, 0x16, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x30, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x52, 0x65, 0x73, 0x75, - 0x6c, 0x74, 0x52, 0x14, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, - 0x65, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x22, 0x56, 0x0a, 0x0a, 0x54, 0x72, 0x61, 0x63, - 0x6b, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x17, 0x0a, 0x07, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x5f, - 0x78, 0x18, 0x01, 0x20, 0x01, 0x28, 0x02, 0x52, 0x06, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x58, 0x12, - 0x17, 0x0a, 0x07, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x5f, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x02, - 0x52, 0x06, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x59, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x61, 0x64, 0x69, - 0x75, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x06, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, - 0x22, 0xcc, 0x01, 0x0a, 0x0e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, - 0x67, 0x6c, 0x65, 0x12, 0x29, 0x0a, 0x11, 0x74, 0x6f, 0x70, 0x5f, 0x6c, 0x65, 0x66, 0x74, 0x5f, - 0x63, 0x6f, 0x72, 0x6e, 0x65, 0x72, 0x5f, 0x78, 0x18, 0x01, 0x20, 0x01, 0x28, 0x02, 0x52, 0x0e, - 0x74, 0x6f, 0x70, 0x4c, 0x65, 0x66, 0x74, 0x43, 0x6f, 0x72, 0x6e, 0x65, 0x72, 0x58, 0x12, 0x29, - 0x0a, 0x11, 0x74, 0x6f, 0x70, 0x5f, 0x6c, 0x65, 0x66, 0x74, 0x5f, 0x63, 0x6f, 0x72, 0x6e, 0x65, - 0x72, 0x5f, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x02, 0x52, 0x0e, 0x74, 0x6f, 0x70, 0x4c, 0x65, - 0x66, 0x74, 0x43, 0x6f, 0x72, 0x6e, 0x65, 0x72, 0x59, 0x12, 0x31, 0x0a, 0x15, 0x62, 0x6f, 0x74, - 0x74, 0x6f, 0x6d, 0x5f, 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x63, 0x6f, 0x72, 0x6e, 0x65, 0x72, - 0x5f, 0x78, 0x18, 0x03, 0x20, 0x01, 0x28, 0x02, 0x52, 0x12, 0x62, 0x6f, 0x74, 0x74, 0x6f, 0x6d, - 0x52, 0x69, 0x67, 0x68, 0x74, 0x43, 0x6f, 0x72, 0x6e, 0x65, 0x72, 0x58, 0x12, 0x31, 0x0a, 0x15, - 0x62, 0x6f, 0x74, 0x74, 0x6f, 0x6d, 0x5f, 0x72, 0x69, 0x67, 0x68, 0x74, 0x5f, 0x63, 0x6f, 0x72, - 0x6e, 0x65, 0x72, 0x5f, 0x79, 0x18, 0x04, 0x20, 0x01, 0x28, 0x02, 0x52, 0x12, 0x62, 0x6f, 0x74, - 0x74, 0x6f, 0x6d, 0x52, 0x69, 0x67, 0x68, 0x74, 0x43, 0x6f, 0x72, 0x6e, 0x65, 0x72, 0x59, 0x22, - 0xeb, 0x01, 0x0a, 0x14, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, - 0x65, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x4f, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, - 0x6c, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x37, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, - 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, - 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, - 0x72, 0x76, 0x65, 0x72, 0x52, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x75, 0x6c, - 0x74, 0x52, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x72, 0x65, 0x73, - 0x75, 0x6c, 0x74, 0x5f, 0x73, 0x74, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x72, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x53, 0x74, 0x72, 0x22, 0x63, 0x0a, 0x06, 0x52, 0x65, 0x73, 0x75, - 0x6c, 0x74, 0x12, 0x12, 0x0a, 0x0e, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x55, 0x4e, 0x4b, - 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x12, 0x0a, 0x0e, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, - 0x5f, 0x53, 0x55, 0x43, 0x43, 0x45, 0x53, 0x53, 0x10, 0x01, 0x12, 0x14, 0x0a, 0x10, 0x52, 0x45, - 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x4e, 0x4f, 0x5f, 0x53, 0x59, 0x53, 0x54, 0x45, 0x4d, 0x10, 0x02, - 0x12, 0x1b, 0x0a, 0x17, 0x52, 0x45, 0x53, 0x55, 0x4c, 0x54, 0x5f, 0x43, 0x4f, 0x4e, 0x4e, 0x45, - 0x43, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x10, 0x03, 0x2a, 0xab, 0x01, - 0x0a, 0x0d, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x41, 0x6e, 0x73, 0x77, 0x65, 0x72, 0x12, - 0x1b, 0x0a, 0x17, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x5f, 0x41, 0x4e, 0x53, 0x57, 0x45, - 0x52, 0x5f, 0x41, 0x43, 0x43, 0x45, 0x50, 0x54, 0x45, 0x44, 0x10, 0x00, 0x12, 0x27, 0x0a, 0x23, - 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x5f, 0x41, 0x4e, 0x53, 0x57, 0x45, 0x52, 0x5f, 0x54, - 0x45, 0x4d, 0x50, 0x4f, 0x52, 0x41, 0x52, 0x49, 0x4c, 0x59, 0x5f, 0x52, 0x45, 0x4a, 0x45, 0x43, - 0x54, 0x45, 0x44, 0x10, 0x01, 0x12, 0x19, 0x0a, 0x15, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, - 0x5f, 0x41, 0x4e, 0x53, 0x57, 0x45, 0x52, 0x5f, 0x44, 0x45, 0x4e, 0x49, 0x45, 0x44, 0x10, 0x02, - 0x12, 0x1e, 0x0a, 0x1a, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x5f, 0x41, 0x4e, 0x53, 0x57, - 0x45, 0x52, 0x5f, 0x55, 0x4e, 0x53, 0x55, 0x50, 0x50, 0x4f, 0x52, 0x54, 0x45, 0x44, 0x10, 0x03, - 0x12, 0x19, 0x0a, 0x15, 0x43, 0x4f, 0x4d, 0x4d, 0x41, 0x4e, 0x44, 0x5f, 0x41, 0x4e, 0x53, 0x57, - 0x45, 0x52, 0x5f, 0x46, 0x41, 0x49, 0x4c, 0x45, 0x44, 0x10, 0x04, 0x32, 0xd8, 0x0b, 0x0a, 0x15, - 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x53, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x95, 0x01, 0x0a, 0x16, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, - 0x12, 0x39, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x65, - 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x53, 0x74, - 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3a, 0x2e, 0x6d, 0x61, - 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x04, 0x80, 0xb5, 0x18, 0x01, 0x12, 0xa1, 0x01, - 0x0a, 0x1a, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, - 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x3d, 0x2e, 0x6d, - 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x53, 0x74, - 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3e, 0x2e, 0x6d, 0x61, - 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x53, 0x74, 0x61, - 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x04, 0x80, 0xb5, 0x18, - 0x01, 0x12, 0x8f, 0x01, 0x0a, 0x14, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x4f, 0x66, 0x66, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x37, 0x2e, 0x6d, 0x61, 0x76, - 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x38, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, - 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, - 0x2e, 0x53, 0x65, 0x74, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x53, - 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x04, 0x80, - 0xb5, 0x18, 0x01, 0x12, 0xa3, 0x01, 0x0a, 0x1d, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, - 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, - 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x40, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, - 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, - 0x65, 0x72, 0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, - 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x38, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, - 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, - 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, - 0x6e, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x04, 0x80, 0xb5, 0x18, 0x00, 0x30, 0x01, 0x12, 0xaf, 0x01, 0x0a, 0x21, 0x53, 0x75, - 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, - 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, - 0x44, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, - 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x75, 0x62, - 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, - 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3c, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, - 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, - 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, - 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x04, 0x80, 0xb5, 0x18, 0x00, 0x30, 0x01, 0x12, 0x9d, 0x01, 0x0a, 0x1b, - 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x3e, 0x2e, 0x6d, 0x61, - 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, - 0x62, 0x65, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, - 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x36, 0x2e, 0x6d, 0x61, - 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x04, 0x80, 0xb5, 0x18, 0x00, 0x30, 0x01, 0x12, 0xa4, 0x01, 0x0a, 0x1b, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, - 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x3e, 0x2e, 0x6d, 0x61, - 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, - 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, - 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x3f, 0x2e, 0x6d, 0x61, - 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, - 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x50, 0x6f, 0x69, 0x6e, 0x74, 0x43, 0x6f, 0x6d, - 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x04, 0x80, 0xb5, - 0x18, 0x01, 0x12, 0xb0, 0x01, 0x0a, 0x1f, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, - 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, - 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x12, 0x42, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, - 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, 0x43, 0x6f, 0x6d, 0x6d, - 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x43, 0x2e, 0x6d, 0x61, 0x76, - 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, - 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x63, 0x74, 0x61, 0x6e, 0x67, 0x6c, 0x65, - 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x04, 0x80, 0xb5, 0x18, 0x01, 0x12, 0x9e, 0x01, 0x0a, 0x19, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, - 0x61, 0x6e, 0x64, 0x12, 0x3c, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, - 0x2e, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, - 0x2e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, - 0x4f, 0x66, 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x3d, 0x2e, 0x6d, 0x61, 0x76, 0x73, 0x64, 0x6b, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x74, - 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x4f, 0x66, - 0x66, 0x43, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x22, 0x04, 0x80, 0xb5, 0x18, 0x01, 0x42, 0x28, 0x42, 0x13, 0x54, 0x72, 0x61, 0x63, 0x6b, 0x69, - 0x6e, 0x67, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x5a, 0x11, 0x2e, - 0x3b, 0x74, 0x72, 0x61, 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -} - -var ( - file_tracking_server_proto_rawDescOnce sync.Once - file_tracking_server_proto_rawDescData = file_tracking_server_proto_rawDesc -) - -func file_tracking_server_proto_rawDescGZIP() []byte { - file_tracking_server_proto_rawDescOnce.Do(func() { - file_tracking_server_proto_rawDescData = protoimpl.X.CompressGZIP(file_tracking_server_proto_rawDescData) - }) - return file_tracking_server_proto_rawDescData -} - -var file_tracking_server_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_tracking_server_proto_msgTypes = make([]protoimpl.MessageInfo, 21) -var file_tracking_server_proto_goTypes = []interface{}{ - (CommandAnswer)(0), // 0: mavsdk.rpc.tracking_server.CommandAnswer - (TrackingServerResult_Result)(0), // 1: mavsdk.rpc.tracking_server.TrackingServerResult.Result - (*SetTrackingPointStatusRequest)(nil), // 2: mavsdk.rpc.tracking_server.SetTrackingPointStatusRequest - (*SetTrackingPointStatusResponse)(nil), // 3: mavsdk.rpc.tracking_server.SetTrackingPointStatusResponse - (*SetTrackingRectangleStatusRequest)(nil), // 4: mavsdk.rpc.tracking_server.SetTrackingRectangleStatusRequest - (*SetTrackingRectangleStatusResponse)(nil), // 5: mavsdk.rpc.tracking_server.SetTrackingRectangleStatusResponse - (*SetTrackingOffStatusRequest)(nil), // 6: mavsdk.rpc.tracking_server.SetTrackingOffStatusRequest - (*SetTrackingOffStatusResponse)(nil), // 7: mavsdk.rpc.tracking_server.SetTrackingOffStatusResponse - (*SubscribeTrackingPointCommandRequest)(nil), // 8: mavsdk.rpc.tracking_server.SubscribeTrackingPointCommandRequest - (*TrackingPointCommandResponse)(nil), // 9: mavsdk.rpc.tracking_server.TrackingPointCommandResponse - (*SubscribeTrackingRectangleCommandRequest)(nil), // 10: mavsdk.rpc.tracking_server.SubscribeTrackingRectangleCommandRequest - (*TrackingRectangleCommandResponse)(nil), // 11: mavsdk.rpc.tracking_server.TrackingRectangleCommandResponse - (*SubscribeTrackingOffCommandRequest)(nil), // 12: mavsdk.rpc.tracking_server.SubscribeTrackingOffCommandRequest - (*TrackingOffCommandResponse)(nil), // 13: mavsdk.rpc.tracking_server.TrackingOffCommandResponse - (*RespondTrackingPointCommandRequest)(nil), // 14: mavsdk.rpc.tracking_server.RespondTrackingPointCommandRequest - (*RespondTrackingPointCommandResponse)(nil), // 15: mavsdk.rpc.tracking_server.RespondTrackingPointCommandResponse - (*RespondTrackingRectangleCommandRequest)(nil), // 16: mavsdk.rpc.tracking_server.RespondTrackingRectangleCommandRequest - (*RespondTrackingRectangleCommandResponse)(nil), // 17: mavsdk.rpc.tracking_server.RespondTrackingRectangleCommandResponse - (*RespondTrackingOffCommandRequest)(nil), // 18: mavsdk.rpc.tracking_server.RespondTrackingOffCommandRequest - (*RespondTrackingOffCommandResponse)(nil), // 19: mavsdk.rpc.tracking_server.RespondTrackingOffCommandResponse - (*TrackPoint)(nil), // 20: mavsdk.rpc.tracking_server.TrackPoint - (*TrackRectangle)(nil), // 21: mavsdk.rpc.tracking_server.TrackRectangle - (*TrackingServerResult)(nil), // 22: mavsdk.rpc.tracking_server.TrackingServerResult -} -var file_tracking_server_proto_depIdxs = []int32{ - 20, // 0: mavsdk.rpc.tracking_server.SetTrackingPointStatusRequest.tracked_point:type_name -> mavsdk.rpc.tracking_server.TrackPoint - 21, // 1: mavsdk.rpc.tracking_server.SetTrackingRectangleStatusRequest.tracked_rectangle:type_name -> mavsdk.rpc.tracking_server.TrackRectangle - 20, // 2: mavsdk.rpc.tracking_server.TrackingPointCommandResponse.track_point:type_name -> mavsdk.rpc.tracking_server.TrackPoint - 21, // 3: mavsdk.rpc.tracking_server.TrackingRectangleCommandResponse.track_rectangle:type_name -> mavsdk.rpc.tracking_server.TrackRectangle - 0, // 4: mavsdk.rpc.tracking_server.RespondTrackingPointCommandRequest.command_answer:type_name -> mavsdk.rpc.tracking_server.CommandAnswer - 22, // 5: mavsdk.rpc.tracking_server.RespondTrackingPointCommandResponse.tracking_server_result:type_name -> mavsdk.rpc.tracking_server.TrackingServerResult - 0, // 6: mavsdk.rpc.tracking_server.RespondTrackingRectangleCommandRequest.command_answer:type_name -> mavsdk.rpc.tracking_server.CommandAnswer - 22, // 7: mavsdk.rpc.tracking_server.RespondTrackingRectangleCommandResponse.tracking_server_result:type_name -> mavsdk.rpc.tracking_server.TrackingServerResult - 0, // 8: mavsdk.rpc.tracking_server.RespondTrackingOffCommandRequest.command_answer:type_name -> mavsdk.rpc.tracking_server.CommandAnswer - 22, // 9: mavsdk.rpc.tracking_server.RespondTrackingOffCommandResponse.tracking_server_result:type_name -> mavsdk.rpc.tracking_server.TrackingServerResult - 1, // 10: mavsdk.rpc.tracking_server.TrackingServerResult.result:type_name -> mavsdk.rpc.tracking_server.TrackingServerResult.Result - 2, // 11: mavsdk.rpc.tracking_server.TrackingServerService.SetTrackingPointStatus:input_type -> mavsdk.rpc.tracking_server.SetTrackingPointStatusRequest - 4, // 12: mavsdk.rpc.tracking_server.TrackingServerService.SetTrackingRectangleStatus:input_type -> mavsdk.rpc.tracking_server.SetTrackingRectangleStatusRequest - 6, // 13: mavsdk.rpc.tracking_server.TrackingServerService.SetTrackingOffStatus:input_type -> mavsdk.rpc.tracking_server.SetTrackingOffStatusRequest - 8, // 14: mavsdk.rpc.tracking_server.TrackingServerService.SubscribeTrackingPointCommand:input_type -> mavsdk.rpc.tracking_server.SubscribeTrackingPointCommandRequest - 10, // 15: mavsdk.rpc.tracking_server.TrackingServerService.SubscribeTrackingRectangleCommand:input_type -> mavsdk.rpc.tracking_server.SubscribeTrackingRectangleCommandRequest - 12, // 16: mavsdk.rpc.tracking_server.TrackingServerService.SubscribeTrackingOffCommand:input_type -> mavsdk.rpc.tracking_server.SubscribeTrackingOffCommandRequest - 14, // 17: mavsdk.rpc.tracking_server.TrackingServerService.RespondTrackingPointCommand:input_type -> mavsdk.rpc.tracking_server.RespondTrackingPointCommandRequest - 16, // 18: mavsdk.rpc.tracking_server.TrackingServerService.RespondTrackingRectangleCommand:input_type -> mavsdk.rpc.tracking_server.RespondTrackingRectangleCommandRequest - 18, // 19: mavsdk.rpc.tracking_server.TrackingServerService.RespondTrackingOffCommand:input_type -> mavsdk.rpc.tracking_server.RespondTrackingOffCommandRequest - 3, // 20: mavsdk.rpc.tracking_server.TrackingServerService.SetTrackingPointStatus:output_type -> mavsdk.rpc.tracking_server.SetTrackingPointStatusResponse - 5, // 21: mavsdk.rpc.tracking_server.TrackingServerService.SetTrackingRectangleStatus:output_type -> mavsdk.rpc.tracking_server.SetTrackingRectangleStatusResponse - 7, // 22: mavsdk.rpc.tracking_server.TrackingServerService.SetTrackingOffStatus:output_type -> mavsdk.rpc.tracking_server.SetTrackingOffStatusResponse - 9, // 23: mavsdk.rpc.tracking_server.TrackingServerService.SubscribeTrackingPointCommand:output_type -> mavsdk.rpc.tracking_server.TrackingPointCommandResponse - 11, // 24: mavsdk.rpc.tracking_server.TrackingServerService.SubscribeTrackingRectangleCommand:output_type -> mavsdk.rpc.tracking_server.TrackingRectangleCommandResponse - 13, // 25: mavsdk.rpc.tracking_server.TrackingServerService.SubscribeTrackingOffCommand:output_type -> mavsdk.rpc.tracking_server.TrackingOffCommandResponse - 15, // 26: mavsdk.rpc.tracking_server.TrackingServerService.RespondTrackingPointCommand:output_type -> mavsdk.rpc.tracking_server.RespondTrackingPointCommandResponse - 17, // 27: mavsdk.rpc.tracking_server.TrackingServerService.RespondTrackingRectangleCommand:output_type -> mavsdk.rpc.tracking_server.RespondTrackingRectangleCommandResponse - 19, // 28: mavsdk.rpc.tracking_server.TrackingServerService.RespondTrackingOffCommand:output_type -> mavsdk.rpc.tracking_server.RespondTrackingOffCommandResponse - 20, // [20:29] is the sub-list for method output_type - 11, // [11:20] is the sub-list for method input_type - 11, // [11:11] is the sub-list for extension type_name - 11, // [11:11] is the sub-list for extension extendee - 0, // [0:11] is the sub-list for field type_name -} - -func init() { file_tracking_server_proto_init() } -func file_tracking_server_proto_init() { - if File_tracking_server_proto != nil { - return - } - if !protoimpl.UnsafeEnabled { - file_tracking_server_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetTrackingPointStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetTrackingPointStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetTrackingRectangleStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetTrackingRectangleStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetTrackingOffStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SetTrackingOffStatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SubscribeTrackingPointCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*TrackingPointCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SubscribeTrackingRectangleCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*TrackingRectangleCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SubscribeTrackingOffCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*TrackingOffCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RespondTrackingPointCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RespondTrackingPointCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RespondTrackingRectangleCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RespondTrackingRectangleCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RespondTrackingOffCommandRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RespondTrackingOffCommandResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*TrackPoint); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*TrackRectangle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tracking_server_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*TrackingServerResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: file_tracking_server_proto_rawDesc, - NumEnums: 2, - NumMessages: 21, - NumExtensions: 0, - NumServices: 1, - }, - GoTypes: file_tracking_server_proto_goTypes, - DependencyIndexes: file_tracking_server_proto_depIdxs, - EnumInfos: file_tracking_server_proto_enumTypes, - MessageInfos: file_tracking_server_proto_msgTypes, - }.Build() - File_tracking_server_proto = out.File - file_tracking_server_proto_rawDesc = nil - file_tracking_server_proto_goTypes = nil - file_tracking_server_proto_depIdxs = nil -} diff --git a/Sources/tracking_server/tracking_server_grpc.pb.go b/Sources/tracking_server/tracking_server_grpc.pb.go deleted file mode 100644 index 999a57a..0000000 --- a/Sources/tracking_server/tracking_server_grpc.pb.go +++ /dev/null @@ -1,505 +0,0 @@ -// Code generated by protoc-gen-go-grpc. DO NOT EDIT. -// versions: -// - protoc-gen-go-grpc v1.3.0 -// - protoc v3.12.4 -// source: tracking_server.proto - -package tracking_server - -import ( - context "context" - grpc "google.golang.org/grpc" - codes "google.golang.org/grpc/codes" - status "google.golang.org/grpc/status" -) - -// 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 - -const ( - TrackingServerService_SetTrackingPointStatus_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/SetTrackingPointStatus" - TrackingServerService_SetTrackingRectangleStatus_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/SetTrackingRectangleStatus" - TrackingServerService_SetTrackingOffStatus_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/SetTrackingOffStatus" - TrackingServerService_SubscribeTrackingPointCommand_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/SubscribeTrackingPointCommand" - TrackingServerService_SubscribeTrackingRectangleCommand_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/SubscribeTrackingRectangleCommand" - TrackingServerService_SubscribeTrackingOffCommand_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/SubscribeTrackingOffCommand" - TrackingServerService_RespondTrackingPointCommand_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/RespondTrackingPointCommand" - TrackingServerService_RespondTrackingRectangleCommand_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/RespondTrackingRectangleCommand" - TrackingServerService_RespondTrackingOffCommand_FullMethodName = "/mavsdk.rpc.tracking_server.TrackingServerService/RespondTrackingOffCommand" -) - -// TrackingServerServiceClient is the client API for TrackingServerService 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. -type TrackingServerServiceClient interface { - // Set/update the current point tracking status. - SetTrackingPointStatus(ctx context.Context, in *SetTrackingPointStatusRequest, opts ...grpc.CallOption) (*SetTrackingPointStatusResponse, error) - // Set/update the current rectangle tracking status. - SetTrackingRectangleStatus(ctx context.Context, in *SetTrackingRectangleStatusRequest, opts ...grpc.CallOption) (*SetTrackingRectangleStatusResponse, error) - // Set the current tracking status to off. - SetTrackingOffStatus(ctx context.Context, in *SetTrackingOffStatusRequest, opts ...grpc.CallOption) (*SetTrackingOffStatusResponse, error) - // Subscribe to incoming tracking point command. - SubscribeTrackingPointCommand(ctx context.Context, in *SubscribeTrackingPointCommandRequest, opts ...grpc.CallOption) (TrackingServerService_SubscribeTrackingPointCommandClient, error) - // Subscribe to incoming tracking rectangle command. - SubscribeTrackingRectangleCommand(ctx context.Context, in *SubscribeTrackingRectangleCommandRequest, opts ...grpc.CallOption) (TrackingServerService_SubscribeTrackingRectangleCommandClient, error) - // Subscribe to incoming tracking off command. - SubscribeTrackingOffCommand(ctx context.Context, in *SubscribeTrackingOffCommandRequest, opts ...grpc.CallOption) (TrackingServerService_SubscribeTrackingOffCommandClient, error) - // Respond to an incoming tracking point command. - RespondTrackingPointCommand(ctx context.Context, in *RespondTrackingPointCommandRequest, opts ...grpc.CallOption) (*RespondTrackingPointCommandResponse, error) - // Respond to an incoming tracking rectangle command. - RespondTrackingRectangleCommand(ctx context.Context, in *RespondTrackingRectangleCommandRequest, opts ...grpc.CallOption) (*RespondTrackingRectangleCommandResponse, error) - // Respond to an incoming tracking off command. - RespondTrackingOffCommand(ctx context.Context, in *RespondTrackingOffCommandRequest, opts ...grpc.CallOption) (*RespondTrackingOffCommandResponse, error) -} - -type trackingServerServiceClient struct { - cc grpc.ClientConnInterface -} - -func NewTrackingServerServiceClient(cc grpc.ClientConnInterface) TrackingServerServiceClient { - return &trackingServerServiceClient{cc} -} - -func (c *trackingServerServiceClient) SetTrackingPointStatus(ctx context.Context, in *SetTrackingPointStatusRequest, opts ...grpc.CallOption) (*SetTrackingPointStatusResponse, error) { - out := new(SetTrackingPointStatusResponse) - err := c.cc.Invoke(ctx, TrackingServerService_SetTrackingPointStatus_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *trackingServerServiceClient) SetTrackingRectangleStatus(ctx context.Context, in *SetTrackingRectangleStatusRequest, opts ...grpc.CallOption) (*SetTrackingRectangleStatusResponse, error) { - out := new(SetTrackingRectangleStatusResponse) - err := c.cc.Invoke(ctx, TrackingServerService_SetTrackingRectangleStatus_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *trackingServerServiceClient) SetTrackingOffStatus(ctx context.Context, in *SetTrackingOffStatusRequest, opts ...grpc.CallOption) (*SetTrackingOffStatusResponse, error) { - out := new(SetTrackingOffStatusResponse) - err := c.cc.Invoke(ctx, TrackingServerService_SetTrackingOffStatus_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *trackingServerServiceClient) SubscribeTrackingPointCommand(ctx context.Context, in *SubscribeTrackingPointCommandRequest, opts ...grpc.CallOption) (TrackingServerService_SubscribeTrackingPointCommandClient, error) { - stream, err := c.cc.NewStream(ctx, &TrackingServerService_ServiceDesc.Streams[0], TrackingServerService_SubscribeTrackingPointCommand_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &trackingServerServiceSubscribeTrackingPointCommandClient{stream} - if err := x.ClientStream.SendMsg(in); err != nil { - return nil, err - } - if err := x.ClientStream.CloseSend(); err != nil { - return nil, err - } - return x, nil -} - -type TrackingServerService_SubscribeTrackingPointCommandClient interface { - Recv() (*TrackingPointCommandResponse, error) - grpc.ClientStream -} - -type trackingServerServiceSubscribeTrackingPointCommandClient struct { - grpc.ClientStream -} - -func (x *trackingServerServiceSubscribeTrackingPointCommandClient) Recv() (*TrackingPointCommandResponse, error) { - m := new(TrackingPointCommandResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *trackingServerServiceClient) SubscribeTrackingRectangleCommand(ctx context.Context, in *SubscribeTrackingRectangleCommandRequest, opts ...grpc.CallOption) (TrackingServerService_SubscribeTrackingRectangleCommandClient, error) { - stream, err := c.cc.NewStream(ctx, &TrackingServerService_ServiceDesc.Streams[1], TrackingServerService_SubscribeTrackingRectangleCommand_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &trackingServerServiceSubscribeTrackingRectangleCommandClient{stream} - if err := x.ClientStream.SendMsg(in); err != nil { - return nil, err - } - if err := x.ClientStream.CloseSend(); err != nil { - return nil, err - } - return x, nil -} - -type TrackingServerService_SubscribeTrackingRectangleCommandClient interface { - Recv() (*TrackingRectangleCommandResponse, error) - grpc.ClientStream -} - -type trackingServerServiceSubscribeTrackingRectangleCommandClient struct { - grpc.ClientStream -} - -func (x *trackingServerServiceSubscribeTrackingRectangleCommandClient) Recv() (*TrackingRectangleCommandResponse, error) { - m := new(TrackingRectangleCommandResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *trackingServerServiceClient) SubscribeTrackingOffCommand(ctx context.Context, in *SubscribeTrackingOffCommandRequest, opts ...grpc.CallOption) (TrackingServerService_SubscribeTrackingOffCommandClient, error) { - stream, err := c.cc.NewStream(ctx, &TrackingServerService_ServiceDesc.Streams[2], TrackingServerService_SubscribeTrackingOffCommand_FullMethodName, opts...) - if err != nil { - return nil, err - } - x := &trackingServerServiceSubscribeTrackingOffCommandClient{stream} - if err := x.ClientStream.SendMsg(in); err != nil { - return nil, err - } - if err := x.ClientStream.CloseSend(); err != nil { - return nil, err - } - return x, nil -} - -type TrackingServerService_SubscribeTrackingOffCommandClient interface { - Recv() (*TrackingOffCommandResponse, error) - grpc.ClientStream -} - -type trackingServerServiceSubscribeTrackingOffCommandClient struct { - grpc.ClientStream -} - -func (x *trackingServerServiceSubscribeTrackingOffCommandClient) Recv() (*TrackingOffCommandResponse, error) { - m := new(TrackingOffCommandResponse) - if err := x.ClientStream.RecvMsg(m); err != nil { - return nil, err - } - return m, nil -} - -func (c *trackingServerServiceClient) RespondTrackingPointCommand(ctx context.Context, in *RespondTrackingPointCommandRequest, opts ...grpc.CallOption) (*RespondTrackingPointCommandResponse, error) { - out := new(RespondTrackingPointCommandResponse) - err := c.cc.Invoke(ctx, TrackingServerService_RespondTrackingPointCommand_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *trackingServerServiceClient) RespondTrackingRectangleCommand(ctx context.Context, in *RespondTrackingRectangleCommandRequest, opts ...grpc.CallOption) (*RespondTrackingRectangleCommandResponse, error) { - out := new(RespondTrackingRectangleCommandResponse) - err := c.cc.Invoke(ctx, TrackingServerService_RespondTrackingRectangleCommand_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -func (c *trackingServerServiceClient) RespondTrackingOffCommand(ctx context.Context, in *RespondTrackingOffCommandRequest, opts ...grpc.CallOption) (*RespondTrackingOffCommandResponse, error) { - out := new(RespondTrackingOffCommandResponse) - err := c.cc.Invoke(ctx, TrackingServerService_RespondTrackingOffCommand_FullMethodName, in, out, opts...) - if err != nil { - return nil, err - } - return out, nil -} - -// TrackingServerServiceServer is the server API for TrackingServerService service. -// All implementations must embed UnimplementedTrackingServerServiceServer -// for forward compatibility -type TrackingServerServiceServer interface { - // Set/update the current point tracking status. - SetTrackingPointStatus(context.Context, *SetTrackingPointStatusRequest) (*SetTrackingPointStatusResponse, error) - // Set/update the current rectangle tracking status. - SetTrackingRectangleStatus(context.Context, *SetTrackingRectangleStatusRequest) (*SetTrackingRectangleStatusResponse, error) - // Set the current tracking status to off. - SetTrackingOffStatus(context.Context, *SetTrackingOffStatusRequest) (*SetTrackingOffStatusResponse, error) - // Subscribe to incoming tracking point command. - SubscribeTrackingPointCommand(*SubscribeTrackingPointCommandRequest, TrackingServerService_SubscribeTrackingPointCommandServer) error - // Subscribe to incoming tracking rectangle command. - SubscribeTrackingRectangleCommand(*SubscribeTrackingRectangleCommandRequest, TrackingServerService_SubscribeTrackingRectangleCommandServer) error - // Subscribe to incoming tracking off command. - SubscribeTrackingOffCommand(*SubscribeTrackingOffCommandRequest, TrackingServerService_SubscribeTrackingOffCommandServer) error - // Respond to an incoming tracking point command. - RespondTrackingPointCommand(context.Context, *RespondTrackingPointCommandRequest) (*RespondTrackingPointCommandResponse, error) - // Respond to an incoming tracking rectangle command. - RespondTrackingRectangleCommand(context.Context, *RespondTrackingRectangleCommandRequest) (*RespondTrackingRectangleCommandResponse, error) - // Respond to an incoming tracking off command. - RespondTrackingOffCommand(context.Context, *RespondTrackingOffCommandRequest) (*RespondTrackingOffCommandResponse, error) - mustEmbedUnimplementedTrackingServerServiceServer() -} - -// UnimplementedTrackingServerServiceServer must be embedded to have forward compatible implementations. -type UnimplementedTrackingServerServiceServer struct { -} - -func (UnimplementedTrackingServerServiceServer) SetTrackingPointStatus(context.Context, *SetTrackingPointStatusRequest) (*SetTrackingPointStatusResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SetTrackingPointStatus not implemented") -} -func (UnimplementedTrackingServerServiceServer) SetTrackingRectangleStatus(context.Context, *SetTrackingRectangleStatusRequest) (*SetTrackingRectangleStatusResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SetTrackingRectangleStatus not implemented") -} -func (UnimplementedTrackingServerServiceServer) SetTrackingOffStatus(context.Context, *SetTrackingOffStatusRequest) (*SetTrackingOffStatusResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method SetTrackingOffStatus not implemented") -} -func (UnimplementedTrackingServerServiceServer) SubscribeTrackingPointCommand(*SubscribeTrackingPointCommandRequest, TrackingServerService_SubscribeTrackingPointCommandServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeTrackingPointCommand not implemented") -} -func (UnimplementedTrackingServerServiceServer) SubscribeTrackingRectangleCommand(*SubscribeTrackingRectangleCommandRequest, TrackingServerService_SubscribeTrackingRectangleCommandServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeTrackingRectangleCommand not implemented") -} -func (UnimplementedTrackingServerServiceServer) SubscribeTrackingOffCommand(*SubscribeTrackingOffCommandRequest, TrackingServerService_SubscribeTrackingOffCommandServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeTrackingOffCommand not implemented") -} -func (UnimplementedTrackingServerServiceServer) RespondTrackingPointCommand(context.Context, *RespondTrackingPointCommandRequest) (*RespondTrackingPointCommandResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method RespondTrackingPointCommand not implemented") -} -func (UnimplementedTrackingServerServiceServer) RespondTrackingRectangleCommand(context.Context, *RespondTrackingRectangleCommandRequest) (*RespondTrackingRectangleCommandResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method RespondTrackingRectangleCommand not implemented") -} -func (UnimplementedTrackingServerServiceServer) RespondTrackingOffCommand(context.Context, *RespondTrackingOffCommandRequest) (*RespondTrackingOffCommandResponse, error) { - return nil, status.Errorf(codes.Unimplemented, "method RespondTrackingOffCommand not implemented") -} -func (UnimplementedTrackingServerServiceServer) mustEmbedUnimplementedTrackingServerServiceServer() {} - -// UnsafeTrackingServerServiceServer may be embedded to opt out of forward compatibility for this service. -// Use of this interface is not recommended, as added methods to TrackingServerServiceServer will -// result in compilation errors. -type UnsafeTrackingServerServiceServer interface { - mustEmbedUnimplementedTrackingServerServiceServer() -} - -func RegisterTrackingServerServiceServer(s grpc.ServiceRegistrar, srv TrackingServerServiceServer) { - s.RegisterService(&TrackingServerService_ServiceDesc, srv) -} - -func _TrackingServerService_SetTrackingPointStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SetTrackingPointStatusRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(TrackingServerServiceServer).SetTrackingPointStatus(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: TrackingServerService_SetTrackingPointStatus_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(TrackingServerServiceServer).SetTrackingPointStatus(ctx, req.(*SetTrackingPointStatusRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _TrackingServerService_SetTrackingRectangleStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SetTrackingRectangleStatusRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(TrackingServerServiceServer).SetTrackingRectangleStatus(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: TrackingServerService_SetTrackingRectangleStatus_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(TrackingServerServiceServer).SetTrackingRectangleStatus(ctx, req.(*SetTrackingRectangleStatusRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _TrackingServerService_SetTrackingOffStatus_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(SetTrackingOffStatusRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(TrackingServerServiceServer).SetTrackingOffStatus(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: TrackingServerService_SetTrackingOffStatus_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(TrackingServerServiceServer).SetTrackingOffStatus(ctx, req.(*SetTrackingOffStatusRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _TrackingServerService_SubscribeTrackingPointCommand_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeTrackingPointCommandRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(TrackingServerServiceServer).SubscribeTrackingPointCommand(m, &trackingServerServiceSubscribeTrackingPointCommandServer{stream}) -} - -type TrackingServerService_SubscribeTrackingPointCommandServer interface { - Send(*TrackingPointCommandResponse) error - grpc.ServerStream -} - -type trackingServerServiceSubscribeTrackingPointCommandServer struct { - grpc.ServerStream -} - -func (x *trackingServerServiceSubscribeTrackingPointCommandServer) Send(m *TrackingPointCommandResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _TrackingServerService_SubscribeTrackingRectangleCommand_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeTrackingRectangleCommandRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(TrackingServerServiceServer).SubscribeTrackingRectangleCommand(m, &trackingServerServiceSubscribeTrackingRectangleCommandServer{stream}) -} - -type TrackingServerService_SubscribeTrackingRectangleCommandServer interface { - Send(*TrackingRectangleCommandResponse) error - grpc.ServerStream -} - -type trackingServerServiceSubscribeTrackingRectangleCommandServer struct { - grpc.ServerStream -} - -func (x *trackingServerServiceSubscribeTrackingRectangleCommandServer) Send(m *TrackingRectangleCommandResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _TrackingServerService_SubscribeTrackingOffCommand_Handler(srv interface{}, stream grpc.ServerStream) error { - m := new(SubscribeTrackingOffCommandRequest) - if err := stream.RecvMsg(m); err != nil { - return err - } - return srv.(TrackingServerServiceServer).SubscribeTrackingOffCommand(m, &trackingServerServiceSubscribeTrackingOffCommandServer{stream}) -} - -type TrackingServerService_SubscribeTrackingOffCommandServer interface { - Send(*TrackingOffCommandResponse) error - grpc.ServerStream -} - -type trackingServerServiceSubscribeTrackingOffCommandServer struct { - grpc.ServerStream -} - -func (x *trackingServerServiceSubscribeTrackingOffCommandServer) Send(m *TrackingOffCommandResponse) error { - return x.ServerStream.SendMsg(m) -} - -func _TrackingServerService_RespondTrackingPointCommand_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(RespondTrackingPointCommandRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(TrackingServerServiceServer).RespondTrackingPointCommand(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: TrackingServerService_RespondTrackingPointCommand_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(TrackingServerServiceServer).RespondTrackingPointCommand(ctx, req.(*RespondTrackingPointCommandRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _TrackingServerService_RespondTrackingRectangleCommand_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(RespondTrackingRectangleCommandRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(TrackingServerServiceServer).RespondTrackingRectangleCommand(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: TrackingServerService_RespondTrackingRectangleCommand_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(TrackingServerServiceServer).RespondTrackingRectangleCommand(ctx, req.(*RespondTrackingRectangleCommandRequest)) - } - return interceptor(ctx, in, info, handler) -} - -func _TrackingServerService_RespondTrackingOffCommand_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(RespondTrackingOffCommandRequest) - if err := dec(in); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(TrackingServerServiceServer).RespondTrackingOffCommand(ctx, in) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: TrackingServerService_RespondTrackingOffCommand_FullMethodName, - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(TrackingServerServiceServer).RespondTrackingOffCommand(ctx, req.(*RespondTrackingOffCommandRequest)) - } - return interceptor(ctx, in, info, handler) -} - -// TrackingServerService_ServiceDesc is the grpc.ServiceDesc for TrackingServerService service. -// It's only intended for direct use with grpc.RegisterService, -// and not to be introspected or modified (even as a copy) -var TrackingServerService_ServiceDesc = grpc.ServiceDesc{ - ServiceName: "mavsdk.rpc.tracking_server.TrackingServerService", - HandlerType: (*TrackingServerServiceServer)(nil), - Methods: []grpc.MethodDesc{ - { - MethodName: "SetTrackingPointStatus", - Handler: _TrackingServerService_SetTrackingPointStatus_Handler, - }, - { - MethodName: "SetTrackingRectangleStatus", - Handler: _TrackingServerService_SetTrackingRectangleStatus_Handler, - }, - { - MethodName: "SetTrackingOffStatus", - Handler: _TrackingServerService_SetTrackingOffStatus_Handler, - }, - { - MethodName: "RespondTrackingPointCommand", - Handler: _TrackingServerService_RespondTrackingPointCommand_Handler, - }, - { - MethodName: "RespondTrackingRectangleCommand", - Handler: _TrackingServerService_RespondTrackingRectangleCommand_Handler, - }, - { - MethodName: "RespondTrackingOffCommand", - Handler: _TrackingServerService_RespondTrackingOffCommand_Handler, - }, - }, - Streams: []grpc.StreamDesc{ - { - StreamName: "SubscribeTrackingPointCommand", - Handler: _TrackingServerService_SubscribeTrackingPointCommand_Handler, - ServerStreams: true, - }, - { - StreamName: "SubscribeTrackingRectangleCommand", - Handler: _TrackingServerService_SubscribeTrackingRectangleCommand_Handler, - ServerStreams: true, - }, - { - StreamName: "SubscribeTrackingOffCommand", - Handler: _TrackingServerService_SubscribeTrackingOffCommand_Handler, - ServerStreams: true, - }, - }, - Metadata: "tracking_server.proto", -} diff --git a/Sources/transponder/transponder.go b/Sources/transponder/transponder.go index f3d5f0d..3eb54dd 100644 --- a/Sources/transponder/transponder.go +++ b/Sources/transponder/transponder.go @@ -2,11 +2,11 @@ package transponder import ( "context" - "fmt" "io" + "log" - "google.golang.org/grpc/status" codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to 'transponder' updates. - - +Transponder Subscribe to 'transponder' updates. */ +func (a *ServiceImpl) Transponder( + ctx context.Context, -func (a *ServiceImpl) Transponder(ctx context.Context) (<-chan *AdsbVehicle, error) { +) (<-chan *AdsbVehicle, error) { ch := make(chan *AdsbVehicle) request := &SubscribeTransponderRequest{} stream, err := a.Client.SubscribeTransponder(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) Transponder(ctx context.Context) (<-chan *AdsbVehicle, err if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Transponder messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Transponder messages, err: %v", err) } ch <- m.GetTransponder() } @@ -48,19 +47,16 @@ func (a *ServiceImpl) Transponder(ctx context.Context) (<-chan *AdsbVehicle, err } /* - Set rate to 'transponder' updates. - - Parameters - ---------- - rateHz float64 - - +SetRateTransponder Set rate to 'transponder' updates. */ +func (s *ServiceImpl) SetRateTransponder( + ctx context.Context, + rateHz float64, -func (s *ServiceImpl) SetRateTransponder(ctx context.Context, rateHz float64) (*SetRateTransponderResponse, error) { - - request := &SetRateTransponderRequest{} - request.RateHz = rateHz +) (*SetRateTransponderResponse, error) { + request := &SetRateTransponderRequest{ + RateHz: rateHz, + } response, err := s.Client.SetRateTransponder(ctx, request) if err != nil { return nil, err diff --git a/Sources/transponder/transponder.pb.go b/Sources/transponder/transponder.pb.go index 7f8f96e..e0820f4 100644 --- a/Sources/transponder/transponder.pb.go +++ b/Sources/transponder/transponder.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: transponder.proto package transponder import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -238,11 +239,9 @@ type SubscribeTransponderRequest struct { func (x *SubscribeTransponderRequest) Reset() { *x = SubscribeTransponderRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_transponder_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_transponder_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeTransponderRequest) String() string { @@ -253,7 +252,7 @@ func (*SubscribeTransponderRequest) ProtoMessage() {} func (x *SubscribeTransponderRequest) ProtoReflect() protoreflect.Message { mi := &file_transponder_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -278,11 +277,9 @@ type TransponderResponse struct { func (x *TransponderResponse) Reset() { *x = TransponderResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_transponder_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_transponder_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TransponderResponse) String() string { @@ -293,7 +290,7 @@ func (*TransponderResponse) ProtoMessage() {} func (x *TransponderResponse) ProtoReflect() protoreflect.Message { mi := &file_transponder_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -325,11 +322,9 @@ type SetRateTransponderRequest struct { func (x *SetRateTransponderRequest) Reset() { *x = SetRateTransponderRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_transponder_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_transponder_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateTransponderRequest) String() string { @@ -340,7 +335,7 @@ func (*SetRateTransponderRequest) ProtoMessage() {} func (x *SetRateTransponderRequest) ProtoReflect() protoreflect.Message { mi := &file_transponder_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -372,11 +367,9 @@ type SetRateTransponderResponse struct { func (x *SetRateTransponderResponse) Reset() { *x = SetRateTransponderResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_transponder_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_transponder_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SetRateTransponderResponse) String() string { @@ -387,7 +380,7 @@ func (*SetRateTransponderResponse) ProtoMessage() {} func (x *SetRateTransponderResponse) ProtoReflect() protoreflect.Message { mi := &file_transponder_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -431,11 +424,9 @@ type AdsbVehicle struct { func (x *AdsbVehicle) Reset() { *x = AdsbVehicle{} - if protoimpl.UnsafeEnabled { - mi := &file_transponder_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_transponder_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AdsbVehicle) String() string { @@ -446,7 +437,7 @@ func (*AdsbVehicle) ProtoMessage() {} func (x *AdsbVehicle) ProtoReflect() protoreflect.Message { mi := &file_transponder_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -557,11 +548,9 @@ type TransponderResult struct { func (x *TransponderResult) Reset() { *x = TransponderResult{} - if protoimpl.UnsafeEnabled { - mi := &file_transponder_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_transponder_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TransponderResult) String() string { @@ -572,7 +561,7 @@ func (*TransponderResult) ProtoMessage() {} func (x *TransponderResult) ProtoReflect() protoreflect.Message { mi := &file_transponder_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -796,80 +785,6 @@ func file_transponder_proto_init() { if File_transponder_proto != nil { return } - if !protoimpl.UnsafeEnabled { - file_transponder_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeTransponderRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_transponder_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*TransponderResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_transponder_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*SetRateTransponderRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_transponder_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*SetRateTransponderResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_transponder_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*AdsbVehicle); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_transponder_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*TransponderResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/transponder/transponder_grpc.pb.go b/Sources/transponder/transponder_grpc.pb.go index c6cc698..6dedf48 100644 --- a/Sources/transponder/transponder_grpc.pb.go +++ b/Sources/transponder/transponder_grpc.pb.go @@ -8,6 +8,7 @@ package transponder import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/tune/tune.go b/Sources/tune/tune.go index 371ae0f..83c72ea 100644 --- a/Sources/tune/tune.go +++ b/Sources/tune/tune.go @@ -9,21 +9,16 @@ type ServiceImpl struct { } /* - Send a tune to be played by the system. - - Parameters - ---------- - tuneDescription *TuneDescription - - - +PlayTune Send a tune to be played by the system. */ +func (s *ServiceImpl) PlayTune( + ctx context.Context, + tuneDescription *TuneDescription, -func (s *ServiceImpl) PlayTune(ctx context.Context, tuneDescription *TuneDescription) (*PlayTuneResponse, error) { - - request := &PlayTuneRequest{} - request.TuneDescription = tuneDescription - +) (*PlayTuneResponse, error) { + request := &PlayTuneRequest{ + TuneDescription: tuneDescription, + } response, err := s.Client.PlayTune(ctx, request) if err != nil { return nil, err diff --git a/Sources/tune/tune.pb.go b/Sources/tune/tune.pb.go index 6ea215e..34234e4 100644 --- a/Sources/tune/tune.pb.go +++ b/Sources/tune/tune.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: tune.proto package tune import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -193,11 +194,9 @@ type PlayTuneRequest struct { func (x *PlayTuneRequest) Reset() { *x = PlayTuneRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_tune_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_tune_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PlayTuneRequest) String() string { @@ -208,7 +207,7 @@ func (*PlayTuneRequest) ProtoMessage() {} func (x *PlayTuneRequest) ProtoReflect() protoreflect.Message { mi := &file_tune_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -240,11 +239,9 @@ type PlayTuneResponse struct { func (x *PlayTuneResponse) Reset() { *x = PlayTuneResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_tune_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_tune_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *PlayTuneResponse) String() string { @@ -255,7 +252,7 @@ func (*PlayTuneResponse) ProtoMessage() {} func (x *PlayTuneResponse) ProtoReflect() protoreflect.Message { mi := &file_tune_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -289,11 +286,9 @@ type TuneDescription struct { func (x *TuneDescription) Reset() { *x = TuneDescription{} - if protoimpl.UnsafeEnabled { - mi := &file_tune_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_tune_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TuneDescription) String() string { @@ -304,7 +299,7 @@ func (*TuneDescription) ProtoMessage() {} func (x *TuneDescription) ProtoReflect() protoreflect.Message { mi := &file_tune_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -344,11 +339,9 @@ type TuneResult struct { func (x *TuneResult) Reset() { *x = TuneResult{} - if protoimpl.UnsafeEnabled { - mi := &file_tune_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_tune_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *TuneResult) String() string { @@ -359,7 +352,7 @@ func (*TuneResult) ProtoMessage() {} func (x *TuneResult) ProtoReflect() protoreflect.Message { mi := &file_tune_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -515,56 +508,6 @@ func file_tune_proto_init() { if File_tune_proto != nil { return } - if !protoimpl.UnsafeEnabled { - file_tune_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*PlayTuneRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tune_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*PlayTuneResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tune_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*TuneDescription); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_tune_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*TuneResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/tune/tune_grpc.pb.go b/Sources/tune/tune_grpc.pb.go index 91736dc..3710210 100644 --- a/Sources/tune/tune_grpc.pb.go +++ b/Sources/tune/tune_grpc.pb.go @@ -8,6 +8,7 @@ package tune import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/Sources/winch/winch.go b/Sources/winch/winch.go index dc3ded3..226f2aa 100644 --- a/Sources/winch/winch.go +++ b/Sources/winch/winch.go @@ -2,11 +2,11 @@ package winch import ( "context" - "fmt" "io" + "log" codes "google.golang.org/grpc/codes" - "google.golang.org/grpc/status" + status "google.golang.org/grpc/status" ) type ServiceImpl struct { @@ -14,12 +14,12 @@ type ServiceImpl struct { } /* - Subscribe to 'winch status' updates. - - +Status Subscribe to 'winch status' updates. */ +func (a *ServiceImpl) Status( + ctx context.Context, -func (a *ServiceImpl) Status(ctx context.Context) (<-chan *Status, error) { +) (<-chan *Status, error) { ch := make(chan *Status) request := &SubscribeStatusRequest{} stream, err := a.Client.SubscribeStatus(ctx, request) @@ -38,8 +38,7 @@ func (a *ServiceImpl) Status(ctx context.Context) (<-chan *Status, error) { if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { return } - fmt.Printf("Unable to receive Status messages, err: %v\n", err) - break + log.Fatalf("Unable to receive Status messages, err: %v", err) } ch <- m.GetStatus() } @@ -48,19 +47,16 @@ func (a *ServiceImpl) Status(ctx context.Context) (<-chan *Status, error) { } /* - Allow motor to freewheel. - - Parameters - ---------- - instance uint32 - - +Relax Allow motor to freewheel. */ +func (s *ServiceImpl) Relax( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Relax(ctx context.Context, instance uint32) (*RelaxResponse, error) { - - request := &RelaxRequest{} - request.Instance = instance +) (*RelaxResponse, error) { + request := &RelaxRequest{ + Instance: instance, + } response, err := s.Client.Relax(ctx, request) if err != nil { return nil, err @@ -69,25 +65,20 @@ func (s *ServiceImpl) Relax(ctx context.Context, instance uint32) (*RelaxRespons } /* - Wind or unwind specified length of line, optionally using specified rate. - - Parameters - ---------- - instance uint32 - - lengthM float32 - - rateMS float32 - - +RelativeLengthControl Wind or unwind specified length of line, optionally using specified rate. */ - -func (s *ServiceImpl) RelativeLengthControl(ctx context.Context, instance uint32, lengthM float32, rateMS float32) (*RelativeLengthControlResponse, error) { - - request := &RelativeLengthControlRequest{} - request.Instance = instance - request.LengthM = lengthM - request.RateMS = rateMS +func (s *ServiceImpl) RelativeLengthControl( + ctx context.Context, + instance uint32, + lengthM float32, + rateMS float32, + +) (*RelativeLengthControlResponse, error) { + request := &RelativeLengthControlRequest{ + Instance: instance, + LengthM: lengthM, + RateMS: rateMS, + } response, err := s.Client.RelativeLengthControl(ctx, request) if err != nil { return nil, err @@ -96,22 +87,18 @@ func (s *ServiceImpl) RelativeLengthControl(ctx context.Context, instance uint32 } /* - Wind or unwind line at specified rate. - - Parameters - ---------- - instance uint32 - - rateMS float32 - - +RateControl Wind or unwind line at specified rate. */ - -func (s *ServiceImpl) RateControl(ctx context.Context, instance uint32, rateMS float32) (*RateControlResponse, error) { - - request := &RateControlRequest{} - request.Instance = instance - request.RateMS = rateMS +func (s *ServiceImpl) RateControl( + ctx context.Context, + instance uint32, + rateMS float32, + +) (*RateControlResponse, error) { + request := &RateControlRequest{ + Instance: instance, + RateMS: rateMS, + } response, err := s.Client.RateControl(ctx, request) if err != nil { return nil, err @@ -120,19 +107,16 @@ func (s *ServiceImpl) RateControl(ctx context.Context, instance uint32, rateMS f } /* - Perform the locking sequence to relieve motor while in the fully retracted position. - - Parameters - ---------- - instance uint32 - - +Lock Perform the locking sequence to relieve motor while in the fully retracted position. */ +func (s *ServiceImpl) Lock( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Lock(ctx context.Context, instance uint32) (*LockResponse, error) { - - request := &LockRequest{} - request.Instance = instance +) (*LockResponse, error) { + request := &LockRequest{ + Instance: instance, + } response, err := s.Client.Lock(ctx, request) if err != nil { return nil, err @@ -141,19 +125,16 @@ func (s *ServiceImpl) Lock(ctx context.Context, instance uint32) (*LockResponse, } /* - Sequence of drop, slow down, touch down, reel up, lock. - - Parameters - ---------- - instance uint32 - - +Deliver Sequence of drop, slow down, touch down, reel up, lock. */ +func (s *ServiceImpl) Deliver( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Deliver(ctx context.Context, instance uint32) (*DeliverResponse, error) { - - request := &DeliverRequest{} - request.Instance = instance +) (*DeliverResponse, error) { + request := &DeliverRequest{ + Instance: instance, + } response, err := s.Client.Deliver(ctx, request) if err != nil { return nil, err @@ -162,19 +143,16 @@ func (s *ServiceImpl) Deliver(ctx context.Context, instance uint32) (*DeliverRes } /* - Engage motor and hold current position. - - Parameters - ---------- - instance uint32 - - +Hold Engage motor and hold current position. */ +func (s *ServiceImpl) Hold( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Hold(ctx context.Context, instance uint32) (*HoldResponse, error) { - - request := &HoldRequest{} - request.Instance = instance +) (*HoldResponse, error) { + request := &HoldRequest{ + Instance: instance, + } response, err := s.Client.Hold(ctx, request) if err != nil { return nil, err @@ -183,19 +161,16 @@ func (s *ServiceImpl) Hold(ctx context.Context, instance uint32) (*HoldResponse, } /* - Return the reel to the fully retracted position. - - Parameters - ---------- - instance uint32 - - +Retract Return the reel to the fully retracted position. */ +func (s *ServiceImpl) Retract( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) Retract(ctx context.Context, instance uint32) (*RetractResponse, error) { - - request := &RetractRequest{} - request.Instance = instance +) (*RetractResponse, error) { + request := &RetractRequest{ + Instance: instance, + } response, err := s.Client.Retract(ctx, request) if err != nil { return nil, err @@ -204,21 +179,18 @@ func (s *ServiceImpl) Retract(ctx context.Context, instance uint32) (*RetractRes } /* - Load the reel with line. - - The winch will calculate the total loaded length and stop when the tension exceeds a threshold. - - Parameters - ---------- - instance uint32 - +LoadLine Load the reel with line. + The winch will calculate the total loaded length and stop when the tension exceeds a threshold. */ +func (s *ServiceImpl) LoadLine( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) LoadLine(ctx context.Context, instance uint32) (*LoadLineResponse, error) { - - request := &LoadLineRequest{} - request.Instance = instance +) (*LoadLineResponse, error) { + request := &LoadLineRequest{ + Instance: instance, + } response, err := s.Client.LoadLine(ctx, request) if err != nil { return nil, err @@ -227,19 +199,16 @@ func (s *ServiceImpl) LoadLine(ctx context.Context, instance uint32) (*LoadLineR } /* - Spool out the entire length of the line. - - Parameters - ---------- - instance uint32 - - +AbandonLine Spool out the entire length of the line. */ +func (s *ServiceImpl) AbandonLine( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) AbandonLine(ctx context.Context, instance uint32) (*AbandonLineResponse, error) { - - request := &AbandonLineRequest{} - request.Instance = instance +) (*AbandonLineResponse, error) { + request := &AbandonLineRequest{ + Instance: instance, + } response, err := s.Client.AbandonLine(ctx, request) if err != nil { return nil, err @@ -248,19 +217,16 @@ func (s *ServiceImpl) AbandonLine(ctx context.Context, instance uint32) (*Abando } /* - Spools out just enough to present the hook to the user to load the payload. - - Parameters - ---------- - instance uint32 - - +LoadPayload Spools out just enough to present the hook to the user to load the payload. */ +func (s *ServiceImpl) LoadPayload( + ctx context.Context, + instance uint32, -func (s *ServiceImpl) LoadPayload(ctx context.Context, instance uint32) (*LoadPayloadResponse, error) { - - request := &LoadPayloadRequest{} - request.Instance = instance +) (*LoadPayloadResponse, error) { + request := &LoadPayloadRequest{ + Instance: instance, + } response, err := s.Client.LoadPayload(ctx, request) if err != nil { return nil, err diff --git a/Sources/winch/winch.pb.go b/Sources/winch/winch.pb.go index 5b76666..206641b 100644 --- a/Sources/winch/winch.pb.go +++ b/Sources/winch/winch.pb.go @@ -1,16 +1,17 @@ // Code generated by protoc-gen-go. DO NOT EDIT. // versions: -// protoc-gen-go v1.34.2 +// protoc-gen-go v1.35.2 // protoc v3.12.4 // source: winch.proto package winch import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" reflect "reflect" sync "sync" + + protoreflect "google.golang.org/protobuf/reflect/protoreflect" + protoimpl "google.golang.org/protobuf/runtime/protoimpl" ) const ( @@ -161,11 +162,9 @@ type SubscribeStatusRequest struct { func (x *SubscribeStatusRequest) Reset() { *x = SubscribeStatusRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[0] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *SubscribeStatusRequest) String() string { @@ -176,7 +175,7 @@ func (*SubscribeStatusRequest) ProtoMessage() {} func (x *SubscribeStatusRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[0] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -201,11 +200,9 @@ type StatusResponse struct { func (x *StatusResponse) Reset() { *x = StatusResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StatusResponse) String() string { @@ -216,7 +213,7 @@ func (*StatusResponse) ProtoMessage() {} func (x *StatusResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[1] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -268,11 +265,9 @@ type StatusFlags struct { func (x *StatusFlags) Reset() { *x = StatusFlags{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *StatusFlags) String() string { @@ -283,7 +278,7 @@ func (*StatusFlags) ProtoMessage() {} func (x *StatusFlags) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[2] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -414,11 +409,9 @@ type Status struct { func (x *Status) Reset() { *x = Status{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *Status) String() string { @@ -429,7 +422,7 @@ func (*Status) ProtoMessage() {} func (x *Status) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[3] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -510,11 +503,9 @@ type RelaxRequest struct { func (x *RelaxRequest) Reset() { *x = RelaxRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RelaxRequest) String() string { @@ -525,7 +516,7 @@ func (*RelaxRequest) ProtoMessage() {} func (x *RelaxRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[4] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -557,11 +548,9 @@ type RelaxResponse struct { func (x *RelaxResponse) Reset() { *x = RelaxResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RelaxResponse) String() string { @@ -572,7 +561,7 @@ func (*RelaxResponse) ProtoMessage() {} func (x *RelaxResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[5] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -606,11 +595,9 @@ type RelativeLengthControlRequest struct { func (x *RelativeLengthControlRequest) Reset() { *x = RelativeLengthControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RelativeLengthControlRequest) String() string { @@ -621,7 +608,7 @@ func (*RelativeLengthControlRequest) ProtoMessage() {} func (x *RelativeLengthControlRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[6] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -667,11 +654,9 @@ type RelativeLengthControlResponse struct { func (x *RelativeLengthControlResponse) Reset() { *x = RelativeLengthControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RelativeLengthControlResponse) String() string { @@ -682,7 +667,7 @@ func (*RelativeLengthControlResponse) ProtoMessage() {} func (x *RelativeLengthControlResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[7] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -715,11 +700,9 @@ type RateControlRequest struct { func (x *RateControlRequest) Reset() { *x = RateControlRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RateControlRequest) String() string { @@ -730,7 +713,7 @@ func (*RateControlRequest) ProtoMessage() {} func (x *RateControlRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[8] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -769,11 +752,9 @@ type RateControlResponse struct { func (x *RateControlResponse) Reset() { *x = RateControlResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RateControlResponse) String() string { @@ -784,7 +765,7 @@ func (*RateControlResponse) ProtoMessage() {} func (x *RateControlResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[9] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -816,11 +797,9 @@ type LockRequest struct { func (x *LockRequest) Reset() { *x = LockRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LockRequest) String() string { @@ -831,7 +810,7 @@ func (*LockRequest) ProtoMessage() {} func (x *LockRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[10] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -863,11 +842,9 @@ type LockResponse struct { func (x *LockResponse) Reset() { *x = LockResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LockResponse) String() string { @@ -878,7 +855,7 @@ func (*LockResponse) ProtoMessage() {} func (x *LockResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[11] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -910,11 +887,9 @@ type DeliverRequest struct { func (x *DeliverRequest) Reset() { *x = DeliverRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DeliverRequest) String() string { @@ -925,7 +900,7 @@ func (*DeliverRequest) ProtoMessage() {} func (x *DeliverRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -957,11 +932,9 @@ type DeliverResponse struct { func (x *DeliverResponse) Reset() { *x = DeliverResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *DeliverResponse) String() string { @@ -972,7 +945,7 @@ func (*DeliverResponse) ProtoMessage() {} func (x *DeliverResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[13] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1004,11 +977,9 @@ type HoldRequest struct { func (x *HoldRequest) Reset() { *x = HoldRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HoldRequest) String() string { @@ -1019,7 +990,7 @@ func (*HoldRequest) ProtoMessage() {} func (x *HoldRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[14] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1051,11 +1022,9 @@ type HoldResponse struct { func (x *HoldResponse) Reset() { *x = HoldResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *HoldResponse) String() string { @@ -1066,7 +1035,7 @@ func (*HoldResponse) ProtoMessage() {} func (x *HoldResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[15] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1098,11 +1067,9 @@ type RetractRequest struct { func (x *RetractRequest) Reset() { *x = RetractRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetractRequest) String() string { @@ -1113,7 +1080,7 @@ func (*RetractRequest) ProtoMessage() {} func (x *RetractRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[16] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1145,11 +1112,9 @@ type RetractResponse struct { func (x *RetractResponse) Reset() { *x = RetractResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *RetractResponse) String() string { @@ -1160,7 +1125,7 @@ func (*RetractResponse) ProtoMessage() {} func (x *RetractResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[17] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1192,11 +1157,9 @@ type LoadLineRequest struct { func (x *LoadLineRequest) Reset() { *x = LoadLineRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LoadLineRequest) String() string { @@ -1207,7 +1170,7 @@ func (*LoadLineRequest) ProtoMessage() {} func (x *LoadLineRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[18] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1239,11 +1202,9 @@ type LoadLineResponse struct { func (x *LoadLineResponse) Reset() { *x = LoadLineResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[19] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LoadLineResponse) String() string { @@ -1254,7 +1215,7 @@ func (*LoadLineResponse) ProtoMessage() {} func (x *LoadLineResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[19] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1286,11 +1247,9 @@ type AbandonLineRequest struct { func (x *AbandonLineRequest) Reset() { *x = AbandonLineRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[20] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AbandonLineRequest) String() string { @@ -1301,7 +1260,7 @@ func (*AbandonLineRequest) ProtoMessage() {} func (x *AbandonLineRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[20] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1333,11 +1292,9 @@ type AbandonLineResponse struct { func (x *AbandonLineResponse) Reset() { *x = AbandonLineResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[21] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[21] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *AbandonLineResponse) String() string { @@ -1348,7 +1305,7 @@ func (*AbandonLineResponse) ProtoMessage() {} func (x *AbandonLineResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[21] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1380,11 +1337,9 @@ type LoadPayloadRequest struct { func (x *LoadPayloadRequest) Reset() { *x = LoadPayloadRequest{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[22] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[22] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LoadPayloadRequest) String() string { @@ -1395,7 +1350,7 @@ func (*LoadPayloadRequest) ProtoMessage() {} func (x *LoadPayloadRequest) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[22] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1427,11 +1382,9 @@ type LoadPayloadResponse struct { func (x *LoadPayloadResponse) Reset() { *x = LoadPayloadResponse{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[23] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *LoadPayloadResponse) String() string { @@ -1442,7 +1395,7 @@ func (*LoadPayloadResponse) ProtoMessage() {} func (x *LoadPayloadResponse) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[23] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1476,11 +1429,9 @@ type WinchResult struct { func (x *WinchResult) Reset() { *x = WinchResult{} - if protoimpl.UnsafeEnabled { - mi := &file_winch_proto_msgTypes[24] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } + mi := &file_winch_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } func (x *WinchResult) String() string { @@ -1491,7 +1442,7 @@ func (*WinchResult) ProtoMessage() {} func (x *WinchResult) ProtoReflect() protoreflect.Message { mi := &file_winch_proto_msgTypes[24] - if protoimpl.UnsafeEnabled && x != nil { + if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { ms.StoreMessageInfo(mi) @@ -1861,309 +1812,6 @@ func file_winch_proto_init() { if File_winch_proto != nil { return } - - if !protoimpl.UnsafeEnabled { - file_winch_proto_msgTypes[0].Exporter = func(v any, i int) any { - switch v := v.(*SubscribeStatusRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[1].Exporter = func(v any, i int) any { - switch v := v.(*StatusResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*StatusFlags); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[3].Exporter = func(v any, i int) any { - switch v := v.(*Status); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[4].Exporter = func(v any, i int) any { - switch v := v.(*RelaxRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[5].Exporter = func(v any, i int) any { - switch v := v.(*RelaxResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[6].Exporter = func(v any, i int) any { - switch v := v.(*RelativeLengthControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*RelativeLengthControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*RateControlRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*RateControlResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*LockRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*LockResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*DeliverRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[13].Exporter = func(v any, i int) any { - switch v := v.(*DeliverResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[14].Exporter = func(v any, i int) any { - switch v := v.(*HoldRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[15].Exporter = func(v any, i int) any { - switch v := v.(*HoldResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[16].Exporter = func(v any, i int) any { - switch v := v.(*RetractRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[17].Exporter = func(v any, i int) any { - switch v := v.(*RetractResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[18].Exporter = func(v any, i int) any { - switch v := v.(*LoadLineRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[19].Exporter = func(v any, i int) any { - switch v := v.(*LoadLineResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[20].Exporter = func(v any, i int) any { - switch v := v.(*AbandonLineRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[21].Exporter = func(v any, i int) any { - switch v := v.(*AbandonLineResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[22].Exporter = func(v any, i int) any { - switch v := v.(*LoadPayloadRequest); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[23].Exporter = func(v any, i int) any { - switch v := v.(*LoadPayloadResponse); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_winch_proto_msgTypes[24].Exporter = func(v any, i int) any { - switch v := v.(*WinchResult); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ diff --git a/Sources/winch/winch_grpc.pb.go b/Sources/winch/winch_grpc.pb.go index 090f22a..2e9f24d 100644 --- a/Sources/winch/winch_grpc.pb.go +++ b/Sources/winch/winch_grpc.pb.go @@ -8,6 +8,7 @@ package winch import ( context "context" + grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" diff --git a/templates/call.j2 b/templates/call.j2 index c5f6a21..ce73a41 100644 --- a/templates/call.j2 +++ b/templates/call.j2 @@ -1,39 +1,14 @@ -/* - {{ indent(method_description, 1) }} - - {% if params -%} - Parameters - ---------- - {% for param in params %} - {%- if param.type_info.is_primitive -%} - {{ param.name.lower_camel_case }} {{ param.type_info.name }} - {%- elif param.type_info.is_repeated -%} - {{ param.name.lower_camel_case }} {{ param.type_info.name }} - {%- else -%} - {{ param.name.lower_camel_case }} *{{ param.type_info.name }} - {% endif %} - - {% endfor %} - {%- endif %} -*/ - -func(s *ServiceImpl){{ name.upper_camel_case }}(ctx context.Context, {% for param in params %}{%- if param.type_info.is_primitive -%}{{ param.name.lower_camel_case }} {{ param.type_info.name }}{%- elif param.type_info.is_repeated -%} {{ param.name.lower_camel_case }} {{ param.type_info.name }} {%- else -%} {{ param.name.lower_camel_case }} *{{ param.type_info.name }} {% endif %}{{ ", " if not loop.last }}{% endfor %})(*{{ name.upper_camel_case }}Response, error){ - - request := &{{ name.upper_camel_case }}Request{} - {% for param in params %} - {%- if param.type_info.is_primitive -%} - request.{{ param.name.upper_camel_case }} = {{ param.name.lower_camel_case }} - {%- elif param.type_info.is_enum -%} - request.{{ param.name.upper_camel_case }} = *{{ param.name.lower_camel_case }} - {%- else -%} - request.{{param.name.upper_camel_case}} = {{param.name.lower_camel_case}} - {% endif %} - {% endfor -%} +{% include 'func_desc_macro.j2' %} +func (s *ServiceImpl) {{ name.upper_camel_case }}( + ctx context.Context, + {% include 'func_param_macro.j2' %} +) (*{{ name.upper_camel_case }}Response, error) { + request := &{{ name.upper_camel_case }}Request{ + {% include 'object_init_macro.j2' %} + } response, err := s.Client.{{ name.upper_camel_case }}(ctx, request) if err != nil { - return nil, err + return nil, err } return response, nil -} - - \ No newline at end of file +} \ No newline at end of file diff --git a/templates/func_desc_macro.j2 b/templates/func_desc_macro.j2 new file mode 100644 index 0000000..754f01d --- /dev/null +++ b/templates/func_desc_macro.j2 @@ -0,0 +1,3 @@ +/* +{{ name.upper_camel_case }} {{ indent(method_description, 0) }} +*/ \ No newline at end of file diff --git a/templates/func_param_macro.j2 b/templates/func_param_macro.j2 new file mode 100644 index 0000000..8dae812 --- /dev/null +++ b/templates/func_param_macro.j2 @@ -0,0 +1,13 @@ +{% for param in params %} + {%- if param.name.lower_camel_case == 'range' %} + rangeVar {{ param.type_info.name }}, + {%- elif param.name.lower_camel_case == 'type' %} + typeVar {{ param.type_info.name }}, + {%- elif param.type_info.is_primitive -%} + {{ param.name.lower_camel_case }} {{ param.type_info.name }}, + {%- elif param.type_info.is_repeated -%} + {{ param.name.lower_camel_case }} {{ param.type_info.name }}, + {%- else -%} + {{ param.name.lower_camel_case }} *{{ param.type_info.name }}, + {% endif %} +{% endfor %} \ No newline at end of file diff --git a/templates/object_init_macro.j2 b/templates/object_init_macro.j2 new file mode 100644 index 0000000..9e00108 --- /dev/null +++ b/templates/object_init_macro.j2 @@ -0,0 +1,13 @@ +{% for param in params %} + {%- if param.name.lower_camel_case == 'range' %} + {{ param.name.upper_camel_case }}: rangeVar, + {%- elif param.name.lower_camel_case == 'type' %} + {{ param.name.upper_camel_case }}: typeVar, + {%- elif param.type_info.is_primitive -%} + {{ param.name.upper_camel_case }}: {{ param.name.lower_camel_case }}, + {%- elif param.type_info.is_enum -%} + {{ param.name.upper_camel_case }}: *{{ param.name.lower_camel_case }}, + {%- else -%} + {{ param.name.upper_camel_case }}: {{ param.name.lower_camel_case }}, + {% endif %} +{% endfor %} \ No newline at end of file diff --git a/templates/request.j2 b/templates/request.j2 index b778267..e18178d 100644 --- a/templates/request.j2 +++ b/templates/request.j2 @@ -1,47 +1,17 @@ -/* - {{ indent(method_description, 1) }} - - {% if params -%} - Parameters - ---------- - {% for param in params %} - {%- if param.type_info.is_primitive -%} - {{ param.name.lower_camel_case }} {{ param.type_info.name }} - {%- elif param.type_info.is_repeated -%} - {{ param.name.lower_camel_case }} {{ param.type_info.name }} - {%- else -%} - {{ param.name.lower_camel_case }} *{{ param.type_info.name }} - {% endif -%} - {% endfor %} - {%- endif %} - - Returns - ------- - {{return_type.is_repeated}} - {{ return_name.upper_camel_case }} : {{ return_type.name }} - {{ return_description }} - {% if has_result -%} - {%- endif %} -*/ - - -func(s *ServiceImpl){{ name.upper_camel_case }}(ctx context.Context, {% for param in params %}{%- if param.type_info.is_primitive -%}{{ param.name.lower_camel_case }} {{ param.type_info.name }}{%- elif param.type_info.is_repeated -%} {{ param.name.lower_camel_case }} {{ param.type_info.name }} {%- else -%} {{ param.name.lower_camel_case }} *{{ param.type_info.name }} {% endif %}{{ ", " if not loop.last }}{% endfor %}) (*{{ name.upper_camel_case }}Response, error){ - request := &{{ name.upper_camel_case }}Request{} - {% for param in params %} - {%- if param.type_info.is_primitive -%} - request.{{ param.name.upper_camel_case }} = {{ param.name.lower_camel_case }} - {%- elif param.type_info.is_enum -%} - request.{{ param.name.upper_camel_case }} = *{{ param.name.lower_camel_case }} - {%- else -%} - request.{{param.name.upper_camel_case}} = {{param.name.lower_camel_case}} - {% endif %} - {% endfor -%} +{% include 'func_desc_macro.j2' %} +func(s *ServiceImpl) {{ name.upper_camel_case }}( + ctx context.Context, + {% include 'func_param_macro.j2' %} +) (*{{ name.upper_camel_case }}Response, error) { + request := &{{ name.upper_camel_case }}Request{ + {% include 'object_init_macro.j2' %} + } response, err := s.Client.{{ name.upper_camel_case }}(ctx, request) if err != nil { - return nil, err - } + return nil, err + } return response, nil - } + \ No newline at end of file diff --git a/templates/stream.j2 b/templates/stream.j2 index f477a52..a15aaaa 100644 --- a/templates/stream.j2 +++ b/templates/stream.j2 @@ -1,46 +1,33 @@ - - /* - {{ indent(method_description, 1) }} - - {% if params -%} - Parameters - ---------- - {% for param in params %}{%- if param.type_info.is_primitive -%}{{ param.name.lower_camel_case }} {{ param.type_info.name }}{%- elif param.type_info.is_repeated -%} {{ param.name.lower_camel_case }} {{ param.type_info.name }} {%- else -%} {{ param.name.lower_camel_case }} *{{ param.type_info.name }} {% endif %}{{ ", " if not loop.last }}{% endfor %} - - {%- endif %} -*/ - -func (a *ServiceImpl) {{ name.upper_camel_case }}(ctx context.Context, {% for param in params %}{%- if param.type_info.is_primitive -%}{{ param.name.lower_camel_case }} {{ param.type_info.name }}{%- elif param.type_info.is_repeated -%} {{ param.name.lower_camel_case }} {{ param.type_info.name }} {%- else -%} {{ param.name.lower_camel_case }} *{{ param.type_info.name }} {% endif %}{{ ", " if not loop.last }}{% endfor %}) (<-chan {% if return_type.is_repeated or return_type.is_primitive or return_type.is_enum %} {{ return_type.name }} {% else %} *{{ return_type.name }} {% endif %}, error){ - ch := make(chan {% if return_type.is_repeated or return_type.is_primitive or return_type.is_enum %} {{ return_type.name }} {% else %} *{{ return_type.name }} {% endif %}) - request := &Subscribe{{ name.upper_camel_case }}Request{} - {% for param in params %} - {%- if param.type_info.is_primitive -%} - request.{{ param.name.upper_camel_case }} = {{ param.name.lower_camel_case }} - {%- else -%} - request.{{param.name.upper_camel_case}} = {{param.name.lower_camel_case}} - {% endif %} - {% endfor -%} - stream, err := a.Client.Subscribe{{ name.upper_camel_case }}(ctx, request) - if err != nil { - return nil, err - } - go func() { - defer close(ch) - for { - m := &{{ name.upper_camel_case }}Response{} - err := stream.RecvMsg(m) - if err == io.EOF { - return - } - if err != nil { - if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { - return - } - fmt.Printf("Unable to receive {{ name.upper_camel_case }} messages, err: %v\n", err) - break - } - ch <- m.Get{{ return_name.upper_camel_case }}() - } - }() - return ch, nil +{% include 'func_desc_macro.j2' %} +func (a *ServiceImpl) {{ name.upper_camel_case }}( + ctx context.Context, + {% include 'func_param_macro.j2' %} +) (<-chan {% if return_type.is_repeated or return_type.is_primitive or return_type.is_enum %} {{ return_type.name }}, {% else %} *{{ return_type.name }}, {% endif %} error) { + ch := make(chan {% if return_type.is_repeated or return_type.is_primitive or return_type.is_enum %} {{ return_type.name }} {% else %} *{{ return_type.name }} {% endif %}) + request := &Subscribe{{ name.upper_camel_case }}Request{ + {% include 'object_init_macro.j2' %} + } + stream, err := a.Client.Subscribe{{ name.upper_camel_case }}(ctx, request) + if err != nil { + return nil, err + } + go func() { + defer close(ch) + for { + m := &{{ name.upper_camel_case }}Response{} + err := stream.RecvMsg(m) + if err == io.EOF { + return + } + if err != nil { + if s, ok := status.FromError(err); ok && s.Code() == codes.Canceled { + return + } + log.Fatalf("Unable to receive {{ name.upper_camel_case }} messages, err: %v", err) + } + ch <- m.Get{{ return_name.upper_camel_case }}() + } + }() + return ch, nil } + diff --git a/tools/Dockerfile b/tools/Dockerfile index 71e4a09..064aba0 100644 --- a/tools/Dockerfile +++ b/tools/Dockerfile @@ -1,14 +1,15 @@ # This is the docker file which is used to generate the code from proto buf files. -FROM ubuntu:22.04 +FROM --platform=linux/amd64 ubuntu:22.04 RUN apt-get update RUN apt-get install -y wget python3 python3-distutils python3-dev python3-pip RUN wget https://go.dev/dl/go1.22.3.linux-amd64.tar.gz RUN rm -rf /usr/local/go && tar -C /usr/local -xzf go1.22.3.linux-amd64.tar.gz -ENV PATH $PATH:/usr/local/go/bin +ENV PATH $PATH:/usr/local/go/bin:/root/go/bin ENV PATH="$PATH:$(go env GOPATH)/bin" RUN go install google.golang.org/protobuf/cmd/protoc-gen-go@latest RUN go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest +RUN go install golang.org/x/tools/cmd/goimports@latest # Step 4: Install the python protoc-gendcsdk plugin to generate the class RUN apt-get install -y -q python3-pip git diff --git a/tools/generate_from_protos.bash b/tools/generate_from_protos.bash index 3869cb8..ba2a6f8 100755 --- a/tools/generate_from_protos.bash +++ b/tools/generate_from_protos.bash @@ -56,6 +56,8 @@ echo "Generating proto definitions." for plugin in ${PLUGIN_LIST}; do mkdir -p ${OUTPUT_DIR}/$plugin protoc ${plugin}.proto -I${PROTO_DIR}/$plugin --go_out=${OUTPUT_DIR}/$plugin --gogrpc_out=${OUTPUT_DIR}/$plugin --plugin=protoc-gen-go=${GO_GEN_CMD} --plugin=protoc-gen-gogrpc=${GO_GEN_RPC_CMD} + ## remove file_mavsdk_options_proto_init() line from generated file + sed -i '/file_mavsdk_options_proto_init/d' ${OUTPUT_DIR}/$plugin/${plugin}.pb.go done echo "Generating final plugins." @@ -84,3 +86,15 @@ done # Remove the temp directory. rm -rf ${PROTO_DIR_TMP} + +# Navigate to OUTPUT_DIR and run the commands +if cd "$OUTPUT_DIR"; then + echo "Running goimports..." + goimports -w . + + echo "Running go fmt..." + go fmt ./... || { echo "go fmt failed"; exit 1; } +else + echo "Error: Could not navigate to OUTPUT_DIR: $OUTPUT_DIR" + exit 1 +fi diff --git a/tools/generate_only_plugins.bash b/tools/generate_only_plugins.bash index 24bcf1c..3a1c95c 100644 --- a/tools/generate_only_plugins.bash +++ b/tools/generate_only_plugins.bash @@ -45,8 +45,9 @@ for plugin in ${PLUGIN_LIST}; do echo "Renaming $actual_file_path to $new_file_path" # Move the original CamelCase file to a temporary name - mv "$actual_file_path" "$temp_file_path" - + cat "$actual_file_path" > "$temp_file_path" + # Remove the original CamelCase file + rm "$actual_file_path" # Rename the temporary file to the new name mv "$temp_file_path" "$new_file_path" @@ -54,4 +55,16 @@ for plugin in ${PLUGIN_LIST}; do done # Remove the temp directory. -rm -rf ${PROTO_DIR_TMP} \ No newline at end of file +rm -rf ${PROTO_DIR_TMP} + +# Navigate to OUTPUT_DIR and run the commands +if cd "$OUTPUT_DIR"; then + echo "Running goimports..." + goimports -w . + + echo "Running go fmt..." + go fmt ./... || { echo "go fmt failed"; exit 1; } +else + echo "Error: Could not navigate to OUTPUT_DIR: $OUTPUT_DIR" + exit 1 +fi