Example #1
0
        public RESULT getSystemObject(ref _System system)
        {
            RESULT rESULT = RESULT.OK;
            IntPtr raw    = IntPtr.Zero;

            try
            {
                rESULT = SoundGroup.FMOD_SoundGroup_GetSystemObject(soundgroupraw, ref raw);
            }
            catch
            {
                rESULT = RESULT.ERR_INVALID_PARAM;
            }
            RESULT result;

            if (rESULT != RESULT.OK)
            {
                result = rESULT;
            }
            else
            {
                if (system == null)
                {
                    _System system2 = new _System();
                    system2.setRaw(raw);
                    system = system2;
                }
                else
                {
                    system.setRaw(raw);
                }
                result = rESULT;
            }
            return(result);
        }
Example #2
0
        public Connect(string ip, int port, NetworkProtocol protocol)
        {
            IPAddress address;

            if (!IPAddress.TryParse(ip, out address))
            {
                throw new InvalidCastException("IP 格式錯誤,請輸入正確的 IPV4 IP ex : 35.123.123.123");
            }
            string ServerIP = address.ToString() + ":" + port;

            NetworkProtocol = protocol;
            gameService     = new GameNetworkService(NetworkProtocol);

            //websocket 的地址,對應到伺服器 websocketsharp 開出的地址
            if (NetworkProtocol == NetworkProtocol.WebSocket)
            {
                gameService.Address = string.Format("ws://{0}/WebSocket", ServerIP);
            }
            else
            {
                gameService.Address = ServerIP;
            }
            _system = new _System();
            AddCallBackHandler(255, _system);
        }
Example #3
0
        public static RESULT System_Create(ref _System system)
        {
            IntPtr raw = IntPtr.Zero;
            RESULT rESULT;

            if (VERSION.platform == Platform.X64)
            {
                rESULT = Factory.FMOD_System_Create_64(ref raw);
            }
            else
            {
                rESULT = Factory.FMOD_System_Create_32(ref raw);
            }
            RESULT result;

            if (rESULT != RESULT.OK)
            {
                result = rESULT;
            }
            else
            {
                _System system2 = new _System();
                system2.setRaw(raw);
                system = system2;
                result = rESULT;
            }
            return(result);
        }
Example #4
0
        public static Tuple <Connect, _System, LobbyHandler, ToArenaHandler, GamingHandler, PacketHandler, PacketHandler> Rudp(Uri gamingServerIp)
        {
            Connect connect = new Connect(gamingServerIp.Host, gamingServerIp.Port, NetworkProtocol.RUDP);

            var system = new _System();

            connect.AddCallBackHandler(_System.OperatorCode, system);

            var gaming = new GamingHandler();

            connect.AddCallBackHandler(GamingHandler.OperationCode, gaming);

            var lobby = new LobbyHandler();

            connect.AddCallBackHandler(LobbyHandler.OperationCode, lobby);

            var toArena = new ToArenaHandler();

            connect.AddCallBackHandler((byte)EOperationCode.ToArena, toArena);

            var gamePacketHandler = new PacketHandler(PacketHandler.GamePacketOperationCode);

            connect.AddCallBackHandler(PacketHandler.GamePacketOperationCode, gamePacketHandler);

            var gameRoomHandler = new PacketHandler(PacketHandler.GameRoomOperationCode);

            connect.AddCallBackHandler(PacketHandler.GameRoomOperationCode, gameRoomHandler);

            //establish connection
            system.Connect += () => { Console.WriteLine("Connect to server."); };

            return(Tuple.Create(connect, system, lobby, toArena, gaming, gamePacketHandler, gameRoomHandler));
        }
        public void Show(_System.FileExplorer.eExplorerType FileExplorer, string Data = "")
        {
            this.ViewState[CnsData] = Data;
            this.FileExplorerHolder1.Url = "~/System/FileExplorer.aspx?ExplorerType=" + ((int)FileExplorer).ToString();
            this.EODialog_BrowseFile.ClientSideOnAccept = "Selection_Accept_" + this.ClientID;
            this.EODialog_BrowseFile.Show();

            try
            { this.EOCbp_BrowseFile.Update(); }
            catch { }
        }
