[asterisk-scf-commits] asterisk-scf/release/test_channel.git branch "master" updated.
Commits to the Asterisk SCF project code repositories
asterisk-scf-commits at lists.digium.com
Mon May 23 16:16:15 CDT 2011
branch "master" has been updated
via 1f84b83379bc5d3b531a43b6efe4850cc6f2429a (commit)
via f3a7942f0d59d012314919d1f2e5437e9126a4f7 (commit)
via 3404992bd9dc27aef8461cfe0302254167e415bf (commit)
via 285080414aa697bfed60d317c61fb5545ac15116 (commit)
from 34a177e2628b60d7fa8da14b35f65f4c79659eee (commit)
Summary of changes:
src/TestEndpoint.cpp | 68 +++++++++++++++++++++++++++++++++++--------------
1 files changed, 48 insertions(+), 20 deletions(-)
- Log -----------------------------------------------------------------
commit 1f84b83379bc5d3b531a43b6efe4850cc6f2429a
Merge: f3a7942 34a177e
Author: Mark Michelson <mmichelson at digium.com>
Date: Mon May 23 15:51:54 2011 -0500
Merge branch 'master' of git.asterisk.org:asterisk-scf/release/test_channel
Conflicts:
src/TestEndpoint.cpp
diff --cc src/TestEndpoint.cpp
index bf2fe9b,538c522..828182e
--- a/src/TestEndpoint.cpp
+++ b/src/TestEndpoint.cpp
@@@ -147,16 -146,22 +147,27 @@@ public
{
mListeners->addListener(listener);
mEndpointManager->log(mId, __FUNCTION__);
- return mInfo;
+ cb->ice_response(mInfo);
}
- void indicate(const AsteriskSCF::SessionCommunications::V1::IndicationPtr& value, const Ice::Current&)
+ void indicate_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_indicatePtr& cb,
+ const AsteriskSCF::SessionCommunications::V1::IndicationPtr&,
+ const Ice::Current&)
{
+ std::string msg;
+ if (value)
+ {
+ msg = value->ice_id() + ":";
+ msg += __FUNCTION__;
+ }
+ else
+ {
+ msg = __FUNCTION__;
+ }
+ mEndpointManager->log(mId, msg);
+ mEndpointManager->log(mId, __FUNCTION__);
+ cb->ice_response();
}
void connect(const Ice::Current&)
commit f3a7942f0d59d012314919d1f2e5437e9126a4f7
Merge: 3404992 c65cf9a
Author: Mark Michelson <mmichelson at digium.com>
Date: Thu May 19 09:07:53 2011 -0500
Merge branch 'master' into sip-threading
Conflicts:
src/TestEndpoint.cpp
commit 3404992bd9dc27aef8461cfe0302254167e415bf
Author: Mark Michelson <mmichelson at digium.com>
Date: Tue May 10 17:28:08 2011 -0500
Adjust for changes in SessionCommunicationsIf.ice
diff --git a/src/TestEndpoint.cpp b/src/TestEndpoint.cpp
index 9d50d43..fda9295 100644
--- a/src/TestEndpoint.cpp
+++ b/src/TestEndpoint.cpp
@@ -140,18 +140,23 @@ public:
mInfo->currentState = "ready";
}
- AsteriskSCF::SessionCommunications::V1::SessionInfoPtr addListener(
- const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
+ void addListener_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_addListenerPtr& cb,
+ const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
const Ice::Current&)
{
mListeners->addListener(listener);
mEndpointManager->log(mId, __FUNCTION__);
- return mInfo;
+ cb->ice_response(mInfo);
}
- void indicate(const AsteriskSCF::SessionCommunications::V1::IndicationPtr&, const Ice::Current&)
+ void indicate_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_indicatePtr& cb,
+ const AsteriskSCF::SessionCommunications::V1::IndicationPtr&,
+ const Ice::Current&)
{
- mEndpointManager->log(mId, __FUNCTION__);
+ mEndpointManager->log(mId, __FUNCTION__);
+ cb->ice_response();
}
void connect(const Ice::Current&)
@@ -164,19 +169,25 @@ public:
mEndpointManager->log(mId, __FUNCTION__);
}
- AsteriskSCF::SessionCommunications::V1::SessionEndpointPrx getEndpoint(const Ice::Current&)
+ void getEndpoint_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_getEndpointPtr& cb,
+ const Ice::Current&)
{
mEndpointManager->log(mId, __FUNCTION__);
- return mEndpointPrx;
+ cb->ice_response(mEndpointPrx);
}
- AsteriskSCF::SessionCommunications::V1::SessionInfoPtr getInfo(const Ice::Current&)
+ void getInfo_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_getInfoPtr& cb,
+ const Ice::Current&)
{
mEndpointManager->log(mId, __FUNCTION__);
- return 0;
+ cb->ice_response(0);
}
- AsteriskSCF::Media::V1::SessionPrx getMediaSession(const Ice::Current& current)
+ void getMediaSession_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_getMediaSessionPtr& cb,
+ const Ice::Current& current)
{
mEndpointManager->log(mId, __FUNCTION__);
boost::unique_lock<boost::shared_mutex> lock(mMutex);
@@ -186,8 +197,8 @@ public:
current.adapter->add(new MediaSessionI(mId + "Media", current.adapter),
current.adapter->getCommunicator()->stringToIdentity(mId + "Media")));
}
- return mMediaSession;
- };
+ cb->ice_response(mMediaSession);
+ }
void hold(const Ice::Current&)
{
@@ -199,8 +210,9 @@ public:
mEndpointManager->log(mId, __FUNCTION__);
}
- void removeListener(const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
- const Ice::Current&)
+ void removeListener(
+ const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
+ const Ice::Current&)
{
mListeners->removeListener(listener);
mEndpointManager->log(mId, __FUNCTION__);
@@ -226,17 +238,20 @@ public:
mEndpointManager->log(mId, __FUNCTION__);
}
- AsteriskSCF::SessionCommunications::V1::BridgePrx getBridge(const Ice::Current&)
+ void getBridge_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_getBridgePtr& cb,
+ const Ice::Current&)
{
mEndpointManager->log(mId, __FUNCTION__);
- return mCurrentBridge;
+ cb->ice_response(mCurrentBridge);
}
/**
* This method is marked as "amd" in the slice, but we are not bothering with actually
* dispatching the message in the test endpoint, at least not for now anyway.
*/
- void setBridge_async(const AsteriskSCF::SessionCommunications::V1::AMD_Session_setBridgePtr& cb,
+ void setBridge_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_setBridgePtr& cb,
const AsteriskSCF::SessionCommunications::V1::BridgePrx& newBridge,
const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
const Ice::Current&)
@@ -248,16 +263,22 @@ public:
cb->ice_response(mInfo);
}
- void removeBridge(const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener, const Ice::Current&)
+ void removeBridge_async(
+ const AsteriskSCF::SessionCommunications::V1::AMD_Session_removeBridgePtr& cb,
+ const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
+ const Ice::Current&)
{
boost::unique_lock<boost::shared_mutex> lock(mMutex);
if(!mCurrentBridge)
{
- throw AsteriskSCF::SessionCommunications::V1::NotBridged();
+ cb->ice_exception(AsteriskSCF::SessionCommunications::V1::NotBridged());
+ //XXX Are we supposed to throw or just return here?
+ return;
}
mListeners->removeListener(listener);
mCurrentBridge = 0;
mEndpointManager->log(mId, __FUNCTION__);
+ cb->ice_response();
}
void echo()
commit 285080414aa697bfed60d317c61fb5545ac15116
Author: Mark Michelson <mmichelson at digium.com>
Date: Mon May 9 16:33:44 2011 -0500
Adjust for AMD changes in Session::setBridge
diff --git a/src/TestEndpoint.cpp b/src/TestEndpoint.cpp
index ec84632..9d50d43 100644
--- a/src/TestEndpoint.cpp
+++ b/src/TestEndpoint.cpp
@@ -232,14 +232,20 @@ public:
return mCurrentBridge;
}
- AsteriskSCF::SessionCommunications::V1::SessionInfoPtr setBridge(const AsteriskSCF::SessionCommunications::V1::BridgePrx& newBridge,
- const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener, const Ice::Current&)
+ /**
+ * This method is marked as "amd" in the slice, but we are not bothering with actually
+ * dispatching the message in the test endpoint, at least not for now anyway.
+ */
+ void setBridge_async(const AsteriskSCF::SessionCommunications::V1::AMD_Session_setBridgePtr& cb,
+ const AsteriskSCF::SessionCommunications::V1::BridgePrx& newBridge,
+ const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener,
+ const Ice::Current&)
{
boost::unique_lock<boost::shared_mutex> lock(mMutex);
mCurrentBridge = newBridge;
mListeners->addListener(listener);
mEndpointManager->log(mId, __FUNCTION__);
- return mInfo;
+ cb->ice_response(mInfo);
}
void removeBridge(const AsteriskSCF::SessionCommunications::V1::SessionListenerPrx& listener, const Ice::Current&)
-----------------------------------------------------------------------
--
asterisk-scf/release/test_channel.git
More information about the asterisk-scf-commits
mailing list