/*
 * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
 * SPDX-License-Identifier: BSD-3-Clause
 */

// Autogenerated by Thrift Compiler (0.14.1-yarped)
//
// This is an automatically generated file.
// It could get re-generated if the ALLOW_IDL_GENERATION flag is on.

#ifndef YARP_THRIFT_GENERATOR_STRUCT_ODOMETRYDATA6D_H
#define YARP_THRIFT_GENERATOR_STRUCT_ODOMETRYDATA6D_H

#include <yarp/dev/api.h>

#include <yarp/os/Wire.h>
#include <yarp/os/idl/WireTypes.h>

namespace yarp::dev {

class YARP_dev_API OdometryData6D :
        public yarp::os::idl::WirePortable
{
public:
    // Fields
    /**
     * position of the robot [m], expressed in the world reference frame
     */
    double odom_x{0.0};
    /**
     * position of the robot [m], expressed in the world reference frame
     */
    double odom_y{0.0};
    /**
     * position of the robot [m], expressed in the world reference frame
     */
    double odom_z{0.0};
    /**
     * orientation the robot [deg], expressed in the world reference frame
     */
    double odom_roll{0.0};
    /**
     * orientation the robot [deg], expressed in the world reference frame
     */
    double odom_pitch{0.0};
    /**
     * orientation the robot [deg], expressed in the world reference frame
     */
    double odom_yaw{0.0};
    /**
     * velocity of the robot [m/s] expressed in the robot reference frame
     */
    double base_vel_x{0.0};
    /**
     * velocity of the robot [m/s] expressed in the robot reference frame
     */
    double base_vel_y{0.0};
    /**
     * velocity of the robot [m/s] expressed in the robot reference frame
     */
    double base_vel_z{0.0};
    /**
     * angular velocity of the robot [deg/s] expressed in the robot reference frame
     */
    double base_vel_roll{0.0};
    /**
     * angular velocity of the robot [deg/s] expressed in the robot reference frame
     */
    double base_vel_pitch{0.0};
    /**
     * angular velocity of the robot [deg/s] expressed in the robot reference frame
     */
    double base_vel_yaw{0.0};
    /**
     * velocity of the robot [m/s] expressed in the world reference frame
     */
    double odom_vel_x{0.0};
    /**
     * velocity of the robot [m/s] expressed in the world reference frame
     */
    double odom_vel_y{0.0};
    /**
     * velocity of the robot [m/s] expressed in the world reference frame
     */
    double odom_vel_z{0.0};
    /**
     * angular velocity of the robot [deg/s] expressed in the world reference frame
     */
    double odom_vel_roll{0.0};
    /**
     * angular velocity of the robot [deg/s] expressed in the world reference frame
     */
    double odom_vel_pitch{0.0};
    /**
     * angular velocity of the robot [deg/s] expressed in the world reference frame
     */
    double odom_vel_yaw{0.0};

    // Default constructor
    OdometryData6D() = default;

    // Constructor with field values
    OdometryData6D(const double odom_x,
                   const double odom_y,
                   const double odom_z,
                   const double odom_roll,
                   const double odom_pitch,
                   const double odom_yaw,
                   const double base_vel_x,
                   const double base_vel_y,
                   const double base_vel_z,
                   const double base_vel_roll,
                   const double base_vel_pitch,
                   const double base_vel_yaw,
                   const double odom_vel_x,
                   const double odom_vel_y,
                   const double odom_vel_z,
                   const double odom_vel_roll,
                   const double odom_vel_pitch,
                   const double odom_vel_yaw);

    // Read structure on a Wire
    bool read(yarp::os::idl::WireReader& reader) override;

    // Read structure on a Connection
    bool read(yarp::os::ConnectionReader& connection) override;

    // Write structure on a Wire
    bool write(const yarp::os::idl::WireWriter& writer) const override;

    // Write structure on a Connection
    bool write(yarp::os::ConnectionWriter& connection) const override;

    // Convert to a printable string
    std::string toString() const;

    // If you want to serialize this class without nesting, use this helper
    typedef yarp::os::idl::Unwrapped<OdometryData6D> unwrapped;

private:
    // read/write odom_x field
    bool read_odom_x(yarp::os::idl::WireReader& reader);
    bool write_odom_x(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_x(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_x(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_y field
    bool read_odom_y(yarp::os::idl::WireReader& reader);
    bool write_odom_y(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_y(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_y(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_z field
    bool read_odom_z(yarp::os::idl::WireReader& reader);
    bool write_odom_z(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_z(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_z(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_roll field
    bool read_odom_roll(yarp::os::idl::WireReader& reader);
    bool write_odom_roll(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_roll(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_roll(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_pitch field
    bool read_odom_pitch(yarp::os::idl::WireReader& reader);
    bool write_odom_pitch(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_pitch(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_pitch(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_yaw field
    bool read_odom_yaw(yarp::os::idl::WireReader& reader);
    bool write_odom_yaw(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_yaw(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_yaw(const yarp::os::idl::WireWriter& writer) const;

    // read/write base_vel_x field
    bool read_base_vel_x(yarp::os::idl::WireReader& reader);
    bool write_base_vel_x(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_base_vel_x(yarp::os::idl::WireReader& reader);
    bool nested_write_base_vel_x(const yarp::os::idl::WireWriter& writer) const;

    // read/write base_vel_y field
    bool read_base_vel_y(yarp::os::idl::WireReader& reader);
    bool write_base_vel_y(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_base_vel_y(yarp::os::idl::WireReader& reader);
    bool nested_write_base_vel_y(const yarp::os::idl::WireWriter& writer) const;

    // read/write base_vel_z field
    bool read_base_vel_z(yarp::os::idl::WireReader& reader);
    bool write_base_vel_z(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_base_vel_z(yarp::os::idl::WireReader& reader);
    bool nested_write_base_vel_z(const yarp::os::idl::WireWriter& writer) const;

    // read/write base_vel_roll field
    bool read_base_vel_roll(yarp::os::idl::WireReader& reader);
    bool write_base_vel_roll(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_base_vel_roll(yarp::os::idl::WireReader& reader);
    bool nested_write_base_vel_roll(const yarp::os::idl::WireWriter& writer) const;

    // read/write base_vel_pitch field
    bool read_base_vel_pitch(yarp::os::idl::WireReader& reader);
    bool write_base_vel_pitch(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_base_vel_pitch(yarp::os::idl::WireReader& reader);
    bool nested_write_base_vel_pitch(const yarp::os::idl::WireWriter& writer) const;

    // read/write base_vel_yaw field
    bool read_base_vel_yaw(yarp::os::idl::WireReader& reader);
    bool write_base_vel_yaw(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_base_vel_yaw(yarp::os::idl::WireReader& reader);
    bool nested_write_base_vel_yaw(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_vel_x field
    bool read_odom_vel_x(yarp::os::idl::WireReader& reader);
    bool write_odom_vel_x(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_vel_x(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_vel_x(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_vel_y field
    bool read_odom_vel_y(yarp::os::idl::WireReader& reader);
    bool write_odom_vel_y(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_vel_y(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_vel_y(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_vel_z field
    bool read_odom_vel_z(yarp::os::idl::WireReader& reader);
    bool write_odom_vel_z(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_vel_z(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_vel_z(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_vel_roll field
    bool read_odom_vel_roll(yarp::os::idl::WireReader& reader);
    bool write_odom_vel_roll(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_vel_roll(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_vel_roll(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_vel_pitch field
    bool read_odom_vel_pitch(yarp::os::idl::WireReader& reader);
    bool write_odom_vel_pitch(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_vel_pitch(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_vel_pitch(const yarp::os::idl::WireWriter& writer) const;

    // read/write odom_vel_yaw field
    bool read_odom_vel_yaw(yarp::os::idl::WireReader& reader);
    bool write_odom_vel_yaw(const yarp::os::idl::WireWriter& writer) const;
    bool nested_read_odom_vel_yaw(yarp::os::idl::WireReader& reader);
    bool nested_write_odom_vel_yaw(const yarp::os::idl::WireWriter& writer) const;
};

} // namespace yarp::dev

#endif // YARP_THRIFT_GENERATOR_STRUCT_ODOMETRYDATA6D_H
