40 namespace data_processing {
49 const std::shared_ptr<std::vector<uint8_t>
const> vec_ptr = buffer.
getBuffer();
50 std::vector<uint8_t>::const_iterator data_ptr = vec_ptr->begin();
93 for (uint8_t i = 0; i < name_length; i++)
void setNameLength(const uint32_t &name_length)
Sets the length of the user name.
std::string readUserName(std::vector< uint8_t >::const_iterator data_ptr) const
Class containing the user name of a laser scanner.
A packetbuffer for the raw data from the sensor.
std::shared_ptr< std::vector< uint8_t > const > getBuffer() const
Getter to return a copy of the data saved in the PacketBuffer.
bool parseTCPSequence(const datastructure::PacketBuffer &buffer, datastructure::UserName &user_name) const
Parses a tcp sequence to read the type code of the sensor.
void setVersionCVersion(const std::string &version_c_version)
Sets the version indicator for the scanner.
uint32_t readUint32LittleEndian(std::vector< uint8_t >::const_iterator it)
Read an unsigned 32-bit integer at offset in little endian encoding.
uint8_t readMinorNumber(std::vector< uint8_t >::const_iterator data_ptr) const
void setVersionReleaseNumber(const uint8_t &version_release_number)
Sets the version release number for the scanner.
void setUserName(const std::string &user_name)
Sets the user name for the scanner.
ParseUserNameData()
Constructor of the parser.
void setVersionMinorVersionNumber(const uint8_t &version_minor_version_number)
Sets the minor version number for the scanner.
std::string readVersionIndicator(std::vector< uint8_t >::const_iterator data_ptr) const
uint8_t readMajorNumber(std::vector< uint8_t >::const_iterator data_ptr) const
uint32_t readNameLength(std::vector< uint8_t >::const_iterator data_ptr) const
uint8_t readReleaseNumber(std::vector< uint8_t >::const_iterator data_ptr) const
void setVersionMajorVersionNumber(const uint8_t &version_major_version_number)
Sets the major version number for the scanner.
uint8_t readUint8(std::vector< uint8_t >::const_iterator it)
Read an unsigned 8-bit integer at offset.