Esempio n. 1
0
        /// <summary>
        /// Runs the callback unparsed.
        /// </summary>
        /// <param name="Command">The command.</param>
        /// <param name="Callback">The callback.</param>
        /// <param name="Args">The args.</param>
        public void RunCallbackUnparsed(P4Callback Callback, string Command, params string[] Args)
        {
            CallbackClientUser cu        = new CallbackClientUser(Callback);
            CallbackKeepAlive  keepAlive = new CallbackKeepAlive(cu);

            EstablishConnection(false, keepAlive);
            Callback.SetEncoding(m_ClientApi.Encoding);
            RunIt(Command, Args, cu);

            // always throw a defered exception (means something went WAY wrong)
            if (cu.DeferedException != null)
            {
                throw cu.DeferedException;
            }
        }
Esempio n. 2
0
 public CallbackKeepAlive(CallbackClientUser callback)
 {
     this.callbackClient = callback;
 }
Esempio n. 3
0
        /// <summary>
        /// Runs the callback unparsed.
        /// </summary>
        /// <param name="Command">The command.</param>
        /// <param name="Callback">The callback.</param>
        /// <param name="Args">The args.</param>
        public void RunCallbackUnparsed(P4Callback Callback, string Command, params string[] Args)
        {
            CallbackClientUser cu = new CallbackClientUser(Callback);
            CallbackKeepAlive keepAlive = new CallbackKeepAlive(cu);
            EstablishConnection(false, keepAlive);
            Callback.SetEncoding(m_ClientApi.Encoding);
            RunIt(Command, Args, cu);

            // always throw a defered exception (means something went WAY wrong)
            if (cu.DeferedException != null)
            {
                throw cu.DeferedException;
            }
        }
Esempio n. 4
0
 public CallbackKeepAlive(CallbackClientUser callback)
 {
     this.callbackClient = callback;
 }