CTransponder: setting code as string and refactored validation

refs #81
This commit is contained in:
Klaus Basan
2013-12-20 22:49:23 +00:00
committed by Mathew Sutcliffe
parent c37e160a42
commit bf0a849a7c
2 changed files with 63 additions and 14 deletions

View File

@@ -205,6 +205,13 @@ namespace BlackMisc
this->validate(true);
}
/*!
* \brief Set transponder code
* \param transponderCode
*/
void setTransponderCode(const QString &transponderCode);
/*!
* \brief Set transponder mode
* \param mode
@@ -248,7 +255,7 @@ namespace BlackMisc
{
return
this->m_transponderCode == other.m_transponderCode &&
this->m_transponderMode == other.m_transponderMode &&
this->getTransponderMode() == other.getTransponderMode() &&
this->CAvionicsBase::operator ==(other);
}
@@ -337,6 +344,20 @@ namespace BlackMisc
*/
virtual uint getValueHash() const;
/*!
* \brief Is valid transponder code?
* \param transponderCode
* \return
*/
static bool isValidTransponderCode(const QString &transponderCode);
/*!
* \brief Is valid transponder code?
* \param transponderCode
* \return
*/
static bool isValidTransponderCode(qint32 transponderMode);
/*!
* \brief Register metadata of unit and quantity
*/