summaryrefslogtreecommitdiffstats
blob: f63a4e85e4a56d63d75cc114c47e5962f5d788e6 (plain)
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
/*
 * Copyright (c) 2013-2015 Isode Limited.
 * All rights reserved.
 * See the COPYING file for more information.
 */

#include <Swiften/FileTransfer/FileTransfer.h>

using namespace Swift;

FileTransfer::FileTransfer() : fileSizeInBytes_(0), state_(State::Initial) {
}

FileTransfer::~FileTransfer() {
}

void FileTransfer::setState(const State& state) {
	state_ = state;
	onStateChanged(state);
}

void FileTransfer::setFileInfo(const std::string& name, boost::uintmax_t size) {
	filename_ = name;
	fileSizeInBytes_ = size;
}