コード例 #1
0
        /**
         * Tears down a tutorial session.
         * <br /><br />
         * Specifically, this involves:
         * <ol>
         *   <li>Un-registering the listeners</li>
         *   <li>Disconnecting the transport</li>
         *   <li>"Closing" our Skype instance, which terminates the SkypeKit runtime</li>
         * </ol>
         *
         * @see Listeners#unRegisterAllListeners()
         *
         * @since 1.0
         */
        public void doTearDownSession()
        {
            if (myListeners != null)
            {
                myListeners.unRegisterAllListeners();
                myListeners = null;
            }
            // Closing Skype also disconnects the transport
            if (mySkype != null)
            {
                mySkype.stop();
                mySkype = null;
            }

            myConsole.printf("%s: Tore down session instance%n", myTutorialTag);
        }