Example #6
0
 public Ice.AsyncResult<MCS.Callback_UserManagement_Logout> begin_Logout(int session, _System.Collections.Generic.Dictionary<string, string> ctx__)
 {
     return begin_Logout(session, ctx__, true, null, null);
 }
Example #7
0
 public void EraseDataUpdater(MCS.GuiDataUpdaterPrx updater, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     EraseDataUpdater(updater, context__, true);
 }
Example #8
0
 public static GuiDataUpdaterPrx checkedCast(Ice.ObjectPrx b, _System.Collections.Generic.Dictionary<string, string> ctx)
 {
     if(b == null)
     {
         return null;
     }
     GuiDataUpdaterPrx r = b as GuiDataUpdaterPrx;
     if((r == null) && b.ice_isA(ice_staticId(), ctx))
     {
         GuiDataUpdaterPrxHelper h = new GuiDataUpdaterPrxHelper();
         h.copyFrom__(b);
         r = h;
     }
     return r;
 }
Example #9
0
 private Ice.AsyncResult<MCS.Callback_GuiDataUpdater_UpdateData> begin_UpdateData(long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> ctx__, bool explicitContext__, Ice.AsyncCallback cb__, object cookie__)
 {
     IceInternal.OnewayOutgoingAsync<MCS.Callback_GuiDataUpdater_UpdateData> result__ = new IceInternal.OnewayOutgoingAsync<MCS.Callback_GuiDataUpdater_UpdateData>(this, __UpdateData_name, UpdateData_completed__, cookie__);
     if(cb__ != null)
     {
         result__.whenCompletedWithAsyncCallback(cb__);
     }
     try
     {
         result__.prepare__(__UpdateData_name, Ice.OperationMode.Idempotent, ctx__, explicitContext__);
         IceInternal.BasicStream os__ = result__.ostr__;
         os__.writeLong(time);
         if(data == null)
         {
             MCS.GuiDataItem tmp__ = new MCS.GuiDataItem();
             tmp__.write__(os__);
         }
         else
         {
             data.write__(os__);
         }
         os__.endWriteEncaps();
         result__.send__(true);
     }
     catch(Ice.LocalException ex__)
     {
         result__.exceptionAsync__(ex__);
     }
     return result__;
 }
Example #10
0
 public Ice.AsyncResult<MCS.Callback_GuiDataUpdater_UpdateData> begin_UpdateData(long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> ctx__)
 {
     return begin_UpdateData(time, data, ctx__, true, null, null);
 }
Example #11
0
 public int SetUserRight(int nUID, int nRight, int session, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     Ice.Current current__ = new Ice.Current();
     initCurrent__(ref current__, "SetUserRight", Ice.OperationMode.Idempotent, context__);
     int result__ = 0;
     IceInternal.Direct.RunDelegate run__ = delegate(Ice.Object obj__)
     {
         UserManagement servant__ = null;
         try
         {
             servant__ = (UserManagement)obj__;
         }
         catch(_System.InvalidCastException)
         {
             throw new Ice.OperationNotExistException(current__.id, current__.facet, current__.operation);
         }
         result__ = servant__.SetUserRight(nUID, nRight, session, current__);
         return Ice.DispatchStatus.DispatchOK;
     };
     IceInternal.Direct direct__ = null;
     try
     {
         direct__ = new IceInternal.Direct(current__, run__);
         try
         {
             Ice.DispatchStatus status__ = direct__.servant().collocDispatch__(direct__);
             _System.Diagnostics.Debug.Assert(status__ == Ice.DispatchStatus.DispatchOK);
         }
         finally
         {
             direct__.destroy();
         }
     }
     catch(Ice.SystemException)
     {
         throw;
     }
     catch(_System.Exception ex__)
     {
         IceInternal.LocalExceptionWrapper.throwWrapper(ex__);
     }
     return result__;
 }
