diff --git a/src/api/newcallmodel.h b/src/api/newcallmodel.h index e5182ec8e2347cf023b64dae9819ed599a1c8803..55c99dc01a8a6161bb73e62fda79692042ba197c 100644 --- a/src/api/newcallmodel.h +++ b/src/api/newcallmodel.h @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (C) 2017-2018 Savoir-faire Linux * + * Copyright (C) 2017-2018 Savoir-faire Linux * * Author: Nicolas Jäger <nicolas.jager@savoirfairelinux.com> * * Author: Sébastien Blin <sebastien.blin@savoirfairelinux.com> * * * @@ -141,9 +141,17 @@ public: */ void setQuality(const std::string& callId, const double quality) const; /** - * Not implemented yet + * Blind transfer. Directly transfer a call to a sip number + * @param callId: the call to transfer + * @param to: the sip number (for example: "sip:1412") */ void transfer(const std::string& callId, const std::string& to) const; + /** + * Perform an attended. Transfer a call to another call + * @param callIdSrc: the call to transfer + * @param callIdDest: the destination's call + */ + void transferToCall(const std::string& callIdSrc, const std::string& callIdDest) const; /** * Create a conference from 2 calls. * @param callIdA uid of the call A diff --git a/src/newcallmodel.cpp b/src/newcallmodel.cpp index d42839d4b864edf0dff1fafd3b12fcb4c9d7832e..b515815d2f744d51344ee40a98a4fef4e7d5c4cd 100644 --- a/src/newcallmodel.cpp +++ b/src/newcallmodel.cpp @@ -282,7 +282,13 @@ NewCallModel::setQuality(const std::string& callId, const double quality) const void NewCallModel::transfer(const std::string& callId, const std::string& to) const { - qDebug() << "transfer, isn't yet implemented"; + CallManager::instance().transfer(callId.c_str(), to.c_str()); +} + +void +NewCallModel::transferToCall(const std::string& callId, const std::string& callIdDest) const +{ + CallManager::instance().attendedTransfer(callId.c_str(), callIdDest.c_str()); } void