Add a bunch of new Parser testcases.

This commit is contained in:
Felix Geyer 2010-08-25 21:14:41 +02:00
parent 542ecd41d1
commit cd26e9d474
4 changed files with 531 additions and 78 deletions

View file

@ -70,6 +70,12 @@ bool Uuid::operator!=(const Uuid& other) const
return !operator==(other);
}
Uuid Uuid::fromBase64(const QString& str)
{
QByteArray data = QByteArray::fromBase64(str.toAscii());
return Uuid(data);
}
uint qHash(const Uuid& key)
{
return qHash(key.toByteArray());

View file

@ -33,6 +33,7 @@ public:
bool operator==(const Uuid& other) const;
bool operator!=(const Uuid& other) const;
static const int length;
static Uuid fromBase64(const QString& str);
private:
QByteArray m_data;