~ubuntu-branches/ubuntu/jaunty/psi/jaunty

« back to all changes in this revision

Viewing changes to iris/xmpp-core/compressionhandler.h

  • Committer: Bazaar Package Importer
  • Author(s): Jan Niehusmann
  • Date: 2008-04-14 18:57:30 UTC
  • mfrom: (2.1.9 hardy)
  • Revision ID: james.westby@ubuntu.com-20080414185730-528re3zp0m2hdlhi
Tags: 0.11-8
* added CONFIG -= link_prl to .pro files and removed dependencies
  which are made unnecessary by this change
* Fix segfault when closing last chat tab with qt4.4
  (This is from upstream svn, rev. 1101) (Closes: Bug#476122)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#ifndef COMPRESSIONHANDLER_H
 
2
#define COMPRESSIONHANDLER_H
 
3
 
 
4
#include <QObject>
 
5
#include <QBuffer>
 
6
 
 
7
class Compressor;
 
8
class Decompressor;
 
9
 
 
10
class CompressionHandler : public QObject
 
11
{
 
12
        Q_OBJECT
 
13
 
 
14
public:
 
15
        CompressionHandler();
 
16
        void writeIncoming(const QByteArray& a);
 
17
        void write(const QByteArray& a);
 
18
        QByteArray read();
 
19
        QByteArray readOutgoing(int*);
 
20
        int errorCode();
 
21
 
 
22
signals:
 
23
        void readyRead();
 
24
        void readyReadOutgoing();
 
25
        void error();
 
26
 
 
27
private: 
 
28
        Compressor* compressor_;
 
29
        Decompressor* decompressor_;
 
30
        QBuffer outgoing_buffer_, incoming_buffer_;
 
31
        int errorCode_;
 
32
};
 
33
 
 
34
#endif