public static QQException CreateException(QQErrorCode errorCode, string msg) { if (msg.IsNullOrEmpty()) { return(CreateException(errorCode)); } return(new QQException(errorCode, msg)); }
private bool DoRetryIt(QQErrorCode code, Exception t) { if (ActionFuture.IsCanceled) { return(true); } ++_retryTimes; if (_retryTimes < QQConstants.MAX_RETRY_TIMES) { NotifyActionEvent(QQActionEventType.EVT_RETRY, new QQException(code, t)); Thread.Sleep(1000); Context.PushActor(new HttpActor(HttpActorType.BUILD_REQUEST, Context, this)); return(true); } return(false); }
public QQException(Exception e) : base(e.Message, e) { ErrorCode = GetErrorCode(e); }
public QQException(QQErrorCode errorCode, string msg) : base(msg) { ErrorCode = errorCode; }
private bool DoRetryIt(QQErrorCode code, Exception t) { if (ActionFuture.IsCanceled) return true; ++_retryTimes; if (_retryTimes < QQConstants.MAX_RETRY_TIMES) { NotifyActionEvent(QQActionEventType.EVT_RETRY, new QQException(code, t)); Thread.Sleep(1000); Context.PushActor(new HttpActor(HttpActorType.BUILD_REQUEST, Context, this)); return true; } return false; }
protected Task<ActionEvent> NotifyErrorEventAsync(QQErrorCode code, string msg) { return NotifyErrorEventAsync(QQException.CreateException(code, msg)); }
/** * <p>Constructor for QQException.</p> * * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param e a {@link java.lang.Throwable} object. */ public QQException(QQErrorCode errorCode, Exception e) : base(errorCode.ToString(), e) { this.errorCode = errorCode; }
public QQException(Exception e) : base(e.Message) { ErrorCode = GetErrorCode(e); _stackTrace = e.StackTrace; }
public QQException(QQErrorCode errorCode, Exception e) : base(e.Message, e) { ErrorCode = errorCode; }
public QQException(QQErrorCode errorCode) : base(errorCode.ToString()) { ErrorCode = errorCode; }
public static QQException CreateException(QQErrorCode errorCode, string msg) { if (msg.IsNullOrEmpty()) return CreateException(errorCode); return new QQException(errorCode, msg); }
public static QQException CreateException(QQErrorCode errorCode) { return Exceptions.GetOrAdd(errorCode, key => new QQException(errorCode, "")); }
public QQException(QQErrorCode errorCode, Exception e) : base(e.Message) { ErrorCode = errorCode; _stackTrace = e.StackTrace; }
public static QQException CreateException(QQErrorCode errorCode) { return(Exceptions.GetOrAdd(errorCode, key => new QQException(errorCode, ""))); }
/** * <p>Constructor for QQException.</p> * * @param errorCode a {@link iqq.im.QQException.QQErrorCode} object. * @param msg a {@link java.lang.String} object. */ public QQException(QQErrorCode errorCode, String msg) : base(msg) { this.errorCode = errorCode; }
protected Task <ActionEvent> NotifyErrorEventAsync(QQErrorCode code, string msg) { return(NotifyErrorEventAsync(QQException.CreateException(code, msg))); }
public QQException(QQErrorCode errorCode) : this(errorCode, errorCode.GetDescription()) { ErrorCode = errorCode; }