1 /* coded by Ketmar // Vampire Avalon (psyc://ketmar.no-ip.org/~Ketmar)
2 * Understanding is not required. Only obedience.
4 * This program is free software. It comes without any warranty, to
5 * the extent permitted by applicable law. You can redistribute it
6 * and/or modify it under the terms of the Do What The Fuck You Want
7 * To Public License, Version 2, as published by Sam Hocevar. See
8 * http://sam.zoy.org/wtfpl/COPYING for more details.
11 #ifndef K8LDBHISTORY_H
12 #define K8LDBHISTORY_H
19 #include "leveldb/db.h"
22 ///////////////////////////////////////////////////////////////////////////////
23 class HistoryFile
: public HistoryFileBase
{
25 HistoryFile (const QString
&fname
, const QString
&myUni
);
26 virtual ~HistoryFile ();
28 virtual bool open (OpenMode newmode
);
29 virtual bool isOpen () const;
30 virtual void close ();
31 virtual void remove ();
35 virtual bool append (const HistoryMessage
&msg
);
37 virtual bool read (int idx
, HistoryMessage
&msg
);
43 HistoryFile::OpenMode mMode
;
46 int mCount
; // -1: not counted yet