Beispiel #1
0
        internal static Exception ExceptionOnError(XmlaResultCollection col)
        {
            XmlaException ex = new XmlaException(col);

            if (col.ContainsInvalidSessionError)
            {
                return(new XmlaStreamException(ex));
            }
            return(ex);
        }
Beispiel #2
0
        internal static Exception ExceptionOnError(XmlaResult res)
        {
            XmlaException ex = new XmlaException(res);

            if (res.ContainsInvalidSessionError)
            {
                return(new XmlaStreamException(ex));
            }
            return(ex);
        }
 private void TranslateException(XmlaException innerException)
 {
     foreach (XmlaResult xmlaResult in ((IEnumerable)innerException.Results))
     {
         foreach (XmlaMessage xmlaMessage in ((IEnumerable)xmlaResult.Messages))
         {
             if (xmlaMessage is XmlaError)
             {
                 AdomdError error = new AdomdError((XmlaError)xmlaMessage);
                 if (this.errors == null)
                 {
                     this.errors = new AdomdErrorCollection();
                 }
                 this.errors.Add(error);
             }
         }
     }
 }
 internal AdomdErrorResponseException(XmlaException innerException)
 {
     this.TranslateException(innerException);
 }