Conscience Core
CommandEntityLidarRelay.h
Go to the documentation of this file.
1 #ifndef CommandEntityLidarRelay_h
2 #define CommandEntityLidarRelay_h
3 
4 #include "CommandCommons.h"
5 
7 
8 ENUM(EntityLidarRelayCompression, ENTITY_LIDAR_RELAY_COMPRESSION_LZ4, ENTITY_LIDAR_RELAY_COMPRESSION_NONE)
9 
11 public:
20  const string &targetIpAddress, unsigned int targetPort,
21  optional<double> periodMillis = {}, optional<EntityLidarRelayCompression> compression = {},
22  const CscArea3d *zone = nullptr);
23 
25  unsigned targetPort;
26  double periodMillis;
27  EntityLidarRelayCompression compression;
28  const CscArea3d *zone = nullptr;
29 };
30 
43 public:
44  inline static const CommandTypeId COMMAND_ID = "ENTITY_LIDAR_RELAY";
45 
47  ~CommandEntityLidarRelay() override;
48 
49 protected:
50  const CscCommandExecutionResultString *doExecute(CscEnvironmentSimulator &environmentSimulator) override;
51 
52  ptr<CscEntityReflexion> getEntityReflexion() const override;
53 
55  CommandEntityLidarRelayParams *params = nullptr;
56  std::unique_ptr<CscLogger> logger = CscLogger::getForCategory("CommandEntityLidarRelay");
57 };
58 
63 public:
64  inline static const CommandTypeId COMMAND_ID = "ENTITY_LIDAR_RELAY_STOP";
65 
66  CommandEntityLidarRelayStop(ptr<CscEntityReflexion> entityReflexion, const string &targetIpAddress, unsigned targetPort);
67 
68 protected:
69  const CscCommandExecutionResultString *doExecute(CscEnvironmentSimulator &environmentSimulator) override;
70 
71  ptr<CscEntityReflexion> getEntityReflexion() const override;
72 
75  unsigned targetPort;
76  std::unique_ptr<CscLogger> logger = CscLogger::getForCategory("CommandEntityLidarRelayStop");
77 };
78 
79 COMMAND_TYPE_BUILDER(CommandEntityLidarRelayStop, CscArea3d, double, double, double, double, double, double)
80 COMMAND_TYPE_BUILDER(CommandEntityLidarRelayStop, CommandEntityLidarRelayParams, const string &, unsigned int, optional<double>, optional<EntityLidarRelayCompression>, const CscArea3d *)
83 
84 }
85 
86 #endif
conscience_core::bridging::commands::CommandEntityLidarRelayStop::targetIpAddress
string targetIpAddress
Definition: CommandEntityLidarRelay.h:74
conscience_core::bridging::commands::CommandEntityLidarRelayStop
Definition: CommandEntityLidarRelay.h:62
CSC_DLL_IMPORTEXPORT
#define CSC_DLL_IMPORTEXPORT
Definition: os.h:34
conscience_core::axiomes::CscArea3d
Definition: Csc3dTypes.h:243
conscience_core::bridging::commands::CommandEntityLidarRelayParams
Definition: CommandEntityLidarRelay.h:10
conscience_core::bridging::commands::CommandTypeId
string CommandTypeId
Definition: Command.h:29
conscience_core::bridging::commands::CommandEntityLidarRelayParams::targetPort
unsigned targetPort
Definition: CommandEntityLidarRelay.h:25
conscience_core::bridging::commands::CommandEntityLidarRelayParams::compression
EntityLidarRelayCompression compression
Definition: CommandEntityLidarRelay.h:27
conscience_core::bridging::commands::result::CscCommandExecutionResultString
Definition: CommandExecutionResultString.h:11
conscience_core::bridging::commands::ENUM
ENUM(CommandParamMetaType, CommandParamMetaType_double, CommandParamMetaType_float, CommandParamMetaType_int, CommandParamMetaType_long, CommandParamMetaType_unsigned_long_long, CommandParamMetaType_bool, CommandParamMetaType_string, CommandParamMetaType_list, CommandParamMetaType_map, CommandParamMetaType_object, CommandParamMetaType_optional, CommandParamMetaType_enum, CommandParamMetaType_entityReflexion, CommandParamMetaType_entityModel, CommandParamMetaType_placeModel, CommandParamMetaType_objectModel)
conscience_core::bridging::commands
Definition: cartographyCommands.cpp:29
conscience_core::bridging::commands::CscCommand
Definition: Command.h:40
conscience_core::bridging::commands::CommandEntityLidarRelayStop::targetPort
unsigned targetPort
Definition: CommandEntityLidarRelay.h:75
conscience_core::bridging::commands::environment_objects::optional< double >
const ptr< CscObjectModel > const string const CscPoint3d const CscPoint3d optional< double >
Definition: environmentObjectsCommands.h:367
conscience_core::bridging::commands::CommandEntityLidarRelay::entityReflexion
ptr< CscEntityReflexion > entityReflexion
Definition: CommandEntityLidarRelay.h:54
conscience_core::bridging::commands::CommandEntityLidarRelayParams::targetIpAddress
string targetIpAddress
Definition: CommandEntityLidarRelay.h:24
CscEnvironmentSimulator
Definition: CscEnvironmentSimulator.h:31
conscience_core::bridging::commands::COMMAND_REGISTER
COMMAND_REGISTER(CommandFollowKinematicTrajectory, ptr< CscEntityReflexion >, int, const CscState *, string, string, string, string, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float, float)
CommandCommons.h
conscience_core::bridging::commands::COMMAND_TYPE_BUILDER
COMMAND_TYPE_BUILDER(CommandVisionDetect, CscAlertIdentificationTimeSlot, int, int, int, int)
conscience_core::bridging::commands::logger
std::unique_ptr< CscLogger > logger
Definition: Command.cpp:7
conscience_core::bridging::commands::CommandEntityLidarRelayStop::entityReflexion
ptr< CscEntityReflexion > entityReflexion
Definition: CommandEntityLidarRelay.h:73
conscience_core::bridging::commands::CommandEntityLidarRelay
Definition: CommandEntityLidarRelay.h:42
ptr
std::shared_ptr< T > ptr
Definition: CscCommon.h:29
conscience_core::bridging::commands::CommandEntityLidarRelayParams::periodMillis
double periodMillis
Definition: CommandEntityLidarRelay.h:26