~ubuntu-branches/ubuntu/saucy/kopete/saucy-proposed

« back to all changes in this revision

Viewing changes to protocols/oscar/liboscar/ofttransfer.h

  • Committer: Package Import Robot
  • Author(s): Jonathan Riddell
  • Date: 2013-06-21 02:22:39 UTC
  • Revision ID: package-import@ubuntu.com-20130621022239-63l3zc8p0nf26pt6
Tags: upstream-4.10.80
ImportĀ upstreamĀ versionĀ 4.10.80

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 
 
3
    Kopete (c) 2006 by the Kopete developers <kopete-devel@kde.org>
 
4
 
 
5
    *************************************************************************
 
6
    *                                                                       *
 
7
    * This library is free software; you can redistribute it and/or         *
 
8
    * modify it under the terms of the GNU Lesser General Public            *
 
9
    * License as published by the Free Software Foundation; either          *
 
10
    * version 2 of the License, or (at your option) any later version.      *
 
11
    *                                                                       *
 
12
    *************************************************************************
 
13
*/
 
14
 
 
15
#ifndef OFTTRANSFER_H
 
16
#define OFTTRANSFER_H
 
17
 
 
18
#include "oscartypes.h"
 
19
#include "buffer.h"
 
20
#include "transfer.h"
 
21
 
 
22
using namespace Oscar;
 
23
 
 
24
class OftTransfer : public Transfer
 
25
{
 
26
public:
 
27
 
 
28
        explicit OftTransfer( OFT data, Buffer* buffer = 0 );
 
29
        OftTransfer();
 
30
        virtual ~OftTransfer();
 
31
 
 
32
        virtual TransferType type() const;
 
33
        virtual QByteArray toWire();
 
34
 
 
35
        //! Set the OFT data
 
36
        void setData( OFT data );
 
37
 
 
38
        //! Get the OFT data
 
39
        OFT data() const;
 
40
 
 
41
        //! Get the validity of the OFT header
 
42
        bool oftValid() const;
 
43
        
 
44
private:
 
45
        //! Converts fileName from Unicode to QByteArray;
 
46
        QByteArray encodeFileName( const QString &fileName, int &encodingType ) const;
 
47
 
 
48
        OFT m_data; //much easier to keep it all in a struct
 
49
 
 
50
        bool m_isOftValid;
 
51
        
 
52
};
 
53
 
 
54
 
 
55
#endif