Example #12
0
 public void SetDataUpdater(MCS.GuiDataUpdaterPrx updater, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     Ice.Current current__ = new Ice.Current();
     initCurrent__(ref current__, "SetDataUpdater", Ice.OperationMode.Idempotent, context__);
     IceInternal.Direct.RunDelegate run__ = delegate(Ice.Object obj__)
     {
         GuiDataHub servant__ = null;
         try
         {
             servant__ = (GuiDataHub)obj__;
         }
         catch(_System.InvalidCastException)
         {
             throw new Ice.OperationNotExistException(current__.id, current__.facet, current__.operation);
         }
         servant__.SetDataUpdater(updater, current__);
         return Ice.DispatchStatus.DispatchOK;
     };
     IceInternal.Direct direct__ = null;
     try
     {
         direct__ = new IceInternal.Direct(current__, run__);
         try
         {
             Ice.DispatchStatus status__ = direct__.servant().collocDispatch__(direct__);
             _System.Diagnostics.Debug.Assert(status__ == Ice.DispatchStatus.DispatchOK);
         }
         finally
         {
             direct__.destroy();
         }
     }
     catch(Ice.SystemException)
     {
         throw;
     }
     catch(_System.Exception ex__)
     {
         IceInternal.LocalExceptionWrapper.throwWrapper(ex__);
     }
 }
Example #13
0
 public int SetUserRight(int nUID, int nRight, int session, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     IceInternal.Outgoing og__ = handler__.getOutgoing("SetUserRight", Ice.OperationMode.Idempotent, context__);
     try
     {
         try
         {
             IceInternal.BasicStream os__ = og__.ostr();
             os__.writeInt(nUID);
             os__.writeInt(nRight);
             os__.writeInt(session);
         }
         catch(Ice.LocalException ex__)
         {
             og__.abort(ex__);
         }
         bool ok__ = og__.invoke();
         try
         {
             if(!ok__)
             {
                 try
                 {
                     og__.throwUserException();
                 }
                 catch(Ice.UserException ex__)
                 {
                     throw new Ice.UnknownUserException(ex__.ice_name(), ex__);
                 }
             }
             IceInternal.BasicStream is__ = og__.istr();
             is__.startReadEncaps();
             int ret__;
             ret__ = is__.readInt();
             is__.endReadEncaps();
             return ret__;
         }
         catch(Ice.LocalException ex__)
         {
             throw new IceInternal.LocalExceptionWrapper(ex__, false);
         }
     }
     finally
     {
         handler__.reclaimOutgoing(og__);
     }
 }
Example #14
0
 public int WriteData(MCS.GuiHub.GuiCommand Tag, string Val, int session, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     IceInternal.Outgoing og__ = handler__.getOutgoing("WriteData", Ice.OperationMode.Idempotent, context__);
     try
     {
         try
         {
             IceInternal.BasicStream os__ = og__.ostr();
             os__.writeByte((byte)Tag, 18);
             os__.writeString(Val);
             os__.writeInt(session);
         }
         catch(Ice.LocalException ex__)
         {
             og__.abort(ex__);
         }
         bool ok__ = og__.invoke();
         try
         {
             if(!ok__)
             {
                 try
                 {
                     og__.throwUserException();
                 }
                 catch(Ice.UserException ex__)
                 {
                     throw new Ice.UnknownUserException(ex__.ice_name(), ex__);
                 }
             }
             IceInternal.BasicStream is__ = og__.istr();
             is__.startReadEncaps();
             int ret__;
             ret__ = is__.readInt();
             is__.endReadEncaps();
             return ret__;
         }
         catch(Ice.LocalException ex__)
         {
             throw new IceInternal.LocalExceptionWrapper(ex__, false);
         }
     }
     finally
     {
         handler__.reclaimOutgoing(og__);
     }
 }
Example #15
0
 public Ice.AsyncResult begin_Login(string user, string pass, _System.Collections.Generic.Dictionary<string, string> ctx__, Ice.AsyncCallback cb__, object cookie__)
 {
     return begin_Login(user, pass, ctx__, true, cb__, cookie__);
 }
Example #16
0
 public Ice.AsyncResult<MCS.Callback_UserManagement_Login> begin_Login(string user, string pass, _System.Collections.Generic.Dictionary<string, string> ctx__)
 {
     return begin_Login(user, pass, ctx__, true, null, null);
 }
Example #17
0
 public Ice.AsyncResult begin_GetUserList(int nBegin, int nCount, int session, _System.Collections.Generic.Dictionary<string, string> ctx__, Ice.AsyncCallback cb__, object cookie__)
 {
     return begin_GetUserList(nBegin, nCount, session, ctx__, true, cb__, cookie__);
 }
