[asterisk-scf-commits] asterisk-scf/integration/slice.git branch "sessioncontroller" updated.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Fri Jun 24 10:25:07 CDT 2011


branch "sessioncontroller" has been updated
       via  f7676e99cd267657e65a233b0b07b0b225e3b8ba (commit)
      from  e5cd7118d887096e0fbaef25d433a5be7a8e2341 (commit)

Summary of changes:
 .../SessionCommunicationsIf.ice                    |   48 +++++++++++++++-----
 1 files changed, 37 insertions(+), 11 deletions(-)


- Log -----------------------------------------------------------------
commit f7676e99cd267657e65a233b0b07b0b225e3b8ba
Author: Joshua Colp <jcolp at digium.com>
Date:   Fri Jun 24 12:25:18 2011 -0300

    Renaming and further documentation.

diff --git a/slice/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice b/slice/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
index 8e1dbc4..b7342c7 100644
--- a/slice/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
+++ b/slice/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
@@ -314,8 +314,18 @@ module V1
     exception NotBridged { };
 
     /**
-     * A SessionController interface which is used to determine if actions should be
-     * permitted to control on a session and what their result is.
+     * A SessionController interface which is used to invoke critical operations
+     * relating to a session. This is implemented by external components so they can
+     * be controlled by a session and is also implemented by a session so it can be
+     * controlled by external components.
+     *
+     * Note that the operations contained can not be safely invoked on a single instance
+     * by multiple external components at the same time. This could lead to dissimilar state
+     * between the external components ultimately leading to a broken session. This is why
+     * in the Session interface in order to receive a proxy to the SessionController interface
+     * you have to provide a proxy to your own SessionController interface. This is to create
+     * a tight relationship between the two instances.
+     *
      */
     interface SessionController
     {
@@ -324,25 +334,25 @@ module V1
          *
          * @param streams A dictionary of streams and their new state.
          */
-        void streamStatesChanged(AsteriskSCF::Media::V1::StreamStateDict streams);
+        void changeStreamStates(AsteriskSCF::Media::V1::StreamStateDict streams);
 
         /**
-         * Method called when streams are to be added to a session.
+         * Method called when streams are added to a session.
          *
          * @param streams A dictionary of streams with state and requested formats.
          *
          * @return StreamInformationDict A dictionary of streams actually added with state
          *       and formats.
          */
-        AsteriskSCF::Media::V1::StreamInformationDict streamsAdd(AsteriskSCF::Media::V1::StreamInformationDict
+        AsteriskSCF::Media::V1::StreamInformationDict addStreams(AsteriskSCF::Media::V1::StreamInformationDict
                                                                  streams);
 
         /**
-         * Method called when streams are to be removed from a session.
+         * Method called when streams are removed from a session.
          *
-         * @param streams A dictionary of streams to be removed.
+         * @param streams A dictionary of streams removed.
          */
-        void streamsRemoved(AsteriskSCF::Media::V1::StreamInformationDict streams);
+        void removeStreams(AsteriskSCF::Media::V1::StreamInformationDict streams);
     };
 
     /**
@@ -506,18 +516,34 @@ module V1
         ["amd"] void removeBridge(SessionListener* listener) throws NotBridged;
 
         /**
-         * Method which sets the session controller on a session and returns a proxy
-         * to the session controller for the session.
+         * Method which sets the session controller proxy to be contacted when actions
+         * that occur on the session require controller intervention or notification.
+         *
+         * Multiple controllers are not supported on a session due to the fact that the
+         * actions occuring on the SessionController interface are critical and supporting
+         * multiple controllers would lead to state information becoming out of sync between
+         * controllers.
+         *
+         * This method returns a proxy to a SessionController interface implemented by
+         * the session so it can also perform controller intervention and receive
+         * notification from the component that passed in the SessionController.
          *
          * @param controller A proxy to the SessionController object.
          *
-         * @return SessionController* A proxy to the session controller for the session.
+         * @return SessionController* A proxy to the session controller implemented by
+         *       the session.
+         *
+         * @see SessionController
          */
         SessionController *setAndGetSessionController(SessionController* controller);
 
         /**
          * Method which removes a session controller from a session.
          *
+         * If the passed in proxy is not the current controller this should not
+         * remove the controller from the session. This prevents a potential issue
+         * with the controller being set before the previous one has been removed.
+         *
          * @param controller A proxy to the session controller to remove.
          */
         void removeSessionController(SessionController* controller);

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/slice.git



More information about the asterisk-scf-commits mailing list