summaryrefslogtreecommitdiffstats
path: root/addon/doxmlparser/src/stringimpl.h
blob: 013858fc39921fc12540a9f8d833ea05f70a25a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#ifndef STRINGIMPL_H
#define STRINGIMPL_H

#include <qstring.h>
#include "doxmlintf.h"

class StringImpl : public QString, public IString
{
  public:
    StringImpl() {}
    StringImpl(const QString &str) : QString(str) {}
    StringImpl &operator=(const QString &str) 
    { QString::operator=(str); return *this; }
    virtual ~StringImpl() {}

    // IString 
    const char *latin1() const 
    { return QString::latin1(); }
    const char *utf8() const 
    { return QString::utf8(); }
    unsigned short unicodeCharAt(int index) const 
    { return QString::unicode()[index].unicode(); } 
    bool isEmpty() const 
    { return QString::isEmpty(); }
    int length() const 
    { return QString::length(); }
};

#endif