summary refs log tree commit diff
path: root/crypto/src/util/MemoableResetException.cs
diff options
context:
space:
mode:
authorTim Whittington <bc@whittington.net.nz>2013-10-12 19:46:25 +1300
committerTim Whittington <bc@whittington.net.nz>2013-10-20 21:32:33 +1300
commitf64b37993aaec3f2baaab236af58c295b06c9f92 (patch)
treeced19bc4695aafe6112dbada80601d5cf8def51f /crypto/src/util/MemoableResetException.cs
parentPort SkeinDigest and SkeinMac from bc-java. (diff)
downloadBouncyCastle.NET-ed25519-f64b37993aaec3f2baaab236af58c295b06c9f92.tar.xz
Port Memoable digest support from bc-java.
Diffstat (limited to 'crypto/src/util/MemoableResetException.cs')
-rw-r--r--crypto/src/util/MemoableResetException.cs27
1 files changed, 27 insertions, 0 deletions
diff --git a/crypto/src/util/MemoableResetException.cs b/crypto/src/util/MemoableResetException.cs
new file mode 100644
index 000000000..d9542dab2
--- /dev/null
+++ b/crypto/src/util/MemoableResetException.cs
@@ -0,0 +1,27 @@
+using System;
+
+namespace Org.BouncyCastle.Utilities
+{
+	/**
+	 * Exception to be thrown on a failure to reset an object implementing Memoable.
+	 * <p>
+	 * The exception extends ClassCastException to enable users to have a single handling case,
+	 * only introducing specific handling of this one if required.
+	 * </p>
+	 */
+	public class MemoableResetException
+		: InvalidCastException
+	{
+		/**
+	     * Basic Constructor.
+	     *
+	     * @param msg message to be associated with this exception.
+	     */
+		public MemoableResetException(string msg)
+			: base(msg)
+		{
+		}
+	}
+
+}
+