Merge pull request #3199 from lambdageek/dev/proxy-setter
[mono.git] / mcs / class / Facades / System.Runtime.Serialization.Xml / NotImplemented.cs
1 // Licensed to the .NET Foundation under one or more agreements.
2 // The .NET Foundation licenses this file to you under the MIT license.
3 // See the LICENSE file in the project root for more information.
4
5 namespace System
6 {
7     //
8     // This class enables one to throw a NotImplementedException using the following idiom:
9     //
10     //     throw NotImplemented.ByDesign;
11     //
12     // Used by methods whose intended implementation is to throw a NotImplementedException (typically
13     // virtual methods in public abstract classes that intended to be subclassed by third parties.)
14     //
15     // This makes it distinguishable both from human eyes and CCI from NYI's that truly represent undone work.
16     //
17     internal static class NotImplemented
18     {
19         internal static Exception ByDesign
20         {
21             get
22             {
23                 return new NotImplementedException();
24             }
25         }
26
27         internal static Exception ByDesignWithMessage(String message)
28         {
29             return new NotImplementedException(message);
30         }
31     }
32 }