File: utf8.h

package info (click to toggle)
swath 0.3.0.cvs20030404
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 1,564 kB
  • ctags: 545
  • sloc: sh: 6,926; cpp: 3,643; makefile: 151
file content (34 lines) | stat: -rw-r--r-- 558 bytes parent folder | download | duplicates (2)
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
31
32
33
34
//
// utf8.h - UTF-8 Agents
// Created: 19 Jan 1999
// Author:  Theppitak Karoonboonyanan <thep@links.nectec.or.th>
//

#ifndef UTF8_INC
#define UTF8_INC

#include <iostream>
#include "convkit.h"

class UTF8Reader : public TextReader {
public:
    UTF8Reader(std::istream& input) : input(input) {}

    bool Read(unichar& c);

private:
    std::istream& input;
};

class UTF8Writer : public TextWriter {
public:
    UTF8Writer(std::ostream& output) : output(output) {}

    bool Write(unichar c);

private:
    std::ostream& output;
};

#endif  // UTF8_INC