コード例 #1
0
ファイル: FaultDto.cs プロジェクト: AmarPotki/TelegramBot
 public FaultDto(string location, string message, FaultSource faultSource)
 {
     Id          = Guid.NewGuid();
     Message     = message;
     FaultSource = faultSource;
     Location    = location;
 }
コード例 #2
0
 public MonMsg_H2G(FaultSource faultSource, int faultType)
 {
     this.FaultSource = (int) faultSource;
     this.FaultType = faultType;
 }
コード例 #3
0
 public MonMsg_H2G(FaultSource faultSource, int faultType)
 {
     this.FaultSource = (int)faultSource;
     this.FaultType   = faultType;
 }
コード例 #4
0
ファイル: FaultHelper.cs プロジェクト: mujiansu/Lync
        /// <summary>
        /// Method to create generic operation fault.
        /// </summary>
        /// <param name="message">Fault message.</param>
        /// <param name="innerException">Inner exception, if any.</param>
        /// <param name="faultSource">Fault source.</param>
        /// <returns>Operation fault.</returns>
        private static OperationFault CreateOperationFault(string message, Exception innerException, FaultSource faultSource)
        {
            Debug.Assert(!String.IsNullOrEmpty(message), "Provide a valid message string");

            OperationFault operationFault = new OperationFault();

            operationFault.Message = message;
            if (innerException != null)
            {
                operationFault.InnerExceptionMessage = innerException.Message;
            }
            operationFault.Source = faultSource;
            return(operationFault);
        }