MetadataException.cs source code in C# .NET

Source code for the .NET framework in C#

                        

Code:

/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / ndp / fx / src / DataEntity / System / Data / MetadataException.cs / 1 / MetadataException.cs

                            //---------------------------------------------------------------------- 
// 
//      Copyright (c) Microsoft Corporation.  All rights reserved.
// 
// 
// @owner  [....]
//--------------------------------------------------------------------- 
 

namespace System.Data 
{
    using System;
    using System.Data;
    using System.Runtime.Serialization; 
    using System.Security.Permissions;
 
    ///  
    /// metadata exception class
    ///  
    ///
    [Serializable]
    public sealed class MetadataException : EntityException
    { 
        #region Constructors
        ///  
        /// constructor with default message 
        /// 
        public MetadataException() // required ctor 
            : base(System.Data.Entity.Strings.Metadata_General_Error)
        {
            HResult = HResults.Metadata;
        } 

        ///  
        /// default constructor 
        /// 
        /// localized error message 
        public MetadataException(string message) // required ctor
            : base(message)
        {
            HResult = HResults.Metadata; 
        }
 
        ///  
        /// constructor
        ///  
        /// localized error message
        /// inner exception
        public MetadataException(string message, Exception innerException) // required ctor
            : base(message, innerException) 
        {
            HResult = HResults.Metadata; 
        } 

        ///  
        /// constructor for deserialization
        /// 
        /// 
        ///  
        private MetadataException(SerializationInfo info, StreamingContext context)
            : base(info, context) 
        { 
        }
        #endregion 

        #region Methods
        /// 
        /// sets the System.Runtime.Serialization.SerializationInfo 
        /// with information about the exception.
        ///  
        /// The System.Runtime.Serialization.SerializationInfo that holds the serialized 
        /// object data about the exception being thrown.
        ///  
        /// 
        [SecurityPermissionAttribute(SecurityAction.Demand, SerializationFormatter = true)]
        public override void GetObjectData(SerializationInfo info, StreamingContext context)
        { 
            base.GetObjectData(info, context);
        } 
        #endregion 
    }
} 

// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//---------------------------------------------------------------------- 
// 
//      Copyright (c) Microsoft Corporation.  All rights reserved.
// 
// 
// @owner  [....]
//--------------------------------------------------------------------- 
 

namespace System.Data 
{
    using System;
    using System.Data;
    using System.Runtime.Serialization; 
    using System.Security.Permissions;
 
    ///  
    /// metadata exception class
    ///  
    ///
    [Serializable]
    public sealed class MetadataException : EntityException
    { 
        #region Constructors
        ///  
        /// constructor with default message 
        /// 
        public MetadataException() // required ctor 
            : base(System.Data.Entity.Strings.Metadata_General_Error)
        {
            HResult = HResults.Metadata;
        } 

        ///  
        /// default constructor 
        /// 
        /// localized error message 
        public MetadataException(string message) // required ctor
            : base(message)
        {
            HResult = HResults.Metadata; 
        }
 
        ///  
        /// constructor
        ///  
        /// localized error message
        /// inner exception
        public MetadataException(string message, Exception innerException) // required ctor
            : base(message, innerException) 
        {
            HResult = HResults.Metadata; 
        } 

        ///  
        /// constructor for deserialization
        /// 
        /// 
        ///  
        private MetadataException(SerializationInfo info, StreamingContext context)
            : base(info, context) 
        { 
        }
        #endregion 

        #region Methods
        /// 
        /// sets the System.Runtime.Serialization.SerializationInfo 
        /// with information about the exception.
        ///  
        /// The System.Runtime.Serialization.SerializationInfo that holds the serialized 
        /// object data about the exception being thrown.
        ///  
        /// 
        [SecurityPermissionAttribute(SecurityAction.Demand, SerializationFormatter = true)]
        public override void GetObjectData(SerializationInfo info, StreamingContext context)
        { 
            base.GetObjectData(info, context);
        } 
        #endregion 
    }
} 

// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
                        

Link Menu

Network programming in C#, Network Programming in VB.NET, Network Programming in .NET
This book is available now!
Buy at Amazon US or
Buy at Amazon UK