file-transfer-content.h 2.07 KB
Newer Older
1 2
/*
 * file-transfer-content.h
3
 * Copyright (C) 2010-2018 Belledonne Communications SARL
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 */

20 21
#ifndef _L_FILE_TRANSFER_CONTENT_H_
#define _L_FILE_TRANSFER_CONTENT_H_
22 23 24 25 26 27 28

#include "content.h"

// =============================================================================

LINPHONE_BEGIN_NAMESPACE

29
class FileContent;
30 31 32 33
class FileTransferContentPrivate;

class LINPHONE_PUBLIC FileTransferContent : public Content {
public:
34
	FileTransferContent ();
35 36
	FileTransferContent (const FileTransferContent &other);
	FileTransferContent (FileTransferContent &&other);
37

38 39
	FileTransferContent &operator= (const FileTransferContent &other);
	FileTransferContent &operator= (FileTransferContent &&other);
40

41
	bool operator== (const FileTransferContent &other) const;
42 43 44 45 46 47 48 49 50 51 52 53 54

	void setFileName (const std::string &name);
	const std::string &getFileName () const;

	void setFileUrl (const std::string &url);
	const std::string &getFileUrl () const;

	void setFilePath (const std::string &path);
	const std::string &getFilePath () const;

	void setFileContent (FileContent *content);
	FileContent *getFileContent () const;

55 56 57
	void setFileSize (size_t size);
	size_t getFileSize () const;

58 59
	bool isFile () const override;

60 61
	// TODO: Remove me later.
	LinphoneContent *toLinphoneContent () const override;
62 63 64 65 66 67 68

private:
	L_DECLARE_PRIVATE(FileTransferContent);
};

LINPHONE_END_NAMESPACE

69
#endif // ifndef _L_FILE_TRANSFER_CONTENT_H_