diff options
Diffstat (limited to 'Swiften/FileTransfer/FailingTransportSession.h')
-rw-r--r-- | Swiften/FileTransfer/FailingTransportSession.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/Swiften/FileTransfer/FailingTransportSession.h b/Swiften/FileTransfer/FailingTransportSession.h new file mode 100644 index 0000000..c197052 --- /dev/null +++ b/Swiften/FileTransfer/FailingTransportSession.h @@ -0,0 +1,28 @@ +/* + * Copyright (c) 2015 Isode Limited. + * All rights reserved. + * See the COPYING file for more information. + */ + +#pragma once + +#include <Swiften/Base/API.h> +#include <Swiften/FileTransfer/TransportSession.h> + +namespace Swift { + +class SWIFTEN_API FailingTransportSession : public TransportSession { + public: + virtual ~FailingTransportSession() { + } + + virtual void start() SWIFTEN_OVERRIDE { + assert(false); + onFinished(FileTransferError(FileTransferError::PeerError)); + } + + virtual void stop() SWIFTEN_OVERRIDE { + } +}; + +} |