コード例 #1
0
        public static RightsManagedMessageDecryptionStatus CreateFromException(Exception exception)
        {
            if (exception == null)
            {
                throw new ArgumentNullException("exception");
            }
            RightsManagementPermanentException ex = exception as RightsManagementPermanentException;

            if (ex != null)
            {
                return(new RightsManagedMessageDecryptionStatus(ex.FailureCode, ex));
            }
            return(new RightsManagedMessageDecryptionStatus(RightsManagementFailureCode.UnknownFailure, exception));
        }
コード例 #2
0
 public RightsManagementPermanentException(LocalizedString message, LocalizedException innerException) : base(message, innerException)
 {
     this.FailureCode = RightsManagementPermanentException.GetRightsManagementFailureCode(innerException);
 }