InvalidEnumArgumentException.cs 735 B

1234567891011121314151617181920212223242526272829303132333435
  1. //
  2. // System.ComponentModel.InvalidEnumArgumentException.cs
  3. //
  4. // Authors:
  5. // Duncan Mak ([email protected])
  6. // Andreas Nahr ([email protected])
  7. //
  8. // (C) 2002 Ximian, Inc. http://www.ximian.com
  9. // (C) 2003 Andreas Nahr
  10. //
  11. using System;
  12. namespace System.ComponentModel
  13. {
  14. public class InvalidEnumArgumentException : ArgumentException
  15. {
  16. public InvalidEnumArgumentException ()
  17. {
  18. }
  19. public InvalidEnumArgumentException (string message) : base (message)
  20. {
  21. }
  22. public InvalidEnumArgumentException (string argumentName, int invalidValue, Type enumClass) :
  23. base (argumentName + " is invalid because this value, " + invalidValue + " is not of type " +
  24. enumClass.Name, argumentName)
  25. {
  26. }
  27. }
  28. }