Example #18
0
 public Ice.AsyncResult<MCS.Callback_UserManagement_GetUserList> begin_GetUserList(int nBegin, int nCount, int session, _System.Collections.Generic.Dictionary<string, string> ctx__)
 {
     return begin_GetUserList(nBegin, nCount, session, ctx__, true, null, null);
 }
Example #19
0
 public MCS.User[] GetUserList(int nBegin, int nCount, int session, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     IceInternal.Outgoing og__ = handler__.getOutgoing("GetUserList", Ice.OperationMode.Idempotent, context__);
     try
     {
         try
         {
             IceInternal.BasicStream os__ = og__.ostr();
             os__.writeInt(nBegin);
             os__.writeInt(nCount);
             os__.writeInt(session);
         }
         catch(Ice.LocalException ex__)
         {
             og__.abort(ex__);
         }
         bool ok__ = og__.invoke();
         try
         {
             if(!ok__)
             {
                 try
                 {
                     og__.throwUserException();
                 }
                 catch(Ice.UserException ex__)
                 {
                     throw new Ice.UnknownUserException(ex__.ice_name(), ex__);
                 }
             }
             IceInternal.BasicStream is__ = og__.istr();
             is__.startReadEncaps();
             MCS.User[] ret__;
             {
                 int szx__ = is__.readAndCheckSeqSize(9);
                 ret__ = new MCS.User[szx__];
                 for(int ix__ = 0; ix__ < szx__; ++ix__)
                 {
                     ret__[ix__] = new MCS.User();
                     ret__[ix__].read__(is__);
                 }
             }
             is__.endReadEncaps();
             return ret__;
         }
         catch(Ice.LocalException ex__)
         {
             throw new IceInternal.LocalExceptionWrapper(ex__, false);
         }
     }
     finally
     {
         handler__.reclaimOutgoing(og__);
     }
 }
Example #20
0
 public Ice.AsyncResult begin_Logout(int session, _System.Collections.Generic.Dictionary<string, string> ctx__, Ice.AsyncCallback cb__, object cookie__)
 {
     return begin_Logout(session, ctx__, true, cb__, cookie__);
 }
Example #21
0
 public void UpdateData(long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     throw new Ice.CollocationOptimizationException();
 }
Example #22
0
 public Ice.AsyncResult<MCS.Callback_UserManagement_SetUserRight> begin_SetUserRight(int nUID, int nRight, int session, _System.Collections.Generic.Dictionary<string, string> ctx__)
 {
     return begin_SetUserRight(nUID, nRight, session, ctx__, true, null, null);
 }
Example #23
0
 public int WriteData(MCS.GuiHub.GuiCommand Tag, string Val, int session, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     Ice.Current current__ = new Ice.Current();
     initCurrent__(ref current__, "WriteData", Ice.OperationMode.Idempotent, context__);
     int result__ = 0;
     IceInternal.Direct.RunDelegate run__ = delegate(Ice.Object obj__)
     {
         GuiDataHub servant__ = null;
         try
         {
             servant__ = (GuiDataHub)obj__;
         }
         catch(_System.InvalidCastException)
         {
             throw new Ice.OperationNotExistException(current__.id, current__.facet, current__.operation);
         }
         result__ = servant__.WriteData(Tag, Val, session, current__);
         return Ice.DispatchStatus.DispatchOK;
     };
     IceInternal.Direct direct__ = null;
     try
     {
         direct__ = new IceInternal.Direct(current__, run__);
         try
         {
             Ice.DispatchStatus status__ = direct__.servant().collocDispatch__(direct__);
             _System.Diagnostics.Debug.Assert(status__ == Ice.DispatchStatus.DispatchOK);
         }
         finally
         {
             direct__.destroy();
         }
     }
     catch(Ice.SystemException)
     {
         throw;
     }
     catch(_System.Exception ex__)
     {
         IceInternal.LocalExceptionWrapper.throwWrapper(ex__);
     }
     return result__;
 }
Example #24
0
 public Ice.AsyncResult begin_SetUserRight(int nUID, int nRight, int session, _System.Collections.Generic.Dictionary<string, string> ctx__, Ice.AsyncCallback cb__, object cookie__)
 {
     return begin_SetUserRight(nUID, nRight, session, ctx__, true, cb__, cookie__);
 }
