Files
pilotclient/src/blackmisc/pqspeed.h
2013-04-11 00:28:35 +02:00

51 lines
1.3 KiB
C++

/* Copyright (C) 2013 VATSIM Community
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef BLACKMISC_CSPEED_H
#define BLACKMISC_CSPEED_H
#include "pqphysicalquantity.h"
namespace BlackMisc
{
namespace PhysicalQuantities
{
/*!
* \brief Speed class, e.g. "m/s", "NM/h", "km/h", "ft/s"
* \author KWB
*/
class CSpeed : public CPhysicalQuantity<CSpeedUnit, CSpeed>
{
public:
/*!
* \brief Default constructor
*/
CSpeed() : CPhysicalQuantity(0, CSpeedUnit::m_s(), CSpeedUnit::m_s()) {}
/**
*\brief Copy constructor
*/
CSpeed(const CPhysicalQuantity &speed): CPhysicalQuantity(speed) {}
/*!
* \brief Init by int value
* \param value
* \param unit
*/
CSpeed(qint32 value, const CSpeedUnit &unit) : CPhysicalQuantity(value, unit, CSpeedUnit::m_s()) {}
/*!
*\brief Init by double value
* \param value
* \param unit
*/
CSpeed(double value, const CSpeedUnit &unit) : CPhysicalQuantity(value, unit, CSpeedUnit::m_s()) {}
/*!
* \brief Destructor
*/
virtual ~CSpeed() {}
};
} // namespace
} // namespace
#endif // BLACKMISC_CSPEED_H