##// END OF EJS Templates
Fixed tests due to async var creation, plus minor stuff...
Fixed tests due to async var creation, plus minor stuff A variable is created synchronously but its data is get in background so tests have now to wait until the variable is ready before checking its state. VC should have a [] operator, it's a model feature. The new data provider interface implies that each call only ask for one range, this has been reflected in its parameters. Signed-off-by: Alexis Jeandet <alexis.jeandet@member.fsf.org>

File last commit:

r0:86b06c4cec3c
r30:02d2d8643fcb
Show More
Unit.h
27 lines | 667 B | text/x-c | CLexer
#ifndef SCIQLOP_UNIT_H
#define SCIQLOP_UNIT_H
#include <Common/MetaTypes.h>
#include <QString>
#include <tuple>
struct Unit {
explicit Unit(const QString &name = {}, bool timeUnit = false)
: m_Name{name}, m_TimeUnit{timeUnit}
{
}
inline bool operator==(const Unit &other) const
{
return std::tie(m_Name, m_TimeUnit) == std::tie(other.m_Name, other.m_TimeUnit);
}
inline bool operator!=(const Unit &other) const { return !(*this == other); }
QString m_Name; ///< Unit name
bool m_TimeUnit; ///< The unit is a unit of time (UTC)
};
SCIQLOP_REGISTER_META_TYPE(UNIT_REGISTRY, Unit)
#endif // SCIQLOP_UNIT_H