The Labs \ Source Viewer \ SSCLI \ System.Security \ XmlSyntaxException

  1. // ==++==
  2. //
  3. //
  4. // Copyright (c) 2006 Microsoft Corporation. All rights reserved.
  5. //
  6. // The use and distribution terms for this software are contained in the file
  7. // named license.txt, which can be found in the root of this distribution.
  8. // By using this software in any fashion, you are agreeing to be bound by the
  9. // terms of this license.
  10. //
  11. // You must not remove this notice, or any other, from this software.
  12. //
  13. //
  14. // ==--==
  15. namespace System.Security
  16. {
  17.     using System;
  18.     using System.Runtime.Serialization;
  19.     using System.Globalization;
  20.    
  21.     [System.Runtime.InteropServices.ComVisible(true)]
  22.     [Serializable()]
  23.     public sealed class XmlSyntaxException : SystemException
  24.     {
  25.         public XmlSyntaxException() : base(Environment.GetResourceString("XMLSyntax_InvalidSyntax"))
  26.         {
  27.             SetErrorCode(__HResults.CORSEC_E_XMLSYNTAX);
  28.         }
  29.        
  30.         public XmlSyntaxException(string message) : base(message)
  31.         {
  32.             SetErrorCode(__HResults.CORSEC_E_XMLSYNTAX);
  33.         }
  34.        
  35.         public XmlSyntaxException(string message, Exception inner) : base(message, inner)
  36.         {
  37.             SetErrorCode(__HResults.CORSEC_E_XMLSYNTAX);
  38.         }
  39.        
  40.         public XmlSyntaxException(int lineNumber) : base(String.Format(CultureInfo.CurrentCulture, Environment.GetResourceString("XMLSyntax_SyntaxError"), lineNumber))
  41.         {
  42.             SetErrorCode(__HResults.CORSEC_E_XMLSYNTAX);
  43.         }
  44.        
  45.         public XmlSyntaxException(int lineNumber, string message) : base(String.Format(CultureInfo.CurrentCulture, Environment.GetResourceString("XMLSyntax_SyntaxErrorEx"), lineNumber, message))
  46.         {
  47.             SetErrorCode(__HResults.CORSEC_E_XMLSYNTAX);
  48.         }
  49.        
  50.         internal XmlSyntaxException(SerializationInfo info, StreamingContext context) : base(info, context)
  51.         {
  52.         }
  53.     }
  54. }

Developer Fusion