'------------------------------------------------------------------------------
' <auto-generated>
'     此代码由工具生成。
'     运行时版本:2.0.50727.3649
'
'     对此文件的更改可能会导致不正确的行为，并且如果
'     重新生成代码，这些更改将会丢失。
' </auto-generated>
'------------------------------------------------------------------------------

Option Strict On
Option Explicit On

Imports System
Imports System.Collections.Generic
Imports System.ComponentModel
Imports System.Data
Imports System.Data.Linq
Imports System.Data.Linq.Mapping
Imports System.Linq
Imports System.Linq.Expressions
Imports System.Reflection


<System.Data.Linq.Mapping.DatabaseAttribute(Name:="WebSiteII")>  _
Partial Public Class DB_ErrorMessageDataContext
	Inherits System.Data.Linq.DataContext
	
	Private Shared mappingSource As System.Data.Linq.Mapping.MappingSource = New AttributeMappingSource
	
  #Region "Extensibility Method Definitions"
  Partial Private Sub OnCreated()
  End Sub
  Partial Private Sub InsertErrorMessage(instance As ErrorMessage)
    End Sub
  Partial Private Sub UpdateErrorMessage(instance As ErrorMessage)
    End Sub
  Partial Private Sub DeleteErrorMessage(instance As ErrorMessage)
    End Sub
  #End Region
	
	Public Sub New()
        MyBase.New(System.Web.Configuration.WebConfigurationManager.ConnectionStrings("XrenCRMConnString").ToString, mappingSource)
		OnCreated
	End Sub
	
	Public Sub New(ByVal connection As String)
		MyBase.New(connection, mappingSource)
		OnCreated
	End Sub
	
	Public Sub New(ByVal connection As System.Data.IDbConnection)
		MyBase.New(connection, mappingSource)
		OnCreated
	End Sub
	
	Public Sub New(ByVal connection As String, ByVal mappingSource As System.Data.Linq.Mapping.MappingSource)
		MyBase.New(connection, mappingSource)
		OnCreated
	End Sub
	
	Public Sub New(ByVal connection As System.Data.IDbConnection, ByVal mappingSource As System.Data.Linq.Mapping.MappingSource)
		MyBase.New(connection, mappingSource)
		OnCreated
	End Sub
	
	Public ReadOnly Property ErrorMessage() As System.Data.Linq.Table(Of ErrorMessage)
		Get
			Return Me.GetTable(Of ErrorMessage)
		End Get
	End Property
End Class

<Table(Name:="dbo.ErrorMessage")>  _
Partial Public Class ErrorMessage
	Implements System.ComponentModel.INotifyPropertyChanging, System.ComponentModel.INotifyPropertyChanged
	
	Private Shared emptyChangingEventArgs As PropertyChangingEventArgs = New PropertyChangingEventArgs(String.Empty)
	
	Private _ID As Integer
	
	Private _Source As String
	
	Private _Message As String
	
	Private _StackTrace As String
	
    #Region "Extensibility Method Definitions"
    Partial Private Sub OnLoaded()
    End Sub
    Partial Private Sub OnValidate(action As System.Data.Linq.ChangeAction)
    End Sub
    Partial Private Sub OnCreated()
    End Sub
    Partial Private Sub OnIDChanging(value As Integer)
    End Sub
    Partial Private Sub OnIDChanged()
    End Sub
    Partial Private Sub OnSourceChanging(value As String)
    End Sub
    Partial Private Sub OnSourceChanged()
    End Sub
    Partial Private Sub OnMessageChanging(value As String)
    End Sub
    Partial Private Sub OnMessageChanged()
    End Sub
    Partial Private Sub OnStackTraceChanging(value As String)
    End Sub
    Partial Private Sub OnStackTraceChanged()
    End Sub
    #End Region
	
	Public Sub New()
		MyBase.New
		OnCreated
	End Sub
	
	<Column(Storage:="_ID", AutoSync:=AutoSync.OnInsert, DbType:="Int NOT NULL IDENTITY", IsPrimaryKey:=true, IsDbGenerated:=true)>  _
	Public Property ID() As Integer
		Get
			Return Me._ID
		End Get
		Set
			If ((Me._ID = value)  _
						= false) Then
				Me.OnIDChanging(value)
				Me.SendPropertyChanging
				Me._ID = value
				Me.SendPropertyChanged("ID")
				Me.OnIDChanged
			End If
		End Set
	End Property
	
	<Column(Storage:="_Source", DbType:="NVarChar(500) NOT NULL", CanBeNull:=false)>  _
	Public Property Source() As String
		Get
			Return Me._Source
		End Get
		Set
			If (String.Equals(Me._Source, value) = false) Then
				Me.OnSourceChanging(value)
				Me.SendPropertyChanging
				Me._Source = value
				Me.SendPropertyChanged("Source")
				Me.OnSourceChanged
			End If
		End Set
	End Property
	
	<Column(Storage:="_Message", DbType:="NVarChar(500) NOT NULL", CanBeNull:=false)>  _
	Public Property Message() As String
		Get
			Return Me._Message
		End Get
		Set
			If (String.Equals(Me._Message, value) = false) Then
				Me.OnMessageChanging(value)
				Me.SendPropertyChanging
				Me._Message = value
				Me.SendPropertyChanged("Message")
				Me.OnMessageChanged
			End If
		End Set
	End Property
	
	<Column(Storage:="_StackTrace", DbType:="NVarChar(MAX) NOT NULL", CanBeNull:=false)>  _
	Public Property StackTrace() As String
		Get
			Return Me._StackTrace
		End Get
		Set
			If (String.Equals(Me._StackTrace, value) = false) Then
				Me.OnStackTraceChanging(value)
				Me.SendPropertyChanging
				Me._StackTrace = value
				Me.SendPropertyChanged("StackTrace")
				Me.OnStackTraceChanged
			End If
		End Set
	End Property
	
	Public Event PropertyChanging As PropertyChangingEventHandler Implements System.ComponentModel.INotifyPropertyChanging.PropertyChanging
	
	Public Event PropertyChanged As PropertyChangedEventHandler Implements System.ComponentModel.INotifyPropertyChanged.PropertyChanged
	
	Protected Overridable Sub SendPropertyChanging()
		If ((Me.PropertyChangingEvent Is Nothing)  _
					= false) Then
			RaiseEvent PropertyChanging(Me, emptyChangingEventArgs)
		End If
	End Sub
	
	Protected Overridable Sub SendPropertyChanged(ByVal propertyName As [String])
		If ((Me.PropertyChangedEvent Is Nothing)  _
					= false) Then
			RaiseEvent PropertyChanged(Me, New PropertyChangedEventArgs(propertyName))
		End If
	End Sub
End Class
