public void finished(Ice.LocalException ex, bool sent) { _m.Lock(); if (_remoteObserver != null) { _remoteObserver.failed(ex.ice_name()); _remoteObserver.detach(); } try { _exception = ex; _m.Notify(); } finally { _m.Unlock(); } }
public void finished(Ice.LocalException ex, bool sent) { _m.Lock(); try { Debug.Assert(_state <= StateInProgress); if (_remoteObserver != null) { _remoteObserver.failed(ex.ice_name()); _remoteObserver.detach(); _remoteObserver = null; } _state = StateFailed; _exception = ex; _sent = sent; _m.Notify(); } finally { _m.Unlock(); } }
public static void throwWrapper(System.Exception ex) { Ice.UserException userException = ex as Ice.UserException; if (userException != null) { throw new LocalExceptionWrapper(new Ice.UnknownUserException(userException.ice_name()), false); } Ice.LocalException localException = ex as Ice.LocalException; if (localException != null) { if (ex is Ice.UnknownException || ex is Ice.ObjectNotExistException || ex is Ice.OperationNotExistException || ex is Ice.FacetNotExistException) { throw new LocalExceptionWrapper(localException, false); } throw new LocalExceptionWrapper(new Ice.UnknownLocalException(localException.ice_name()), false); } throw new LocalExceptionWrapper(new Ice.UnknownException(ex.GetType().FullName), false); }