546fa38894d2a015f6174d89ea014efa22a78bd8
[mono.git] / mcs / class / corlib / System.Security.Cryptography / CryptographicUnexpectedOperationExcpetion.cs
1 //
2 // System.Security.Cryptography.CryptographicUnexpectedOperationException.cs
3 //
4 // Author:
5 //   Thomas Neidhart (tome@sbox.tugraz.at)
6 //
7 // (C) 2004 Novell (http://www.novell.com)
8 //
9
10 using System;
11 using System.Globalization;
12 using System.Runtime.Serialization;
13
14 namespace System.Security.Cryptography {
15
16 [Serializable]
17 public class CryptographicUnexpectedOperationException : CryptographicException {
18
19         public CryptographicUnexpectedOperationException ()
20                 : base (Locale.GetText ("Unexpected error occured during a cryptographic operation."))
21         {
22                 // Default to CORSEC_E_CRYPTO_UNEX_OPER (CorError.h)
23                 HResult = unchecked ((int)0x80131431);
24         }
25
26         public CryptographicUnexpectedOperationException (string message)
27                 : base (message)
28         {
29                 HResult = unchecked ((int)0x80131431);
30         }
31
32         public CryptographicUnexpectedOperationException (string message, Exception inner)
33                 : base (message, inner)
34         {
35                 HResult = unchecked ((int)0x80131431);
36         }
37
38         public CryptographicUnexpectedOperationException (string format, string insert)
39                 : base (String.Format(format, insert))
40         {
41                 HResult = unchecked ((int)0x80131431);
42         }
43
44         protected CryptographicUnexpectedOperationException (SerializationInfo info, StreamingContext context)
45                 : base (info, context) 
46         {
47         }
48 }
49
50 }