Example #25
0
 public void UpdateData(long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     UpdateData(time, data, context__, true);
 }
Example #26
0
 private Ice.AsyncResult<MCS.Callback_UserManagement_SetUserRight> begin_SetUserRight(int nUID, int nRight, int session, _System.Collections.Generic.Dictionary<string, string> ctx__, bool explicitContext__, Ice.AsyncCallback cb__, object cookie__)
 {
     checkAsyncTwowayOnly__(__SetUserRight_name);
     IceInternal.TwowayOutgoingAsync<MCS.Callback_UserManagement_SetUserRight> result__ =  new IceInternal.TwowayOutgoingAsync<MCS.Callback_UserManagement_SetUserRight>(this, __SetUserRight_name, SetUserRight_completed__, cookie__);
     if(cb__ != null)
     {
         result__.whenCompletedWithAsyncCallback(cb__);
     }
     try
     {
         result__.prepare__(__SetUserRight_name, Ice.OperationMode.Idempotent, ctx__, explicitContext__);
         IceInternal.BasicStream os__ = result__.ostr__;
         os__.writeInt(nUID);
         os__.writeInt(nRight);
         os__.writeInt(session);
         os__.endWriteEncaps();
         result__.send__(true);
     }
     catch(Ice.LocalException ex__)
     {
         result__.exceptionAsync__(ex__);
     }
     return result__;
 }
Example #27
0
 public Ice.AsyncResult begin_UpdateData(long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> ctx__, Ice.AsyncCallback cb__, object cookie__)
 {
     return begin_UpdateData(time, data, ctx__, true, cb__, cookie__);
 }
Example #28
0
 public static UserManagementPrx checkedCast(Ice.ObjectPrx b, _System.Collections.Generic.Dictionary<string, string> ctx)
 {
     if(b == null)
     {
         return null;
     }
     UserManagementPrx r = b as UserManagementPrx;
     if((r == null) && b.ice_isA(ice_staticId(), ctx))
     {
         UserManagementPrxHelper h = new UserManagementPrxHelper();
         h.copyFrom__(b);
         r = h;
     }
     return r;
 }
Example #29
0
 public bool UpdateData_async(MCS.AMI_GuiDataUpdater_UpdateData cb__, long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> ctx__)
 {
     Ice.AsyncResult<MCS.Callback_GuiDataUpdater_UpdateData> result__ = begin_UpdateData(time, data, ctx__);
     result__.whenCompleted(cb__.response__, cb__.exception__);
     if(cb__ is Ice.AMISentCallback)
     {
         result__.whenSent((Ice.AsyncCallback)cb__.sent__);
     }
     return result__.sentSynchronously();
 }
Example #30
0
 public void UpdateData(long time, MCS.GuiDataItem data, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     IceInternal.Outgoing og__ = handler__.getOutgoing("UpdateData", Ice.OperationMode.Idempotent, context__);
     try
     {
         try
         {
             IceInternal.BasicStream os__ = og__.ostr();
             os__.writeLong(time);
             if(data == null)
             {
                 MCS.GuiDataItem tmp__ = new MCS.GuiDataItem();
                 tmp__.write__(os__);
             }
             else
             {
                 data.write__(os__);
             }
         }
         catch(Ice.LocalException ex__)
         {
             og__.abort(ex__);
         }
         bool ok__ = og__.invoke();
         if(!og__.istr().isEmpty())
         {
             try
             {
                 if(!ok__)
                 {
                     try
                     {
                         og__.throwUserException();
                     }
                     catch(Ice.UserException ex__)
                     {
                         throw new Ice.UnknownUserException(ex__.ice_name(), ex__);
                     }
                 }
                 og__.istr().skipEmptyEncaps();
             }
             catch(Ice.LocalException ex__)
             {
                 throw new IceInternal.LocalExceptionWrapper(ex__, false);
             }
         }
     }
     finally
     {
         handler__.reclaimOutgoing(og__);
     }
 }
Example #31
0
 public static GuiDataUpdaterPrx checkedCast(Ice.ObjectPrx b, string f, _System.Collections.Generic.Dictionary<string, string> ctx)
 {
     if(b == null)
     {
         return null;
     }
     Ice.ObjectPrx bb = b.ice_facet(f);
     try
     {
         if(bb.ice_isA(ice_staticId(), ctx))
         {
             GuiDataUpdaterPrxHelper h = new GuiDataUpdaterPrxHelper();
             h.copyFrom__(bb);
             return h;
         }
     }
     catch(Ice.FacetNotExistException)
     {
     }
     return null;
 }
Example #32
0
 public void SetDataUpdater(MCS.GuiDataUpdaterPrx updater, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     IceInternal.Outgoing og__ = handler__.getOutgoing("SetDataUpdater", Ice.OperationMode.Idempotent, context__);
     try
     {
         try
         {
             IceInternal.BasicStream os__ = og__.ostr();
             MCS.GuiDataUpdaterPrxHelper.write__(os__, updater);
         }
         catch(Ice.LocalException ex__)
         {
             og__.abort(ex__);
         }
         bool ok__ = og__.invoke();
         if(!og__.istr().isEmpty())
         {
             try
             {
                 if(!ok__)
                 {
                     try
                     {
                         og__.throwUserException();
                     }
                     catch(Ice.UserException ex__)
                     {
                         throw new Ice.UnknownUserException(ex__.ice_name(), ex__);
                     }
                 }
                 og__.istr().skipEmptyEncaps();
             }
             catch(Ice.LocalException ex__)
             {
                 throw new IceInternal.LocalExceptionWrapper(ex__, false);
             }
         }
     }
     finally
     {
         handler__.reclaimOutgoing(og__);
     }
 }
Example #33
0
 private void EraseDataUpdater(MCS.GuiDataUpdaterPrx updater, _System.Collections.Generic.Dictionary<string, string> context__, bool explicitContext__)
 {
     if(explicitContext__ && context__ == null)
     {
         context__ = emptyContext_;
     }
     int cnt__ = 0;
     while(true)
     {
         Ice.ObjectDel_ delBase__ = null;
         try
         {
             delBase__ = getDelegate__(false);
             GuiDataHubDel_ del__ = (GuiDataHubDel_)delBase__;
             del__.EraseDataUpdater(updater, context__);
             return;
         }
         catch(IceInternal.LocalExceptionWrapper ex__)
         {
             handleExceptionWrapperRelaxed__(delBase__, ex__, true, ref cnt__);
         }
         catch(Ice.LocalException ex__)
         {
             handleException__(delBase__, ex__, true, ref cnt__);
         }
     }
 }
Example #34
0
 public int SetPushCmd(MCS.GuiDataUpdaterPrx updater, MCS.GuiHub.PushData[] list, int session, _System.Collections.Generic.Dictionary<string, string> context__)
 {
     IceInternal.Outgoing og__ = handler__.getOutgoing("SetPushCmd", Ice.OperationMode.Idempotent, context__);
     try
     {
         try
         {
             IceInternal.BasicStream os__ = og__.ostr();
             MCS.GuiDataUpdaterPrxHelper.write__(os__, updater);
             if(list == null)
             {
                 os__.writeSize(0);
             }
             else
             {
                 os__.writeSize(list.Length);
                 for(int ix__ = 0; ix__ < list.Length; ++ix__)
                 {
                     os__.writeByte((byte)list[ix__], 10);
                 }
             }
             os__.writeInt(session);
         }
         catch(Ice.LocalException ex__)
         {
             og__.abort(ex__);
         }
         bool ok__ = og__.invoke();
         try
         {
             if(!ok__)
             {
                 try
                 {
                     og__.throwUserException();
                 }
                 catch(Ice.UserException ex__)
                 {
                     throw new Ice.UnknownUserException(ex__.ice_name(), ex__);
                 }
             }
             IceInternal.BasicStream is__ = og__.istr();
             is__.startReadEncaps();
             int ret__;
             ret__ = is__.readInt();
             is__.endReadEncaps();
             return ret__;
         }
         catch(Ice.LocalException ex__)
         {
             throw new IceInternal.LocalExceptionWrapper(ex__, false);
         }
     }
     finally
     {
         handler__.reclaimOutgoing(og__);
     }
 }