summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2011-09-28 19:26:48 (GMT)
committerRemko Tronçon <git@el-tramo.be>2011-09-28 19:26:48 (GMT)
commit6cea7fdfea93e54543c6757909a8fae7348754fc (patch)
treeebdb062bcf8c707e45a6151e9069a08461c3a373 /Swiften
parent585ec5609fd437a222bdfa6eb243cc4ce8e45391 (diff)
downloadswift-contrib-6cea7fdfea93e54543c6757909a8fae7348754fc.zip
swift-contrib-6cea7fdfea93e54543c6757909a8fae7348754fc.tar.bz2
Added getRecipient() to IncomingJingleFileTransfer.
Diffstat (limited to 'Swiften')
-rw-r--r--Swiften/FileTransfer/IncomingFileTransfer.h2
-rw-r--r--Swiften/FileTransfer/IncomingJingleFileTransfer.cpp4
-rw-r--r--Swiften/FileTransfer/IncomingJingleFileTransfer.h3
3 files changed, 8 insertions, 1 deletions
diff --git a/Swiften/FileTransfer/IncomingFileTransfer.h b/Swiften/FileTransfer/IncomingFileTransfer.h
index a6cf05e..5b53d54 100644
--- a/Swiften/FileTransfer/IncomingFileTransfer.h
+++ b/Swiften/FileTransfer/IncomingFileTransfer.h
@@ -21,6 +21,8 @@ namespace Swift {
virtual ~IncomingFileTransfer();
virtual void accept(WriteBytestream::ref) = 0;
+
virtual const JID& getSender() const = 0;
+ virtual const JID& getRecipient() const = 0;
};
}
diff --git a/Swiften/FileTransfer/IncomingJingleFileTransfer.cpp b/Swiften/FileTransfer/IncomingJingleFileTransfer.cpp
index 0481a47..ab6b5e5 100644
--- a/Swiften/FileTransfer/IncomingJingleFileTransfer.cpp
+++ b/Swiften/FileTransfer/IncomingJingleFileTransfer.cpp
@@ -124,6 +124,10 @@ const JID& IncomingJingleFileTransfer::getSender() const {
return session->getInitiator();
}
+const JID& IncomingJingleFileTransfer::getRecipient() const {
+ return ourJID;
+}
+
void IncomingJingleFileTransfer::cancel() {
session->sendTerminate(JinglePayload::Reason::Cancel);
diff --git a/Swiften/FileTransfer/IncomingJingleFileTransfer.h b/Swiften/FileTransfer/IncomingJingleFileTransfer.h
index 9e77de7..4ae0bfb 100644
--- a/Swiften/FileTransfer/IncomingJingleFileTransfer.h
+++ b/Swiften/FileTransfer/IncomingJingleFileTransfer.h
@@ -48,7 +48,7 @@ namespace Swift {
};
IncomingJingleFileTransfer(
- const JID& ourJID,
+ const JID& recipient,
JingleSession::ref,
JingleContentPayload::ref content,
RemoteJingleTransportCandidateSelectorFactory*,
@@ -61,6 +61,7 @@ namespace Swift {
virtual void accept(WriteBytestream::ref);
virtual const JID& getSender() const;
+ virtual const JID& getRecipient() const;
void cancel();
private: