﻿#pragma warning disable 1591
//------------------------------------------------------------------------------
// <auto-generated>
//     This code was generated by a tool.
//     Runtime Version:4.0.30319.42000
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------

namespace MArchive.DataContext
{
	using System.Data.Linq;
	using System.Data.Linq.Mapping;
	using System.Data;
	using System.Collections.Generic;
	using System.Reflection;
	using System.Linq;
	using System.Linq.Expressions;
	using System.ComponentModel;
	using System;
	
	
	[global::System.Data.Linq.Mapping.DatabaseAttribute(Name="MovieArchive")]
	public partial class MovieArchiveDBDataContext : System.Data.Linq.DataContext
	{
		
		private static System.Data.Linq.Mapping.MappingSource mappingSource = new AttributeMappingSource();
		
    #region Extensibility Method Definitions
    partial void OnCreated();
    partial void InsertINF_Actor(INF_Actor instance);
    partial void UpdateINF_Actor(INF_Actor instance);
    partial void DeleteINF_Actor(INF_Actor instance);
    partial void InsertUser(User instance);
    partial void UpdateUser(User instance);
    partial void DeleteUser(User instance);
    partial void InsertINF_Director(INF_Director instance);
    partial void UpdateINF_Director(INF_Director instance);
    partial void DeleteINF_Director(INF_Director instance);
    partial void InsertINF_Language(INF_Language instance);
    partial void UpdateINF_Language(INF_Language instance);
    partial void DeleteINF_Language(INF_Language instance);
    partial void InsertINF_Type(INF_Type instance);
    partial void UpdateINF_Type(INF_Type instance);
    partial void DeleteINF_Type(INF_Type instance);
    partial void InsertINF_Writer(INF_Writer instance);
    partial void UpdateINF_Writer(INF_Writer instance);
    partial void DeleteINF_Writer(INF_Writer instance);
    partial void InsertMOV_M_Actor(MOV_M_Actor instance);
    partial void UpdateMOV_M_Actor(MOV_M_Actor instance);
    partial void DeleteMOV_M_Actor(MOV_M_Actor instance);
    partial void InsertMOV_M_Archive(MOV_M_Archive instance);
    partial void UpdateMOV_M_Archive(MOV_M_Archive instance);
    partial void DeleteMOV_M_Archive(MOV_M_Archive instance);
    partial void InsertMOV_M_Director(MOV_M_Director instance);
    partial void UpdateMOV_M_Director(MOV_M_Director instance);
    partial void DeleteMOV_M_Director(MOV_M_Director instance);
    partial void InsertMOV_M_Language(MOV_M_Language instance);
    partial void UpdateMOV_M_Language(MOV_M_Language instance);
    partial void DeleteMOV_M_Language(MOV_M_Language instance);
    partial void InsertMOV_M_Movie(MOV_M_Movie instance);
    partial void UpdateMOV_M_Movie(MOV_M_Movie instance);
    partial void DeleteMOV_M_Movie(MOV_M_Movie instance);
    partial void InsertMOV_M_Name(MOV_M_Name instance);
    partial void UpdateMOV_M_Name(MOV_M_Name instance);
    partial void DeleteMOV_M_Name(MOV_M_Name instance);
    partial void InsertMOV_M_Type(MOV_M_Type instance);
    partial void UpdateMOV_M_Type(MOV_M_Type instance);
    partial void DeleteMOV_M_Type(MOV_M_Type instance);
    partial void InsertMOV_M_UserRating(MOV_M_UserRating instance);
    partial void UpdateMOV_M_UserRating(MOV_M_UserRating instance);
    partial void DeleteMOV_M_UserRating(MOV_M_UserRating instance);
    partial void InsertMOV_M_Writer(MOV_M_Writer instance);
    partial void UpdateMOV_M_Writer(MOV_M_Writer instance);
    partial void DeleteMOV_M_Writer(MOV_M_Writer instance);
    partial void InsertMOV_UserMovie(MOV_UserMovie instance);
    partial void UpdateMOV_UserMovie(MOV_UserMovie instance);
    partial void DeleteMOV_UserMovie(MOV_UserMovie instance);
    partial void InsertUSR_Archive(USR_Archive instance);
    partial void UpdateUSR_Archive(USR_Archive instance);
    partial void DeleteUSR_Archive(USR_Archive instance);
    partial void InsertUSR_List(USR_List instance);
    partial void UpdateUSR_List(USR_List instance);
    partial void DeleteUSR_List(USR_List instance);
    partial void InsertUSR_ListMovie(USR_ListMovie instance);
    partial void UpdateUSR_ListMovie(USR_ListMovie instance);
    partial void DeleteUSR_ListMovie(USR_ListMovie instance);
    partial void InsertUSR_Friend(USR_Friend instance);
    partial void UpdateUSR_Friend(USR_Friend instance);
    partial void DeleteUSR_Friend(USR_Friend instance);
    partial void InsertUSR_FriendRequest(USR_FriendRequest instance);
    partial void UpdateUSR_FriendRequest(USR_FriendRequest instance);
    partial void DeleteUSR_FriendRequest(USR_FriendRequest instance);
    partial void InsertUSR_FriendRequestStatus(USR_FriendRequestStatus instance);
    partial void UpdateUSR_FriendRequestStatus(USR_FriendRequestStatus instance);
    partial void DeleteUSR_FriendRequestStatus(USR_FriendRequestStatus instance);
    partial void InsertUSR_UserListAuthorization(USR_UserListAuthorization instance);
    partial void UpdateUSR_UserListAuthorization(USR_UserListAuthorization instance);
    partial void DeleteUSR_UserListAuthorization(USR_UserListAuthorization instance);
    partial void InsertUSR_UserListAuthorizationType(USR_UserListAuthorizationType instance);
    partial void UpdateUSR_UserListAuthorizationType(USR_UserListAuthorizationType instance);
    partial void DeleteUSR_UserListAuthorizationType(USR_UserListAuthorizationType instance);
    #endregion
		
		public MovieArchiveDBDataContext() : 
				base(global::MArchive.DataContext.Properties.Settings.Default.MovieArchiveConnectionString2, mappingSource)
		{
			OnCreated();
		}
		
		public MovieArchiveDBDataContext(string connection) : 
				base(connection, mappingSource)
		{
			OnCreated();
		}
		
		public MovieArchiveDBDataContext(System.Data.IDbConnection connection) : 
				base(connection, mappingSource)
		{
			OnCreated();
		}
		
		public MovieArchiveDBDataContext(string connection, System.Data.Linq.Mapping.MappingSource mappingSource) : 
				base(connection, mappingSource)
		{
			OnCreated();
		}
		
		public MovieArchiveDBDataContext(System.Data.IDbConnection connection, System.Data.Linq.Mapping.MappingSource mappingSource) : 
				base(connection, mappingSource)
		{
			OnCreated();
		}
		
		public System.Data.Linq.Table<INF_Actor> INF_Actors
		{
			get
			{
				return this.GetTable<INF_Actor>();
			}
		}
		
		public System.Data.Linq.Table<User> Users
		{
			get
			{
				return this.GetTable<User>();
			}
		}
		
		public System.Data.Linq.Table<INF_Director> INF_Directors
		{
			get
			{
				return this.GetTable<INF_Director>();
			}
		}
		
		public System.Data.Linq.Table<INF_Language> INF_Languages
		{
			get
			{
				return this.GetTable<INF_Language>();
			}
		}
		
		public System.Data.Linq.Table<INF_Type> INF_Types
		{
			get
			{
				return this.GetTable<INF_Type>();
			}
		}
		
		public System.Data.Linq.Table<INF_Writer> INF_Writers
		{
			get
			{
				return this.GetTable<INF_Writer>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Actor> MOV_M_Actors
		{
			get
			{
				return this.GetTable<MOV_M_Actor>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Archive> MOV_M_Archives
		{
			get
			{
				return this.GetTable<MOV_M_Archive>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Director> MOV_M_Directors
		{
			get
			{
				return this.GetTable<MOV_M_Director>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Language> MOV_M_Languages
		{
			get
			{
				return this.GetTable<MOV_M_Language>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Movie> MOV_M_Movies
		{
			get
			{
				return this.GetTable<MOV_M_Movie>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Name> MOV_M_Names
		{
			get
			{
				return this.GetTable<MOV_M_Name>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Type> MOV_M_Types
		{
			get
			{
				return this.GetTable<MOV_M_Type>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_UserRating> MOV_M_UserRatings
		{
			get
			{
				return this.GetTable<MOV_M_UserRating>();
			}
		}
		
		public System.Data.Linq.Table<MOV_M_Writer> MOV_M_Writers
		{
			get
			{
				return this.GetTable<MOV_M_Writer>();
			}
		}
		
		public System.Data.Linq.Table<MOV_UserMovie> MOV_UserMovies
		{
			get
			{
				return this.GetTable<MOV_UserMovie>();
			}
		}
		
		public System.Data.Linq.Table<MoviesNotInHardDisk> MoviesNotInHardDisks
		{
			get
			{
				return this.GetTable<MoviesNotInHardDisk>();
			}
		}
		
		public System.Data.Linq.Table<vUserListMoviesDetail> vUserListMoviesDetails
		{
			get
			{
				return this.GetTable<vUserListMoviesDetail>();
			}
		}
		
		public System.Data.Linq.Table<vMovieActor> vMovieActors
		{
			get
			{
				return this.GetTable<vMovieActor>();
			}
		}
		
		public System.Data.Linq.Table<vMovieDirector> vMovieDirectors
		{
			get
			{
				return this.GetTable<vMovieDirector>();
			}
		}
		
		public System.Data.Linq.Table<vMovieLanguage> vMovieLanguages
		{
			get
			{
				return this.GetTable<vMovieLanguage>();
			}
		}
		
		public System.Data.Linq.Table<vMovieName> vMovieNames
		{
			get
			{
				return this.GetTable<vMovieName>();
			}
		}
		
		public System.Data.Linq.Table<vMovieType> vMovieTypes
		{
			get
			{
				return this.GetTable<vMovieType>();
			}
		}
		
		public System.Data.Linq.Table<vMovieUserRating> vMovieUserRatings
		{
			get
			{
				return this.GetTable<vMovieUserRating>();
			}
		}
		
		public System.Data.Linq.Table<vMovieWriter> vMovieWriters
		{
			get
			{
				return this.GetTable<vMovieWriter>();
			}
		}
		
		public System.Data.Linq.Table<USR_Archive> USR_Archives
		{
			get
			{
				return this.GetTable<USR_Archive>();
			}
		}
		
		public System.Data.Linq.Table<USR_List> USR_Lists
		{
			get
			{
				return this.GetTable<USR_List>();
			}
		}
		
		public System.Data.Linq.Table<USR_ListMovie> USR_ListMovies
		{
			get
			{
				return this.GetTable<USR_ListMovie>();
			}
		}
		
		public System.Data.Linq.Table<vMovieArchive> vMovieArchives
		{
			get
			{
				return this.GetTable<vMovieArchive>();
			}
		}
		
		public System.Data.Linq.Table<USR_Friend> USR_Friends
		{
			get
			{
				return this.GetTable<USR_Friend>();
			}
		}
		
		public System.Data.Linq.Table<USR_FriendRequest> USR_FriendRequests
		{
			get
			{
				return this.GetTable<USR_FriendRequest>();
			}
		}
		
		public System.Data.Linq.Table<USR_FriendRequestStatus> USR_FriendRequestStatus
		{
			get
			{
				return this.GetTable<USR_FriendRequestStatus>();
			}
		}
		
		public System.Data.Linq.Table<USR_UserListAuthorization> USR_UserListAuthorizations
		{
			get
			{
				return this.GetTable<USR_UserListAuthorization>();
			}
		}
		
		public System.Data.Linq.Table<USR_UserListAuthorizationType> USR_UserListAuthorizationTypes
		{
			get
			{
				return this.GetTable<USR_UserListAuthorizationType>();
			}
		}
		
		[global::System.Data.Linq.Mapping.FunctionAttribute(Name="dbo.ResetImdbId")]
		public int ResetImdbId([global::System.Data.Linq.Mapping.ParameterAttribute(Name="MovieID", DbType="Int")] System.Nullable<int> movieID)
		{
			IExecuteResult result = this.ExecuteMethodCall(this, ((MethodInfo)(MethodInfo.GetCurrentMethod())), movieID);
			return ((int)(result.ReturnValue));
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.INF_Actor")]
	public partial class INF_Actor : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<MOV_M_Actor> _MOV_M_Actors;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public INF_Actor()
		{
			this._MOV_M_Actors = new EntitySet<MOV_M_Actor>(new Action<MOV_M_Actor>(this.attach_MOV_M_Actors), new Action<MOV_M_Actor>(this.detach_MOV_M_Actors));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100)")]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Actor_MOV_M_Actor", Storage="_MOV_M_Actors", ThisKey="ID", OtherKey="ActorID")]
		public EntitySet<MOV_M_Actor> MOV_M_Actors
		{
			get
			{
				return this._MOV_M_Actors;
			}
			set
			{
				this._MOV_M_Actors.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Actors(MOV_M_Actor entity)
		{
			this.SendPropertyChanging();
			entity.INF_Actor = this;
		}
		
		private void detach_MOV_M_Actors(MOV_M_Actor entity)
		{
			this.SendPropertyChanging();
			entity.INF_Actor = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.[User]")]
	public partial class User : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private string _Username;
		
		private string _Password;
		
		private string _Name;
		
		private string _Email;
		
		private System.Nullable<bool> _IsAdmin;
		
		private EntitySet<MOV_M_UserRating> _MOV_M_UserRatings;
		
		private EntitySet<MOV_UserMovie> _MOV_UserMovies;
		
		private EntitySet<USR_Archive> _USR_Archives;
		
		private EntitySet<USR_List> _USR_Lists;
		
		private EntitySet<USR_Friend> _USR_Friends;
		
		private EntitySet<USR_Friend> _USR_Friends1;
		
		private EntitySet<USR_FriendRequest> _USR_FriendRequests;
		
		private EntitySet<USR_FriendRequest> _USR_FriendRequests1;
		
		private EntitySet<USR_UserListAuthorization> _USR_UserListAuthorizations;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUsernameChanging(string value);
    partial void OnUsernameChanged();
    partial void OnPasswordChanging(string value);
    partial void OnPasswordChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    partial void OnEmailChanging(string value);
    partial void OnEmailChanged();
    partial void OnIsAdminChanging(System.Nullable<bool> value);
    partial void OnIsAdminChanged();
    #endregion
		
		public User()
		{
			this._MOV_M_UserRatings = new EntitySet<MOV_M_UserRating>(new Action<MOV_M_UserRating>(this.attach_MOV_M_UserRatings), new Action<MOV_M_UserRating>(this.detach_MOV_M_UserRatings));
			this._MOV_UserMovies = new EntitySet<MOV_UserMovie>(new Action<MOV_UserMovie>(this.attach_MOV_UserMovies), new Action<MOV_UserMovie>(this.detach_MOV_UserMovies));
			this._USR_Archives = new EntitySet<USR_Archive>(new Action<USR_Archive>(this.attach_USR_Archives), new Action<USR_Archive>(this.detach_USR_Archives));
			this._USR_Lists = new EntitySet<USR_List>(new Action<USR_List>(this.attach_USR_Lists), new Action<USR_List>(this.detach_USR_Lists));
			this._USR_Friends = new EntitySet<USR_Friend>(new Action<USR_Friend>(this.attach_USR_Friends), new Action<USR_Friend>(this.detach_USR_Friends));
			this._USR_Friends1 = new EntitySet<USR_Friend>(new Action<USR_Friend>(this.attach_USR_Friends1), new Action<USR_Friend>(this.detach_USR_Friends1));
			this._USR_FriendRequests = new EntitySet<USR_FriendRequest>(new Action<USR_FriendRequest>(this.attach_USR_FriendRequests), new Action<USR_FriendRequest>(this.detach_USR_FriendRequests));
			this._USR_FriendRequests1 = new EntitySet<USR_FriendRequest>(new Action<USR_FriendRequest>(this.attach_USR_FriendRequests1), new Action<USR_FriendRequest>(this.detach_USR_FriendRequests1));
			this._USR_UserListAuthorizations = new EntitySet<USR_UserListAuthorization>(new Action<USR_UserListAuthorization>(this.attach_USR_UserListAuthorizations), new Action<USR_UserListAuthorization>(this.detach_USR_UserListAuthorizations));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Username", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
		public string Username
		{
			get
			{
				return this._Username;
			}
			set
			{
				if ((this._Username != value))
				{
					this.OnUsernameChanging(value);
					this.SendPropertyChanging();
					this._Username = value;
					this.SendPropertyChanged("Username");
					this.OnUsernameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Password", DbType="NVarChar(100) NOT NULL", CanBeNull=false)]
		public string Password
		{
			get
			{
				return this._Password;
			}
			set
			{
				if ((this._Password != value))
				{
					this.OnPasswordChanging(value);
					this.SendPropertyChanging();
					this._Password = value;
					this.SendPropertyChanged("Password");
					this.OnPasswordChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100)")]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Email", DbType="NVarChar(250)")]
		public string Email
		{
			get
			{
				return this._Email;
			}
			set
			{
				if ((this._Email != value))
				{
					this.OnEmailChanging(value);
					this.SendPropertyChanging();
					this._Email = value;
					this.SendPropertyChanged("Email");
					this.OnEmailChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsAdmin", DbType="Bit")]
		public System.Nullable<bool> IsAdmin
		{
			get
			{
				return this._IsAdmin;
			}
			set
			{
				if ((this._IsAdmin != value))
				{
					this.OnIsAdminChanging(value);
					this.SendPropertyChanging();
					this._IsAdmin = value;
					this.SendPropertyChanged("IsAdmin");
					this.OnIsAdminChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_MOV_M_UserRating", Storage="_MOV_M_UserRatings", ThisKey="ID", OtherKey="UserID")]
		public EntitySet<MOV_M_UserRating> MOV_M_UserRatings
		{
			get
			{
				return this._MOV_M_UserRatings;
			}
			set
			{
				this._MOV_M_UserRatings.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_MOV_UserMovie", Storage="_MOV_UserMovies", ThisKey="ID", OtherKey="UserID")]
		public EntitySet<MOV_UserMovie> MOV_UserMovies
		{
			get
			{
				return this._MOV_UserMovies;
			}
			set
			{
				this._MOV_UserMovies.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_Archive", Storage="_USR_Archives", ThisKey="ID", OtherKey="UserID")]
		public EntitySet<USR_Archive> USR_Archives
		{
			get
			{
				return this._USR_Archives;
			}
			set
			{
				this._USR_Archives.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_List", Storage="_USR_Lists", ThisKey="ID", OtherKey="UserID")]
		public EntitySet<USR_List> USR_Lists
		{
			get
			{
				return this._USR_Lists;
			}
			set
			{
				this._USR_Lists.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_Friend", Storage="_USR_Friends", ThisKey="ID", OtherKey="UserID")]
		public EntitySet<USR_Friend> USR_Friends
		{
			get
			{
				return this._USR_Friends;
			}
			set
			{
				this._USR_Friends.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_Friend1", Storage="_USR_Friends1", ThisKey="ID", OtherKey="FriendUserID")]
		public EntitySet<USR_Friend> USR_Friends1
		{
			get
			{
				return this._USR_Friends1;
			}
			set
			{
				this._USR_Friends1.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_FriendRequest", Storage="_USR_FriendRequests", ThisKey="ID", OtherKey="RequestCreatorUserID")]
		public EntitySet<USR_FriendRequest> USR_FriendRequests
		{
			get
			{
				return this._USR_FriendRequests;
			}
			set
			{
				this._USR_FriendRequests.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_FriendRequest1", Storage="_USR_FriendRequests1", ThisKey="ID", OtherKey="RequestSentToUserID")]
		public EntitySet<USR_FriendRequest> USR_FriendRequests1
		{
			get
			{
				return this._USR_FriendRequests1;
			}
			set
			{
				this._USR_FriendRequests1.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_UserListAuthorization", Storage="_USR_UserListAuthorizations", ThisKey="ID", OtherKey="UserID")]
		public EntitySet<USR_UserListAuthorization> USR_UserListAuthorizations
		{
			get
			{
				return this._USR_UserListAuthorizations;
			}
			set
			{
				this._USR_UserListAuthorizations.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_UserRatings(MOV_M_UserRating entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_MOV_M_UserRatings(MOV_M_UserRating entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
		
		private void attach_MOV_UserMovies(MOV_UserMovie entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_MOV_UserMovies(MOV_UserMovie entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
		
		private void attach_USR_Archives(USR_Archive entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_USR_Archives(USR_Archive entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
		
		private void attach_USR_Lists(USR_List entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_USR_Lists(USR_List entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
		
		private void attach_USR_Friends(USR_Friend entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_USR_Friends(USR_Friend entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
		
		private void attach_USR_Friends1(USR_Friend entity)
		{
			this.SendPropertyChanging();
			entity.User1 = this;
		}
		
		private void detach_USR_Friends1(USR_Friend entity)
		{
			this.SendPropertyChanging();
			entity.User1 = null;
		}
		
		private void attach_USR_FriendRequests(USR_FriendRequest entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_USR_FriendRequests(USR_FriendRequest entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
		
		private void attach_USR_FriendRequests1(USR_FriendRequest entity)
		{
			this.SendPropertyChanging();
			entity.User1 = this;
		}
		
		private void detach_USR_FriendRequests1(USR_FriendRequest entity)
		{
			this.SendPropertyChanging();
			entity.User1 = null;
		}
		
		private void attach_USR_UserListAuthorizations(USR_UserListAuthorization entity)
		{
			this.SendPropertyChanging();
			entity.User = this;
		}
		
		private void detach_USR_UserListAuthorizations(USR_UserListAuthorization entity)
		{
			this.SendPropertyChanging();
			entity.User = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.INF_Director")]
	public partial class INF_Director : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<MOV_M_Director> _MOV_M_Directors;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public INF_Director()
		{
			this._MOV_M_Directors = new EntitySet<MOV_M_Director>(new Action<MOV_M_Director>(this.attach_MOV_M_Directors), new Action<MOV_M_Director>(this.detach_MOV_M_Directors));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100)")]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Director_MOV_M_Director", Storage="_MOV_M_Directors", ThisKey="ID", OtherKey="DirectorID")]
		public EntitySet<MOV_M_Director> MOV_M_Directors
		{
			get
			{
				return this._MOV_M_Directors;
			}
			set
			{
				this._MOV_M_Directors.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Directors(MOV_M_Director entity)
		{
			this.SendPropertyChanging();
			entity.INF_Director = this;
		}
		
		private void detach_MOV_M_Directors(MOV_M_Director entity)
		{
			this.SendPropertyChanging();
			entity.INF_Director = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.INF_Language")]
	public partial class INF_Language : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<MOV_M_Language> _MOV_M_Languages;
		
		private EntitySet<MOV_M_Name> _MOV_M_Names;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public INF_Language()
		{
			this._MOV_M_Languages = new EntitySet<MOV_M_Language>(new Action<MOV_M_Language>(this.attach_MOV_M_Languages), new Action<MOV_M_Language>(this.detach_MOV_M_Languages));
			this._MOV_M_Names = new EntitySet<MOV_M_Name>(new Action<MOV_M_Name>(this.attach_MOV_M_Names), new Action<MOV_M_Name>(this.detach_MOV_M_Names));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100)")]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Language_MOV_M_Language", Storage="_MOV_M_Languages", ThisKey="ID", OtherKey="LanguageID")]
		public EntitySet<MOV_M_Language> MOV_M_Languages
		{
			get
			{
				return this._MOV_M_Languages;
			}
			set
			{
				this._MOV_M_Languages.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Language_MOV_M_Name", Storage="_MOV_M_Names", ThisKey="ID", OtherKey="LanguageID")]
		public EntitySet<MOV_M_Name> MOV_M_Names
		{
			get
			{
				return this._MOV_M_Names;
			}
			set
			{
				this._MOV_M_Names.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Languages(MOV_M_Language entity)
		{
			this.SendPropertyChanging();
			entity.INF_Language = this;
		}
		
		private void detach_MOV_M_Languages(MOV_M_Language entity)
		{
			this.SendPropertyChanging();
			entity.INF_Language = null;
		}
		
		private void attach_MOV_M_Names(MOV_M_Name entity)
		{
			this.SendPropertyChanging();
			entity.INF_Language = this;
		}
		
		private void detach_MOV_M_Names(MOV_M_Name entity)
		{
			this.SendPropertyChanging();
			entity.INF_Language = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.INF_Type")]
	public partial class INF_Type : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<MOV_M_Type> _MOV_M_Types;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public INF_Type()
		{
			this._MOV_M_Types = new EntitySet<MOV_M_Type>(new Action<MOV_M_Type>(this.attach_MOV_M_Types), new Action<MOV_M_Type>(this.detach_MOV_M_Types));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100)")]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Type_MOV_M_Type", Storage="_MOV_M_Types", ThisKey="ID", OtherKey="TypeID")]
		public EntitySet<MOV_M_Type> MOV_M_Types
		{
			get
			{
				return this._MOV_M_Types;
			}
			set
			{
				this._MOV_M_Types.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Types(MOV_M_Type entity)
		{
			this.SendPropertyChanging();
			entity.INF_Type = this;
		}
		
		private void detach_MOV_M_Types(MOV_M_Type entity)
		{
			this.SendPropertyChanging();
			entity.INF_Type = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.INF_Writer")]
	public partial class INF_Writer : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<MOV_M_Writer> _MOV_M_Writers;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public INF_Writer()
		{
			this._MOV_M_Writers = new EntitySet<MOV_M_Writer>(new Action<MOV_M_Writer>(this.attach_MOV_M_Writers), new Action<MOV_M_Writer>(this.detach_MOV_M_Writers));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100)")]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Writer_MOV_M_Writer", Storage="_MOV_M_Writers", ThisKey="ID", OtherKey="WriterID")]
		public EntitySet<MOV_M_Writer> MOV_M_Writers
		{
			get
			{
				return this._MOV_M_Writers;
			}
			set
			{
				this._MOV_M_Writers.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Writers(MOV_M_Writer entity)
		{
			this.SendPropertyChanging();
			entity.INF_Writer = this;
		}
		
		private void detach_MOV_M_Writers(MOV_M_Writer entity)
		{
			this.SendPropertyChanging();
			entity.INF_Writer = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Actor")]
	public partial class MOV_M_Actor : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _ActorID;
		
		private EntityRef<INF_Actor> _INF_Actor;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnActorIDChanging(int value);
    partial void OnActorIDChanged();
    #endregion
		
		public MOV_M_Actor()
		{
			this._INF_Actor = default(EntityRef<INF_Actor>);
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ActorID", DbType="Int NOT NULL")]
		public int ActorID
		{
			get
			{
				return this._ActorID;
			}
			set
			{
				if ((this._ActorID != value))
				{
					if (this._INF_Actor.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnActorIDChanging(value);
					this.SendPropertyChanging();
					this._ActorID = value;
					this.SendPropertyChanged("ActorID");
					this.OnActorIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Actor_MOV_M_Actor", Storage="_INF_Actor", ThisKey="ActorID", OtherKey="ID", IsForeignKey=true)]
		public INF_Actor INF_Actor
		{
			get
			{
				return this._INF_Actor.Entity;
			}
			set
			{
				INF_Actor previousValue = this._INF_Actor.Entity;
				if (((previousValue != value) 
							|| (this._INF_Actor.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._INF_Actor.Entity = null;
						previousValue.MOV_M_Actors.Remove(this);
					}
					this._INF_Actor.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Actors.Add(this);
						this._ActorID = value.ID;
					}
					else
					{
						this._ActorID = default(int);
					}
					this.SendPropertyChanged("INF_Actor");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Actor", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Actors.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Actors.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Archive")]
	public partial class MOV_M_Archive : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _ArchiveID;
		
		private string _Resolution;
		
		private string _FileExtension;
		
		private string _Path;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
		private EntityRef<USR_Archive> _USR_Archive;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnArchiveIDChanging(int value);
    partial void OnArchiveIDChanged();
    partial void OnResolutionChanging(string value);
    partial void OnResolutionChanged();
    partial void OnFileExtensionChanging(string value);
    partial void OnFileExtensionChanged();
    partial void OnPathChanging(string value);
    partial void OnPathChanged();
    #endregion
		
		public MOV_M_Archive()
		{
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			this._USR_Archive = default(EntityRef<USR_Archive>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ArchiveID", DbType="Int NOT NULL")]
		public int ArchiveID
		{
			get
			{
				return this._ArchiveID;
			}
			set
			{
				if ((this._ArchiveID != value))
				{
					if (this._USR_Archive.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnArchiveIDChanging(value);
					this.SendPropertyChanging();
					this._ArchiveID = value;
					this.SendPropertyChanged("ArchiveID");
					this.OnArchiveIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Resolution", DbType="NVarChar(30)")]
		public string Resolution
		{
			get
			{
				return this._Resolution;
			}
			set
			{
				if ((this._Resolution != value))
				{
					this.OnResolutionChanging(value);
					this.SendPropertyChanging();
					this._Resolution = value;
					this.SendPropertyChanged("Resolution");
					this.OnResolutionChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FileExtension", DbType="NVarChar(10)")]
		public string FileExtension
		{
			get
			{
				return this._FileExtension;
			}
			set
			{
				if ((this._FileExtension != value))
				{
					this.OnFileExtensionChanging(value);
					this.SendPropertyChanging();
					this._FileExtension = value;
					this.SendPropertyChanged("FileExtension");
					this.OnFileExtensionChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Path", DbType="NVarChar(1000)")]
		public string Path
		{
			get
			{
				return this._Path;
			}
			set
			{
				if ((this._Path != value))
				{
					this.OnPathChanging(value);
					this.SendPropertyChanging();
					this._Path = value;
					this.SendPropertyChanged("Path");
					this.OnPathChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Archive", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Archives.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Archives.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_Archive_MOV_M_Archive", Storage="_USR_Archive", ThisKey="ArchiveID", OtherKey="ID", IsForeignKey=true)]
		public USR_Archive USR_Archive
		{
			get
			{
				return this._USR_Archive.Entity;
			}
			set
			{
				USR_Archive previousValue = this._USR_Archive.Entity;
				if (((previousValue != value) 
							|| (this._USR_Archive.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._USR_Archive.Entity = null;
						previousValue.MOV_M_Archives.Remove(this);
					}
					this._USR_Archive.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Archives.Add(this);
						this._ArchiveID = value.ID;
					}
					else
					{
						this._ArchiveID = default(int);
					}
					this.SendPropertyChanged("USR_Archive");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Director")]
	public partial class MOV_M_Director : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _DirectorID;
		
		private EntityRef<INF_Director> _INF_Director;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnDirectorIDChanging(int value);
    partial void OnDirectorIDChanged();
    #endregion
		
		public MOV_M_Director()
		{
			this._INF_Director = default(EntityRef<INF_Director>);
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DirectorID", DbType="Int NOT NULL")]
		public int DirectorID
		{
			get
			{
				return this._DirectorID;
			}
			set
			{
				if ((this._DirectorID != value))
				{
					if (this._INF_Director.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnDirectorIDChanging(value);
					this.SendPropertyChanging();
					this._DirectorID = value;
					this.SendPropertyChanged("DirectorID");
					this.OnDirectorIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Director_MOV_M_Director", Storage="_INF_Director", ThisKey="DirectorID", OtherKey="ID", IsForeignKey=true)]
		public INF_Director INF_Director
		{
			get
			{
				return this._INF_Director.Entity;
			}
			set
			{
				INF_Director previousValue = this._INF_Director.Entity;
				if (((previousValue != value) 
							|| (this._INF_Director.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._INF_Director.Entity = null;
						previousValue.MOV_M_Directors.Remove(this);
					}
					this._INF_Director.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Directors.Add(this);
						this._DirectorID = value.ID;
					}
					else
					{
						this._DirectorID = default(int);
					}
					this.SendPropertyChanged("INF_Director");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Director", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Directors.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Directors.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Language")]
	public partial class MOV_M_Language : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _LanguageID;
		
		private EntityRef<INF_Language> _INF_Language;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnLanguageIDChanging(int value);
    partial void OnLanguageIDChanged();
    #endregion
		
		public MOV_M_Language()
		{
			this._INF_Language = default(EntityRef<INF_Language>);
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LanguageID", DbType="Int NOT NULL")]
		public int LanguageID
		{
			get
			{
				return this._LanguageID;
			}
			set
			{
				if ((this._LanguageID != value))
				{
					if (this._INF_Language.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnLanguageIDChanging(value);
					this.SendPropertyChanging();
					this._LanguageID = value;
					this.SendPropertyChanged("LanguageID");
					this.OnLanguageIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Language_MOV_M_Language", Storage="_INF_Language", ThisKey="LanguageID", OtherKey="ID", IsForeignKey=true)]
		public INF_Language INF_Language
		{
			get
			{
				return this._INF_Language.Entity;
			}
			set
			{
				INF_Language previousValue = this._INF_Language.Entity;
				if (((previousValue != value) 
							|| (this._INF_Language.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._INF_Language.Entity = null;
						previousValue.MOV_M_Languages.Remove(this);
					}
					this._INF_Language.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Languages.Add(this);
						this._LanguageID = value.ID;
					}
					else
					{
						this._LanguageID = default(int);
					}
					this.SendPropertyChanged("INF_Language");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Language", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Languages.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Languages.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Movie")]
	public partial class MOV_M_Movie : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private System.Nullable<int> _Year;
		
		private string _ImdbID;
		
		private System.Nullable<double> _ImdbRating;
		
		private string _ImdbPoster;
		
		private bool _ImdbParsed;
		
		private System.Nullable<System.DateTime> _ImdbLastParseDate;
		
		private System.DateTime _InsertDate;
		
		private int _InsertUserID;
		
		private System.DateTime _UpdateDate;
		
		private int _UpdateUserID;
		
		private EntitySet<MOV_M_Actor> _MOV_M_Actors;
		
		private EntitySet<MOV_M_Archive> _MOV_M_Archives;
		
		private EntitySet<MOV_M_Director> _MOV_M_Directors;
		
		private EntitySet<MOV_M_Language> _MOV_M_Languages;
		
		private EntitySet<MOV_M_Name> _MOV_M_Names;
		
		private EntitySet<MOV_M_Type> _MOV_M_Types;
		
		private EntitySet<MOV_M_UserRating> _MOV_M_UserRatings;
		
		private EntitySet<MOV_M_Writer> _MOV_M_Writers;
		
		private EntitySet<MOV_UserMovie> _MOV_UserMovies;
		
		private EntitySet<USR_ListMovie> _USR_ListMovies;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnYearChanging(System.Nullable<int> value);
    partial void OnYearChanged();
    partial void OnImdbIDChanging(string value);
    partial void OnImdbIDChanged();
    partial void OnImdbRatingChanging(System.Nullable<double> value);
    partial void OnImdbRatingChanged();
    partial void OnImdbPosterChanging(string value);
    partial void OnImdbPosterChanged();
    partial void OnImdbParsedChanging(bool value);
    partial void OnImdbParsedChanged();
    partial void OnImdbLastParseDateChanging(System.Nullable<System.DateTime> value);
    partial void OnImdbLastParseDateChanged();
    partial void OnInsertDateChanging(System.DateTime value);
    partial void OnInsertDateChanged();
    partial void OnInsertUserIDChanging(int value);
    partial void OnInsertUserIDChanged();
    partial void OnUpdateDateChanging(System.DateTime value);
    partial void OnUpdateDateChanged();
    partial void OnUpdateUserIDChanging(int value);
    partial void OnUpdateUserIDChanged();
    #endregion
		
		public MOV_M_Movie()
		{
			this._MOV_M_Actors = new EntitySet<MOV_M_Actor>(new Action<MOV_M_Actor>(this.attach_MOV_M_Actors), new Action<MOV_M_Actor>(this.detach_MOV_M_Actors));
			this._MOV_M_Archives = new EntitySet<MOV_M_Archive>(new Action<MOV_M_Archive>(this.attach_MOV_M_Archives), new Action<MOV_M_Archive>(this.detach_MOV_M_Archives));
			this._MOV_M_Directors = new EntitySet<MOV_M_Director>(new Action<MOV_M_Director>(this.attach_MOV_M_Directors), new Action<MOV_M_Director>(this.detach_MOV_M_Directors));
			this._MOV_M_Languages = new EntitySet<MOV_M_Language>(new Action<MOV_M_Language>(this.attach_MOV_M_Languages), new Action<MOV_M_Language>(this.detach_MOV_M_Languages));
			this._MOV_M_Names = new EntitySet<MOV_M_Name>(new Action<MOV_M_Name>(this.attach_MOV_M_Names), new Action<MOV_M_Name>(this.detach_MOV_M_Names));
			this._MOV_M_Types = new EntitySet<MOV_M_Type>(new Action<MOV_M_Type>(this.attach_MOV_M_Types), new Action<MOV_M_Type>(this.detach_MOV_M_Types));
			this._MOV_M_UserRatings = new EntitySet<MOV_M_UserRating>(new Action<MOV_M_UserRating>(this.attach_MOV_M_UserRatings), new Action<MOV_M_UserRating>(this.detach_MOV_M_UserRatings));
			this._MOV_M_Writers = new EntitySet<MOV_M_Writer>(new Action<MOV_M_Writer>(this.attach_MOV_M_Writers), new Action<MOV_M_Writer>(this.detach_MOV_M_Writers));
			this._MOV_UserMovies = new EntitySet<MOV_UserMovie>(new Action<MOV_UserMovie>(this.attach_MOV_UserMovies), new Action<MOV_UserMovie>(this.detach_MOV_UserMovies));
			this._USR_ListMovies = new EntitySet<USR_ListMovie>(new Action<USR_ListMovie>(this.attach_USR_ListMovies), new Action<USR_ListMovie>(this.detach_USR_ListMovies));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Year", DbType="Int")]
		public System.Nullable<int> Year
		{
			get
			{
				return this._Year;
			}
			set
			{
				if ((this._Year != value))
				{
					this.OnYearChanging(value);
					this.SendPropertyChanging();
					this._Year = value;
					this.SendPropertyChanged("Year");
					this.OnYearChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbID", DbType="NVarChar(30)")]
		public string ImdbID
		{
			get
			{
				return this._ImdbID;
			}
			set
			{
				if ((this._ImdbID != value))
				{
					this.OnImdbIDChanging(value);
					this.SendPropertyChanging();
					this._ImdbID = value;
					this.SendPropertyChanged("ImdbID");
					this.OnImdbIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbRating", DbType="Float")]
		public System.Nullable<double> ImdbRating
		{
			get
			{
				return this._ImdbRating;
			}
			set
			{
				if ((this._ImdbRating != value))
				{
					this.OnImdbRatingChanging(value);
					this.SendPropertyChanging();
					this._ImdbRating = value;
					this.SendPropertyChanged("ImdbRating");
					this.OnImdbRatingChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbPoster", DbType="NVarChar(500)")]
		public string ImdbPoster
		{
			get
			{
				return this._ImdbPoster;
			}
			set
			{
				if ((this._ImdbPoster != value))
				{
					this.OnImdbPosterChanging(value);
					this.SendPropertyChanging();
					this._ImdbPoster = value;
					this.SendPropertyChanged("ImdbPoster");
					this.OnImdbPosterChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbParsed", DbType="Bit NOT NULL")]
		public bool ImdbParsed
		{
			get
			{
				return this._ImdbParsed;
			}
			set
			{
				if ((this._ImdbParsed != value))
				{
					this.OnImdbParsedChanging(value);
					this.SendPropertyChanging();
					this._ImdbParsed = value;
					this.SendPropertyChanged("ImdbParsed");
					this.OnImdbParsedChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbLastParseDate", DbType="DateTime")]
		public System.Nullable<System.DateTime> ImdbLastParseDate
		{
			get
			{
				return this._ImdbLastParseDate;
			}
			set
			{
				if ((this._ImdbLastParseDate != value))
				{
					this.OnImdbLastParseDateChanging(value);
					this.SendPropertyChanging();
					this._ImdbLastParseDate = value;
					this.SendPropertyChanged("ImdbLastParseDate");
					this.OnImdbLastParseDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertDate", DbType="DateTime NOT NULL")]
		public System.DateTime InsertDate
		{
			get
			{
				return this._InsertDate;
			}
			set
			{
				if ((this._InsertDate != value))
				{
					this.OnInsertDateChanging(value);
					this.SendPropertyChanging();
					this._InsertDate = value;
					this.SendPropertyChanged("InsertDate");
					this.OnInsertDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertUserID", DbType="Int NOT NULL")]
		public int InsertUserID
		{
			get
			{
				return this._InsertUserID;
			}
			set
			{
				if ((this._InsertUserID != value))
				{
					this.OnInsertUserIDChanging(value);
					this.SendPropertyChanging();
					this._InsertUserID = value;
					this.SendPropertyChanged("InsertUserID");
					this.OnInsertUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UpdateDate", DbType="DateTime NOT NULL")]
		public System.DateTime UpdateDate
		{
			get
			{
				return this._UpdateDate;
			}
			set
			{
				if ((this._UpdateDate != value))
				{
					this.OnUpdateDateChanging(value);
					this.SendPropertyChanging();
					this._UpdateDate = value;
					this.SendPropertyChanged("UpdateDate");
					this.OnUpdateDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UpdateUserID", DbType="Int NOT NULL")]
		public int UpdateUserID
		{
			get
			{
				return this._UpdateUserID;
			}
			set
			{
				if ((this._UpdateUserID != value))
				{
					this.OnUpdateUserIDChanging(value);
					this.SendPropertyChanging();
					this._UpdateUserID = value;
					this.SendPropertyChanged("UpdateUserID");
					this.OnUpdateUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Actor", Storage="_MOV_M_Actors", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Actor> MOV_M_Actors
		{
			get
			{
				return this._MOV_M_Actors;
			}
			set
			{
				this._MOV_M_Actors.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Archive", Storage="_MOV_M_Archives", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Archive> MOV_M_Archives
		{
			get
			{
				return this._MOV_M_Archives;
			}
			set
			{
				this._MOV_M_Archives.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Director", Storage="_MOV_M_Directors", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Director> MOV_M_Directors
		{
			get
			{
				return this._MOV_M_Directors;
			}
			set
			{
				this._MOV_M_Directors.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Language", Storage="_MOV_M_Languages", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Language> MOV_M_Languages
		{
			get
			{
				return this._MOV_M_Languages;
			}
			set
			{
				this._MOV_M_Languages.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Name", Storage="_MOV_M_Names", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Name> MOV_M_Names
		{
			get
			{
				return this._MOV_M_Names;
			}
			set
			{
				this._MOV_M_Names.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Type", Storage="_MOV_M_Types", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Type> MOV_M_Types
		{
			get
			{
				return this._MOV_M_Types;
			}
			set
			{
				this._MOV_M_Types.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_UserRating", Storage="_MOV_M_UserRatings", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_UserRating> MOV_M_UserRatings
		{
			get
			{
				return this._MOV_M_UserRatings;
			}
			set
			{
				this._MOV_M_UserRatings.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Writer", Storage="_MOV_M_Writers", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_M_Writer> MOV_M_Writers
		{
			get
			{
				return this._MOV_M_Writers;
			}
			set
			{
				this._MOV_M_Writers.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_UserMovie", Storage="_MOV_UserMovies", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<MOV_UserMovie> MOV_UserMovies
		{
			get
			{
				return this._MOV_UserMovies;
			}
			set
			{
				this._MOV_UserMovies.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_USR_ListMovie", Storage="_USR_ListMovies", ThisKey="ID", OtherKey="MovieID")]
		public EntitySet<USR_ListMovie> USR_ListMovies
		{
			get
			{
				return this._USR_ListMovies;
			}
			set
			{
				this._USR_ListMovies.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Actors(MOV_M_Actor entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Actors(MOV_M_Actor entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_Archives(MOV_M_Archive entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Archives(MOV_M_Archive entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_Directors(MOV_M_Director entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Directors(MOV_M_Director entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_Languages(MOV_M_Language entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Languages(MOV_M_Language entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_Names(MOV_M_Name entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Names(MOV_M_Name entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_Types(MOV_M_Type entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Types(MOV_M_Type entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_UserRatings(MOV_M_UserRating entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_UserRatings(MOV_M_UserRating entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_M_Writers(MOV_M_Writer entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_M_Writers(MOV_M_Writer entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_MOV_UserMovies(MOV_UserMovie entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_MOV_UserMovies(MOV_UserMovie entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
		
		private void attach_USR_ListMovies(USR_ListMovie entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = this;
		}
		
		private void detach_USR_ListMovies(USR_ListMovie entity)
		{
			this.SendPropertyChanging();
			entity.MOV_M_Movie = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Names")]
	public partial class MOV_M_Name : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _LanguageID;
		
		private string _Name;
		
		private bool _IsDefault;
		
		private EntityRef<INF_Language> _INF_Language;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnLanguageIDChanging(int value);
    partial void OnLanguageIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    partial void OnIsDefaultChanging(bool value);
    partial void OnIsDefaultChanged();
    #endregion
		
		public MOV_M_Name()
		{
			this._INF_Language = default(EntityRef<INF_Language>);
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LanguageID", DbType="Int NOT NULL")]
		public int LanguageID
		{
			get
			{
				return this._LanguageID;
			}
			set
			{
				if ((this._LanguageID != value))
				{
					if (this._INF_Language.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnLanguageIDChanging(value);
					this.SendPropertyChanging();
					this._LanguageID = value;
					this.SendPropertyChanged("LanguageID");
					this.OnLanguageIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(250) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsDefault", DbType="Bit NOT NULL")]
		public bool IsDefault
		{
			get
			{
				return this._IsDefault;
			}
			set
			{
				if ((this._IsDefault != value))
				{
					this.OnIsDefaultChanging(value);
					this.SendPropertyChanging();
					this._IsDefault = value;
					this.SendPropertyChanged("IsDefault");
					this.OnIsDefaultChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Language_MOV_M_Name", Storage="_INF_Language", ThisKey="LanguageID", OtherKey="ID", IsForeignKey=true)]
		public INF_Language INF_Language
		{
			get
			{
				return this._INF_Language.Entity;
			}
			set
			{
				INF_Language previousValue = this._INF_Language.Entity;
				if (((previousValue != value) 
							|| (this._INF_Language.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._INF_Language.Entity = null;
						previousValue.MOV_M_Names.Remove(this);
					}
					this._INF_Language.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Names.Add(this);
						this._LanguageID = value.ID;
					}
					else
					{
						this._LanguageID = default(int);
					}
					this.SendPropertyChanged("INF_Language");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Name", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Names.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Names.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Types")]
	public partial class MOV_M_Type : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _TypeID;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
		private EntityRef<INF_Type> _INF_Type;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnTypeIDChanging(int value);
    partial void OnTypeIDChanged();
    #endregion
		
		public MOV_M_Type()
		{
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			this._INF_Type = default(EntityRef<INF_Type>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TypeID", DbType="Int NOT NULL")]
		public int TypeID
		{
			get
			{
				return this._TypeID;
			}
			set
			{
				if ((this._TypeID != value))
				{
					if (this._INF_Type.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnTypeIDChanging(value);
					this.SendPropertyChanging();
					this._TypeID = value;
					this.SendPropertyChanged("TypeID");
					this.OnTypeIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Type", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Types.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Types.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Type_MOV_M_Type", Storage="_INF_Type", ThisKey="TypeID", OtherKey="ID", IsForeignKey=true)]
		public INF_Type INF_Type
		{
			get
			{
				return this._INF_Type.Entity;
			}
			set
			{
				INF_Type previousValue = this._INF_Type.Entity;
				if (((previousValue != value) 
							|| (this._INF_Type.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._INF_Type.Entity = null;
						previousValue.MOV_M_Types.Remove(this);
					}
					this._INF_Type.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Types.Add(this);
						this._TypeID = value.ID;
					}
					else
					{
						this._TypeID = default(int);
					}
					this.SendPropertyChanged("INF_Type");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_UserRating")]
	public partial class MOV_M_UserRating : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _UserID;
		
		private int _MovieID;
		
		private bool _Watched;
		
		private System.Nullable<int> _Rating;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
		private EntityRef<User> _User;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUserIDChanging(int value);
    partial void OnUserIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnWatchedChanging(bool value);
    partial void OnWatchedChanged();
    partial void OnRatingChanging(System.Nullable<int> value);
    partial void OnRatingChanged();
    #endregion
		
		public MOV_M_UserRating()
		{
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			this._User = default(EntityRef<User>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserIDChanging(value);
					this.SendPropertyChanging();
					this._UserID = value;
					this.SendPropertyChanged("UserID");
					this.OnUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Watched", DbType="Bit NOT NULL")]
		public bool Watched
		{
			get
			{
				return this._Watched;
			}
			set
			{
				if ((this._Watched != value))
				{
					this.OnWatchedChanging(value);
					this.SendPropertyChanging();
					this._Watched = value;
					this.SendPropertyChanged("Watched");
					this.OnWatchedChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Rating", DbType="Int")]
		public System.Nullable<int> Rating
		{
			get
			{
				return this._Rating;
			}
			set
			{
				if ((this._Rating != value))
				{
					this.OnRatingChanging(value);
					this.SendPropertyChanging();
					this._Rating = value;
					this.SendPropertyChanged("Rating");
					this.OnRatingChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_UserRating", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_UserRatings.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_UserRatings.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_MOV_M_UserRating", Storage="_User", ThisKey="UserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.MOV_M_UserRatings.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.MOV_M_UserRatings.Add(this);
						this._UserID = value.ID;
					}
					else
					{
						this._UserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_M_Writer")]
	public partial class MOV_M_Writer : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _MovieID;
		
		private int _WriterID;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
		private EntityRef<INF_Writer> _INF_Writer;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnWriterIDChanging(int value);
    partial void OnWriterIDChanged();
    #endregion
		
		public MOV_M_Writer()
		{
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			this._INF_Writer = default(EntityRef<INF_Writer>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WriterID", DbType="Int NOT NULL")]
		public int WriterID
		{
			get
			{
				return this._WriterID;
			}
			set
			{
				if ((this._WriterID != value))
				{
					if (this._INF_Writer.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnWriterIDChanging(value);
					this.SendPropertyChanging();
					this._WriterID = value;
					this.SendPropertyChanged("WriterID");
					this.OnWriterIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_M_Writer", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_M_Writers.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Writers.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="INF_Writer_MOV_M_Writer", Storage="_INF_Writer", ThisKey="WriterID", OtherKey="ID", IsForeignKey=true)]
		public INF_Writer INF_Writer
		{
			get
			{
				return this._INF_Writer.Entity;
			}
			set
			{
				INF_Writer previousValue = this._INF_Writer.Entity;
				if (((previousValue != value) 
							|| (this._INF_Writer.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._INF_Writer.Entity = null;
						previousValue.MOV_M_Writers.Remove(this);
					}
					this._INF_Writer.Entity = value;
					if ((value != null))
					{
						value.MOV_M_Writers.Add(this);
						this._WriterID = value.ID;
					}
					else
					{
						this._WriterID = default(int);
					}
					this.SendPropertyChanged("INF_Writer");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MOV_UserMovie")]
	public partial class MOV_UserMovie : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _UserID;
		
		private int _MovieID;
		
		private System.DateTime _InsertDate;
		
		private int _InsertUserID;
		
		private System.DateTime _UpdateDate;
		
		private int _UpdateUserID;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
		private EntityRef<User> _User;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUserIDChanging(int value);
    partial void OnUserIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnInsertDateChanging(System.DateTime value);
    partial void OnInsertDateChanged();
    partial void OnInsertUserIDChanging(int value);
    partial void OnInsertUserIDChanged();
    partial void OnUpdateDateChanging(System.DateTime value);
    partial void OnUpdateDateChanged();
    partial void OnUpdateUserIDChanging(int value);
    partial void OnUpdateUserIDChanged();
    #endregion
		
		public MOV_UserMovie()
		{
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			this._User = default(EntityRef<User>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserIDChanging(value);
					this.SendPropertyChanging();
					this._UserID = value;
					this.SendPropertyChanged("UserID");
					this.OnUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertDate", DbType="DateTime NOT NULL")]
		public System.DateTime InsertDate
		{
			get
			{
				return this._InsertDate;
			}
			set
			{
				if ((this._InsertDate != value))
				{
					this.OnInsertDateChanging(value);
					this.SendPropertyChanging();
					this._InsertDate = value;
					this.SendPropertyChanged("InsertDate");
					this.OnInsertDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertUserID", DbType="Int NOT NULL")]
		public int InsertUserID
		{
			get
			{
				return this._InsertUserID;
			}
			set
			{
				if ((this._InsertUserID != value))
				{
					this.OnInsertUserIDChanging(value);
					this.SendPropertyChanging();
					this._InsertUserID = value;
					this.SendPropertyChanged("InsertUserID");
					this.OnInsertUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UpdateDate", DbType="DateTime NOT NULL")]
		public System.DateTime UpdateDate
		{
			get
			{
				return this._UpdateDate;
			}
			set
			{
				if ((this._UpdateDate != value))
				{
					this.OnUpdateDateChanging(value);
					this.SendPropertyChanging();
					this._UpdateDate = value;
					this.SendPropertyChanged("UpdateDate");
					this.OnUpdateDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UpdateUserID", DbType="Int NOT NULL")]
		public int UpdateUserID
		{
			get
			{
				return this._UpdateUserID;
			}
			set
			{
				if ((this._UpdateUserID != value))
				{
					this.OnUpdateUserIDChanging(value);
					this.SendPropertyChanging();
					this._UpdateUserID = value;
					this.SendPropertyChanged("UpdateUserID");
					this.OnUpdateUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_MOV_UserMovie", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.MOV_UserMovies.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.MOV_UserMovies.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_MOV_UserMovie", Storage="_User", ThisKey="UserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.MOV_UserMovies.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.MOV_UserMovies.Add(this);
						this._UserID = value.ID;
					}
					else
					{
						this._UserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.MoviesNotInHardDisk")]
	public partial class MoviesNotInHardDisk
	{
		
		private string _Name;
		
		private int _ID;
		
		private System.Nullable<int> _Year;
		
		private string _ImdbID;
		
		private System.Nullable<double> _ImdbRating;
		
		private string _ImdbPoster;
		
		private bool _ImdbParsed;
		
		private System.Nullable<System.DateTime> _ImdbLastParseDate;
		
		private System.DateTime _InsertDate;
		
		private int _InsertUserID;
		
		private System.DateTime _UpdateDate;
		
		private int _UpdateUserID;
		
		public MoviesNotInHardDisk()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(250) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this._Name = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Year", DbType="Int")]
		public System.Nullable<int> Year
		{
			get
			{
				return this._Year;
			}
			set
			{
				if ((this._Year != value))
				{
					this._Year = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbID", DbType="NVarChar(30)")]
		public string ImdbID
		{
			get
			{
				return this._ImdbID;
			}
			set
			{
				if ((this._ImdbID != value))
				{
					this._ImdbID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbRating", DbType="Float")]
		public System.Nullable<double> ImdbRating
		{
			get
			{
				return this._ImdbRating;
			}
			set
			{
				if ((this._ImdbRating != value))
				{
					this._ImdbRating = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbPoster", DbType="NVarChar(500)")]
		public string ImdbPoster
		{
			get
			{
				return this._ImdbPoster;
			}
			set
			{
				if ((this._ImdbPoster != value))
				{
					this._ImdbPoster = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbParsed", DbType="Bit NOT NULL")]
		public bool ImdbParsed
		{
			get
			{
				return this._ImdbParsed;
			}
			set
			{
				if ((this._ImdbParsed != value))
				{
					this._ImdbParsed = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ImdbLastParseDate", DbType="DateTime")]
		public System.Nullable<System.DateTime> ImdbLastParseDate
		{
			get
			{
				return this._ImdbLastParseDate;
			}
			set
			{
				if ((this._ImdbLastParseDate != value))
				{
					this._ImdbLastParseDate = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertDate", DbType="DateTime NOT NULL")]
		public System.DateTime InsertDate
		{
			get
			{
				return this._InsertDate;
			}
			set
			{
				if ((this._InsertDate != value))
				{
					this._InsertDate = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertUserID", DbType="Int NOT NULL")]
		public int InsertUserID
		{
			get
			{
				return this._InsertUserID;
			}
			set
			{
				if ((this._InsertUserID != value))
				{
					this._InsertUserID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UpdateDate", DbType="DateTime NOT NULL")]
		public System.DateTime UpdateDate
		{
			get
			{
				return this._UpdateDate;
			}
			set
			{
				if ((this._UpdateDate != value))
				{
					this._UpdateDate = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UpdateUserID", DbType="Int NOT NULL")]
		public int UpdateUserID
		{
			get
			{
				return this._UpdateUserID;
			}
			set
			{
				if ((this._UpdateUserID != value))
				{
					this._UpdateUserID = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vUserListMoviesDetail")]
	public partial class vUserListMoviesDetail
	{
		
		private int _UserID;
		
		private int _ListID;
		
		private string _ListName;
		
		private System.Nullable<int> _ListMovieID;
		
		private System.Nullable<int> _MovieID;
		
		private string _MovieName;
		
		private System.Nullable<int> _SortOrder;
		
		private System.Nullable<bool> _IsChecked;
		
		private System.Nullable<bool> _Watched;
		
		public vUserListMoviesDetail()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					this._UserID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ListID", DbType="Int NOT NULL")]
		public int ListID
		{
			get
			{
				return this._ListID;
			}
			set
			{
				if ((this._ListID != value))
				{
					this._ListID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ListName", DbType="NVarChar(250) NOT NULL", CanBeNull=false)]
		public string ListName
		{
			get
			{
				return this._ListName;
			}
			set
			{
				if ((this._ListName != value))
				{
					this._ListName = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ListMovieID", DbType="Int")]
		public System.Nullable<int> ListMovieID
		{
			get
			{
				return this._ListMovieID;
			}
			set
			{
				if ((this._ListMovieID != value))
				{
					this._ListMovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int")]
		public System.Nullable<int> MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieName", DbType="NVarChar(250)")]
		public string MovieName
		{
			get
			{
				return this._MovieName;
			}
			set
			{
				if ((this._MovieName != value))
				{
					this._MovieName = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SortOrder", DbType="Int")]
		public System.Nullable<int> SortOrder
		{
			get
			{
				return this._SortOrder;
			}
			set
			{
				if ((this._SortOrder != value))
				{
					this._SortOrder = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsChecked", DbType="Bit")]
		public System.Nullable<bool> IsChecked
		{
			get
			{
				return this._IsChecked;
			}
			set
			{
				if ((this._IsChecked != value))
				{
					this._IsChecked = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Watched", DbType="Bit")]
		public System.Nullable<bool> Watched
		{
			get
			{
				return this._Watched;
			}
			set
			{
				if ((this._Watched != value))
				{
					this._Watched = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieActor")]
	public partial class vMovieActor
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _ActorID;
		
		private string _ActorName;
		
		public vMovieActor()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ActorID", DbType="Int NOT NULL")]
		public int ActorID
		{
			get
			{
				return this._ActorID;
			}
			set
			{
				if ((this._ActorID != value))
				{
					this._ActorID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ActorName", DbType="NVarChar(100)")]
		public string ActorName
		{
			get
			{
				return this._ActorName;
			}
			set
			{
				if ((this._ActorName != value))
				{
					this._ActorName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieDirector")]
	public partial class vMovieDirector
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _DirectorID;
		
		private string _DirectorName;
		
		public vMovieDirector()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DirectorID", DbType="Int NOT NULL")]
		public int DirectorID
		{
			get
			{
				return this._DirectorID;
			}
			set
			{
				if ((this._DirectorID != value))
				{
					this._DirectorID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_DirectorName", DbType="NVarChar(100)")]
		public string DirectorName
		{
			get
			{
				return this._DirectorName;
			}
			set
			{
				if ((this._DirectorName != value))
				{
					this._DirectorName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieLanguage")]
	public partial class vMovieLanguage
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _LanguageID;
		
		private string _LanguageName;
		
		public vMovieLanguage()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LanguageID", DbType="Int NOT NULL")]
		public int LanguageID
		{
			get
			{
				return this._LanguageID;
			}
			set
			{
				if ((this._LanguageID != value))
				{
					this._LanguageID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LanguageName", DbType="NVarChar(100)")]
		public string LanguageName
		{
			get
			{
				return this._LanguageName;
			}
			set
			{
				if ((this._LanguageName != value))
				{
					this._LanguageName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieName")]
	public partial class vMovieName
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _LanguageID;
		
		private string _Name;
		
		private bool _IsDefault;
		
		private string _LanguageName;
		
		public vMovieName()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LanguageID", DbType="Int NOT NULL")]
		public int LanguageID
		{
			get
			{
				return this._LanguageID;
			}
			set
			{
				if ((this._LanguageID != value))
				{
					this._LanguageID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(250) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this._Name = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsDefault", DbType="Bit NOT NULL")]
		public bool IsDefault
		{
			get
			{
				return this._IsDefault;
			}
			set
			{
				if ((this._IsDefault != value))
				{
					this._IsDefault = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_LanguageName", DbType="NVarChar(100)")]
		public string LanguageName
		{
			get
			{
				return this._LanguageName;
			}
			set
			{
				if ((this._LanguageName != value))
				{
					this._LanguageName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieType")]
	public partial class vMovieType
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _TypeID;
		
		private string _TypeName;
		
		public vMovieType()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TypeID", DbType="Int NOT NULL")]
		public int TypeID
		{
			get
			{
				return this._TypeID;
			}
			set
			{
				if ((this._TypeID != value))
				{
					this._TypeID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_TypeName", DbType="NVarChar(100)")]
		public string TypeName
		{
			get
			{
				return this._TypeName;
			}
			set
			{
				if ((this._TypeName != value))
				{
					this._TypeName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieUserRating")]
	public partial class vMovieUserRating
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _UserID;
		
		private bool _Watched;
		
		private System.Nullable<int> _Rating;
		
		private string _UserName;
		
		public vMovieUserRating()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					this._UserID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Watched", DbType="Bit NOT NULL")]
		public bool Watched
		{
			get
			{
				return this._Watched;
			}
			set
			{
				if ((this._Watched != value))
				{
					this._Watched = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Rating", DbType="Int")]
		public System.Nullable<int> Rating
		{
			get
			{
				return this._Rating;
			}
			set
			{
				if ((this._Rating != value))
				{
					this._Rating = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserName", DbType="NVarChar(100)")]
		public string UserName
		{
			get
			{
				return this._UserName;
			}
			set
			{
				if ((this._UserName != value))
				{
					this._UserName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieWriter")]
	public partial class vMovieWriter
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _WriterID;
		
		private string _WriterName;
		
		public vMovieWriter()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WriterID", DbType="Int NOT NULL")]
		public int WriterID
		{
			get
			{
				return this._WriterID;
			}
			set
			{
				if ((this._WriterID != value))
				{
					this._WriterID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WriterName", DbType="NVarChar(100)")]
		public string WriterName
		{
			get
			{
				return this._WriterName;
			}
			set
			{
				if ((this._WriterName != value))
				{
					this._WriterName = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_Archive")]
	public partial class USR_Archive : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _UserID;
		
		private string _Name;
		
		private string _Path;
		
		private EntitySet<MOV_M_Archive> _MOV_M_Archives;
		
		private EntityRef<User> _User;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUserIDChanging(int value);
    partial void OnUserIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    partial void OnPathChanging(string value);
    partial void OnPathChanged();
    #endregion
		
		public USR_Archive()
		{
			this._MOV_M_Archives = new EntitySet<MOV_M_Archive>(new Action<MOV_M_Archive>(this.attach_MOV_M_Archives), new Action<MOV_M_Archive>(this.detach_MOV_M_Archives));
			this._User = default(EntityRef<User>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserIDChanging(value);
					this.SendPropertyChanging();
					this._UserID = value;
					this.SendPropertyChanged("UserID");
					this.OnUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(100) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Path", DbType="NVarChar(100)")]
		public string Path
		{
			get
			{
				return this._Path;
			}
			set
			{
				if ((this._Path != value))
				{
					this.OnPathChanging(value);
					this.SendPropertyChanging();
					this._Path = value;
					this.SendPropertyChanged("Path");
					this.OnPathChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_Archive_MOV_M_Archive", Storage="_MOV_M_Archives", ThisKey="ID", OtherKey="ArchiveID")]
		public EntitySet<MOV_M_Archive> MOV_M_Archives
		{
			get
			{
				return this._MOV_M_Archives;
			}
			set
			{
				this._MOV_M_Archives.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_Archive", Storage="_User", ThisKey="UserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.USR_Archives.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.USR_Archives.Add(this);
						this._UserID = value.ID;
					}
					else
					{
						this._UserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_MOV_M_Archives(MOV_M_Archive entity)
		{
			this.SendPropertyChanging();
			entity.USR_Archive = this;
		}
		
		private void detach_MOV_M_Archives(MOV_M_Archive entity)
		{
			this.SendPropertyChanging();
			entity.USR_Archive = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_List")]
	public partial class USR_List : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _UserID;
		
		private string _Name;
		
		private EntitySet<USR_ListMovie> _USR_ListMovies;
		
		private EntitySet<USR_UserListAuthorization> _USR_UserListAuthorizations;
		
		private EntityRef<User> _User;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUserIDChanging(int value);
    partial void OnUserIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public USR_List()
		{
			this._USR_ListMovies = new EntitySet<USR_ListMovie>(new Action<USR_ListMovie>(this.attach_USR_ListMovies), new Action<USR_ListMovie>(this.detach_USR_ListMovies));
			this._USR_UserListAuthorizations = new EntitySet<USR_UserListAuthorization>(new Action<USR_UserListAuthorization>(this.attach_USR_UserListAuthorizations), new Action<USR_UserListAuthorization>(this.detach_USR_UserListAuthorizations));
			this._User = default(EntityRef<User>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserIDChanging(value);
					this.SendPropertyChanging();
					this._UserID = value;
					this.SendPropertyChanged("UserID");
					this.OnUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(250) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_List_USR_ListMovie", Storage="_USR_ListMovies", ThisKey="ID", OtherKey="ListID")]
		public EntitySet<USR_ListMovie> USR_ListMovies
		{
			get
			{
				return this._USR_ListMovies;
			}
			set
			{
				this._USR_ListMovies.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_List_USR_UserListAuthorization", Storage="_USR_UserListAuthorizations", ThisKey="ID", OtherKey="UserListID")]
		public EntitySet<USR_UserListAuthorization> USR_UserListAuthorizations
		{
			get
			{
				return this._USR_UserListAuthorizations;
			}
			set
			{
				this._USR_UserListAuthorizations.Assign(value);
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_List", Storage="_User", ThisKey="UserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.USR_Lists.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.USR_Lists.Add(this);
						this._UserID = value.ID;
					}
					else
					{
						this._UserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_USR_ListMovies(USR_ListMovie entity)
		{
			this.SendPropertyChanging();
			entity.USR_List = this;
		}
		
		private void detach_USR_ListMovies(USR_ListMovie entity)
		{
			this.SendPropertyChanging();
			entity.USR_List = null;
		}
		
		private void attach_USR_UserListAuthorizations(USR_UserListAuthorization entity)
		{
			this.SendPropertyChanging();
			entity.USR_List = this;
		}
		
		private void detach_USR_UserListAuthorizations(USR_UserListAuthorization entity)
		{
			this.SendPropertyChanging();
			entity.USR_List = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_ListMovie")]
	public partial class USR_ListMovie : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _ListID;
		
		private int _MovieID;
		
		private int _SortOrder;
		
		private bool _IsChecked;
		
		private EntityRef<MOV_M_Movie> _MOV_M_Movie;
		
		private EntityRef<USR_List> _USR_List;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnListIDChanging(int value);
    partial void OnListIDChanged();
    partial void OnMovieIDChanging(int value);
    partial void OnMovieIDChanged();
    partial void OnSortOrderChanging(int value);
    partial void OnSortOrderChanged();
    partial void OnIsCheckedChanging(bool value);
    partial void OnIsCheckedChanged();
    #endregion
		
		public USR_ListMovie()
		{
			this._MOV_M_Movie = default(EntityRef<MOV_M_Movie>);
			this._USR_List = default(EntityRef<USR_List>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ListID", DbType="Int NOT NULL")]
		public int ListID
		{
			get
			{
				return this._ListID;
			}
			set
			{
				if ((this._ListID != value))
				{
					if (this._USR_List.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnListIDChanging(value);
					this.SendPropertyChanging();
					this._ListID = value;
					this.SendPropertyChanged("ListID");
					this.OnListIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					if (this._MOV_M_Movie.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnMovieIDChanging(value);
					this.SendPropertyChanging();
					this._MovieID = value;
					this.SendPropertyChanged("MovieID");
					this.OnMovieIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SortOrder", DbType="Int NOT NULL")]
		public int SortOrder
		{
			get
			{
				return this._SortOrder;
			}
			set
			{
				if ((this._SortOrder != value))
				{
					this.OnSortOrderChanging(value);
					this.SendPropertyChanging();
					this._SortOrder = value;
					this.SendPropertyChanged("SortOrder");
					this.OnSortOrderChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsChecked", DbType="Bit NOT NULL")]
		public bool IsChecked
		{
			get
			{
				return this._IsChecked;
			}
			set
			{
				if ((this._IsChecked != value))
				{
					this.OnIsCheckedChanging(value);
					this.SendPropertyChanging();
					this._IsChecked = value;
					this.SendPropertyChanged("IsChecked");
					this.OnIsCheckedChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="MOV_M_Movie_USR_ListMovie", Storage="_MOV_M_Movie", ThisKey="MovieID", OtherKey="ID", IsForeignKey=true)]
		public MOV_M_Movie MOV_M_Movie
		{
			get
			{
				return this._MOV_M_Movie.Entity;
			}
			set
			{
				MOV_M_Movie previousValue = this._MOV_M_Movie.Entity;
				if (((previousValue != value) 
							|| (this._MOV_M_Movie.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._MOV_M_Movie.Entity = null;
						previousValue.USR_ListMovies.Remove(this);
					}
					this._MOV_M_Movie.Entity = value;
					if ((value != null))
					{
						value.USR_ListMovies.Add(this);
						this._MovieID = value.ID;
					}
					else
					{
						this._MovieID = default(int);
					}
					this.SendPropertyChanged("MOV_M_Movie");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_List_USR_ListMovie", Storage="_USR_List", ThisKey="ListID", OtherKey="ID", IsForeignKey=true)]
		public USR_List USR_List
		{
			get
			{
				return this._USR_List.Entity;
			}
			set
			{
				USR_List previousValue = this._USR_List.Entity;
				if (((previousValue != value) 
							|| (this._USR_List.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._USR_List.Entity = null;
						previousValue.USR_ListMovies.Remove(this);
					}
					this._USR_List.Entity = value;
					if ((value != null))
					{
						value.USR_ListMovies.Add(this);
						this._ListID = value.ID;
					}
					else
					{
						this._ListID = default(int);
					}
					this.SendPropertyChanged("USR_List");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.vMovieArchive")]
	public partial class vMovieArchive
	{
		
		private int _ID;
		
		private int _MovieID;
		
		private int _UserID;
		
		private int _ArchiveID;
		
		private string _Resolution;
		
		private string _FileExtension;
		
		private string _Path;
		
		private string _ArchiveName;
		
		private string _ArchivePath;
		
		public vMovieArchive()
		{
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this._ID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MovieID", DbType="Int NOT NULL")]
		public int MovieID
		{
			get
			{
				return this._MovieID;
			}
			set
			{
				if ((this._MovieID != value))
				{
					this._MovieID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					this._UserID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ArchiveID", DbType="Int NOT NULL")]
		public int ArchiveID
		{
			get
			{
				return this._ArchiveID;
			}
			set
			{
				if ((this._ArchiveID != value))
				{
					this._ArchiveID = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Resolution", DbType="NVarChar(30)")]
		public string Resolution
		{
			get
			{
				return this._Resolution;
			}
			set
			{
				if ((this._Resolution != value))
				{
					this._Resolution = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FileExtension", DbType="NVarChar(10)")]
		public string FileExtension
		{
			get
			{
				return this._FileExtension;
			}
			set
			{
				if ((this._FileExtension != value))
				{
					this._FileExtension = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Path", DbType="NVarChar(1000)")]
		public string Path
		{
			get
			{
				return this._Path;
			}
			set
			{
				if ((this._Path != value))
				{
					this._Path = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ArchiveName", DbType="NVarChar(100) NOT NULL", CanBeNull=false)]
		public string ArchiveName
		{
			get
			{
				return this._ArchiveName;
			}
			set
			{
				if ((this._ArchiveName != value))
				{
					this._ArchiveName = value;
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ArchivePath", DbType="NVarChar(100)")]
		public string ArchivePath
		{
			get
			{
				return this._ArchivePath;
			}
			set
			{
				if ((this._ArchivePath != value))
				{
					this._ArchivePath = value;
				}
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_Friend")]
	public partial class USR_Friend : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _UserID;
		
		private int _FriendUserID;
		
		private System.DateTime _InsertDate;
		
		private EntityRef<User> _User;
		
		private EntityRef<User> _User1;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUserIDChanging(int value);
    partial void OnUserIDChanged();
    partial void OnFriendUserIDChanging(int value);
    partial void OnFriendUserIDChanged();
    partial void OnInsertDateChanging(System.DateTime value);
    partial void OnInsertDateChanged();
    #endregion
		
		public USR_Friend()
		{
			this._User = default(EntityRef<User>);
			this._User1 = default(EntityRef<User>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserIDChanging(value);
					this.SendPropertyChanging();
					this._UserID = value;
					this.SendPropertyChanged("UserID");
					this.OnUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_FriendUserID", DbType="Int NOT NULL")]
		public int FriendUserID
		{
			get
			{
				return this._FriendUserID;
			}
			set
			{
				if ((this._FriendUserID != value))
				{
					if (this._User1.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnFriendUserIDChanging(value);
					this.SendPropertyChanging();
					this._FriendUserID = value;
					this.SendPropertyChanged("FriendUserID");
					this.OnFriendUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertDate", DbType="DateTime NOT NULL")]
		public System.DateTime InsertDate
		{
			get
			{
				return this._InsertDate;
			}
			set
			{
				if ((this._InsertDate != value))
				{
					this.OnInsertDateChanging(value);
					this.SendPropertyChanging();
					this._InsertDate = value;
					this.SendPropertyChanged("InsertDate");
					this.OnInsertDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_Friend", Storage="_User", ThisKey="UserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.USR_Friends.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.USR_Friends.Add(this);
						this._UserID = value.ID;
					}
					else
					{
						this._UserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_Friend1", Storage="_User1", ThisKey="FriendUserID", OtherKey="ID", IsForeignKey=true)]
		public User User1
		{
			get
			{
				return this._User1.Entity;
			}
			set
			{
				User previousValue = this._User1.Entity;
				if (((previousValue != value) 
							|| (this._User1.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User1.Entity = null;
						previousValue.USR_Friends1.Remove(this);
					}
					this._User1.Entity = value;
					if ((value != null))
					{
						value.USR_Friends1.Add(this);
						this._FriendUserID = value.ID;
					}
					else
					{
						this._FriendUserID = default(int);
					}
					this.SendPropertyChanged("User1");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_FriendRequest")]
	public partial class USR_FriendRequest : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _RequestCreatorUserID;
		
		private int _RequestSentToUserID;
		
		private int _RequestStatus;
		
		private System.DateTime _InsertDate;
		
		private EntityRef<User> _User;
		
		private EntityRef<User> _User1;
		
		private EntityRef<USR_FriendRequestStatus> _USR_FriendRequestStatus;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnRequestCreatorUserIDChanging(int value);
    partial void OnRequestCreatorUserIDChanged();
    partial void OnRequestSentToUserIDChanging(int value);
    partial void OnRequestSentToUserIDChanged();
    partial void OnRequestStatusChanging(int value);
    partial void OnRequestStatusChanged();
    partial void OnInsertDateChanging(System.DateTime value);
    partial void OnInsertDateChanged();
    #endregion
		
		public USR_FriendRequest()
		{
			this._User = default(EntityRef<User>);
			this._User1 = default(EntityRef<User>);
			this._USR_FriendRequestStatus = default(EntityRef<USR_FriendRequestStatus>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RequestCreatorUserID", DbType="Int NOT NULL")]
		public int RequestCreatorUserID
		{
			get
			{
				return this._RequestCreatorUserID;
			}
			set
			{
				if ((this._RequestCreatorUserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnRequestCreatorUserIDChanging(value);
					this.SendPropertyChanging();
					this._RequestCreatorUserID = value;
					this.SendPropertyChanged("RequestCreatorUserID");
					this.OnRequestCreatorUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RequestSentToUserID", DbType="Int NOT NULL")]
		public int RequestSentToUserID
		{
			get
			{
				return this._RequestSentToUserID;
			}
			set
			{
				if ((this._RequestSentToUserID != value))
				{
					if (this._User1.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnRequestSentToUserIDChanging(value);
					this.SendPropertyChanging();
					this._RequestSentToUserID = value;
					this.SendPropertyChanged("RequestSentToUserID");
					this.OnRequestSentToUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RequestStatus", DbType="Int NOT NULL")]
		public int RequestStatus
		{
			get
			{
				return this._RequestStatus;
			}
			set
			{
				if ((this._RequestStatus != value))
				{
					if (this._USR_FriendRequestStatus.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnRequestStatusChanging(value);
					this.SendPropertyChanging();
					this._RequestStatus = value;
					this.SendPropertyChanged("RequestStatus");
					this.OnRequestStatusChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_InsertDate", DbType="DateTime NOT NULL")]
		public System.DateTime InsertDate
		{
			get
			{
				return this._InsertDate;
			}
			set
			{
				if ((this._InsertDate != value))
				{
					this.OnInsertDateChanging(value);
					this.SendPropertyChanging();
					this._InsertDate = value;
					this.SendPropertyChanged("InsertDate");
					this.OnInsertDateChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_FriendRequest", Storage="_User", ThisKey="RequestCreatorUserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.USR_FriendRequests.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.USR_FriendRequests.Add(this);
						this._RequestCreatorUserID = value.ID;
					}
					else
					{
						this._RequestCreatorUserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_FriendRequest1", Storage="_User1", ThisKey="RequestSentToUserID", OtherKey="ID", IsForeignKey=true)]
		public User User1
		{
			get
			{
				return this._User1.Entity;
			}
			set
			{
				User previousValue = this._User1.Entity;
				if (((previousValue != value) 
							|| (this._User1.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User1.Entity = null;
						previousValue.USR_FriendRequests1.Remove(this);
					}
					this._User1.Entity = value;
					if ((value != null))
					{
						value.USR_FriendRequests1.Add(this);
						this._RequestSentToUserID = value.ID;
					}
					else
					{
						this._RequestSentToUserID = default(int);
					}
					this.SendPropertyChanged("User1");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_FriendRequestStatus_USR_FriendRequest", Storage="_USR_FriendRequestStatus", ThisKey="RequestStatus", OtherKey="ID", IsForeignKey=true)]
		public USR_FriendRequestStatus USR_FriendRequestStatus
		{
			get
			{
				return this._USR_FriendRequestStatus.Entity;
			}
			set
			{
				USR_FriendRequestStatus previousValue = this._USR_FriendRequestStatus.Entity;
				if (((previousValue != value) 
							|| (this._USR_FriendRequestStatus.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._USR_FriendRequestStatus.Entity = null;
						previousValue.USR_FriendRequests.Remove(this);
					}
					this._USR_FriendRequestStatus.Entity = value;
					if ((value != null))
					{
						value.USR_FriendRequests.Add(this);
						this._RequestStatus = value.ID;
					}
					else
					{
						this._RequestStatus = default(int);
					}
					this.SendPropertyChanged("USR_FriendRequestStatus");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_FriendRequestStatus")]
	public partial class USR_FriendRequestStatus : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ObligatoryID;
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<USR_FriendRequest> _USR_FriendRequests;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnObligatoryIDChanging(int value);
    partial void OnObligatoryIDChanged();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public USR_FriendRequestStatus()
		{
			this._USR_FriendRequests = new EntitySet<USR_FriendRequest>(new Action<USR_FriendRequest>(this.attach_USR_FriendRequests), new Action<USR_FriendRequest>(this.detach_USR_FriendRequests));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ObligatoryID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int ObligatoryID
		{
			get
			{
				return this._ObligatoryID;
			}
			set
			{
				if ((this._ObligatoryID != value))
				{
					this.OnObligatoryIDChanging(value);
					this.SendPropertyChanging();
					this._ObligatoryID = value;
					this.SendPropertyChanged("ObligatoryID");
					this.OnObligatoryIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_FriendRequestStatus_USR_FriendRequest", Storage="_USR_FriendRequests", ThisKey="ID", OtherKey="RequestStatus")]
		public EntitySet<USR_FriendRequest> USR_FriendRequests
		{
			get
			{
				return this._USR_FriendRequests;
			}
			set
			{
				this._USR_FriendRequests.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_USR_FriendRequests(USR_FriendRequest entity)
		{
			this.SendPropertyChanging();
			entity.USR_FriendRequestStatus = this;
		}
		
		private void detach_USR_FriendRequests(USR_FriendRequest entity)
		{
			this.SendPropertyChanging();
			entity.USR_FriendRequestStatus = null;
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_UserListAuthorization")]
	public partial class USR_UserListAuthorization : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _ID;
		
		private int _UserListID;
		
		private int _UserID;
		
		private int _AuthorizationTypeID;
		
		private EntityRef<USR_List> _USR_List;
		
		private EntityRef<User> _User;
		
		private EntityRef<USR_UserListAuthorizationType> _USR_UserListAuthorizationType;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnUserListIDChanging(int value);
    partial void OnUserListIDChanged();
    partial void OnUserIDChanging(int value);
    partial void OnUserIDChanged();
    partial void OnAuthorizationTypeIDChanging(int value);
    partial void OnAuthorizationTypeIDChanged();
    #endregion
		
		public USR_UserListAuthorization()
		{
			this._USR_List = default(EntityRef<USR_List>);
			this._User = default(EntityRef<User>);
			this._USR_UserListAuthorizationType = default(EntityRef<USR_UserListAuthorizationType>);
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL", IsPrimaryKey=true)]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserListID", DbType="Int NOT NULL")]
		public int UserListID
		{
			get
			{
				return this._UserListID;
			}
			set
			{
				if ((this._UserListID != value))
				{
					if (this._USR_List.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserListIDChanging(value);
					this.SendPropertyChanging();
					this._UserListID = value;
					this.SendPropertyChanged("UserListID");
					this.OnUserListIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UserID", DbType="Int NOT NULL")]
		public int UserID
		{
			get
			{
				return this._UserID;
			}
			set
			{
				if ((this._UserID != value))
				{
					if (this._User.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnUserIDChanging(value);
					this.SendPropertyChanging();
					this._UserID = value;
					this.SendPropertyChanged("UserID");
					this.OnUserIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AuthorizationTypeID", DbType="Int NOT NULL")]
		public int AuthorizationTypeID
		{
			get
			{
				return this._AuthorizationTypeID;
			}
			set
			{
				if ((this._AuthorizationTypeID != value))
				{
					if (this._USR_UserListAuthorizationType.HasLoadedOrAssignedValue)
					{
						throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException();
					}
					this.OnAuthorizationTypeIDChanging(value);
					this.SendPropertyChanging();
					this._AuthorizationTypeID = value;
					this.SendPropertyChanged("AuthorizationTypeID");
					this.OnAuthorizationTypeIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_List_USR_UserListAuthorization", Storage="_USR_List", ThisKey="UserListID", OtherKey="ID", IsForeignKey=true)]
		public USR_List USR_List
		{
			get
			{
				return this._USR_List.Entity;
			}
			set
			{
				USR_List previousValue = this._USR_List.Entity;
				if (((previousValue != value) 
							|| (this._USR_List.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._USR_List.Entity = null;
						previousValue.USR_UserListAuthorizations.Remove(this);
					}
					this._USR_List.Entity = value;
					if ((value != null))
					{
						value.USR_UserListAuthorizations.Add(this);
						this._UserListID = value.ID;
					}
					else
					{
						this._UserListID = default(int);
					}
					this.SendPropertyChanged("USR_List");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="User_USR_UserListAuthorization", Storage="_User", ThisKey="UserID", OtherKey="ID", IsForeignKey=true)]
		public User User
		{
			get
			{
				return this._User.Entity;
			}
			set
			{
				User previousValue = this._User.Entity;
				if (((previousValue != value) 
							|| (this._User.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._User.Entity = null;
						previousValue.USR_UserListAuthorizations.Remove(this);
					}
					this._User.Entity = value;
					if ((value != null))
					{
						value.USR_UserListAuthorizations.Add(this);
						this._UserID = value.ID;
					}
					else
					{
						this._UserID = default(int);
					}
					this.SendPropertyChanged("User");
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_UserListAuthorizationType_USR_UserListAuthorization", Storage="_USR_UserListAuthorizationType", ThisKey="AuthorizationTypeID", OtherKey="ID", IsForeignKey=true)]
		public USR_UserListAuthorizationType USR_UserListAuthorizationType
		{
			get
			{
				return this._USR_UserListAuthorizationType.Entity;
			}
			set
			{
				USR_UserListAuthorizationType previousValue = this._USR_UserListAuthorizationType.Entity;
				if (((previousValue != value) 
							|| (this._USR_UserListAuthorizationType.HasLoadedOrAssignedValue == false)))
				{
					this.SendPropertyChanging();
					if ((previousValue != null))
					{
						this._USR_UserListAuthorizationType.Entity = null;
						previousValue.USR_UserListAuthorizations.Remove(this);
					}
					this._USR_UserListAuthorizationType.Entity = value;
					if ((value != null))
					{
						value.USR_UserListAuthorizations.Add(this);
						this._AuthorizationTypeID = value.ID;
					}
					else
					{
						this._AuthorizationTypeID = default(int);
					}
					this.SendPropertyChanged("USR_UserListAuthorizationType");
				}
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
	}
	
	[global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.USR_UserListAuthorizationType")]
	public partial class USR_UserListAuthorizationType : INotifyPropertyChanging, INotifyPropertyChanged
	{
		
		private static PropertyChangingEventArgs emptyChangingEventArgs = new PropertyChangingEventArgs(String.Empty);
		
		private int _RequiredPKID;
		
		private int _ID;
		
		private string _Name;
		
		private EntitySet<USR_UserListAuthorization> _USR_UserListAuthorizations;
		
    #region Extensibility Method Definitions
    partial void OnLoaded();
    partial void OnValidate(System.Data.Linq.ChangeAction action);
    partial void OnCreated();
    partial void OnRequiredPKIDChanging(int value);
    partial void OnRequiredPKIDChanged();
    partial void OnIDChanging(int value);
    partial void OnIDChanged();
    partial void OnNameChanging(string value);
    partial void OnNameChanged();
    #endregion
		
		public USR_UserListAuthorizationType()
		{
			this._USR_UserListAuthorizations = new EntitySet<USR_UserListAuthorization>(new Action<USR_UserListAuthorization>(this.attach_USR_UserListAuthorizations), new Action<USR_UserListAuthorization>(this.detach_USR_UserListAuthorizations));
			OnCreated();
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RequiredPKID", AutoSync=AutoSync.OnInsert, DbType="Int NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)]
		public int RequiredPKID
		{
			get
			{
				return this._RequiredPKID;
			}
			set
			{
				if ((this._RequiredPKID != value))
				{
					this.OnRequiredPKIDChanging(value);
					this.SendPropertyChanging();
					this._RequiredPKID = value;
					this.SendPropertyChanged("RequiredPKID");
					this.OnRequiredPKIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", DbType="Int NOT NULL")]
		public int ID
		{
			get
			{
				return this._ID;
			}
			set
			{
				if ((this._ID != value))
				{
					this.OnIDChanging(value);
					this.SendPropertyChanging();
					this._ID = value;
					this.SendPropertyChanged("ID");
					this.OnIDChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(50) NOT NULL", CanBeNull=false)]
		public string Name
		{
			get
			{
				return this._Name;
			}
			set
			{
				if ((this._Name != value))
				{
					this.OnNameChanging(value);
					this.SendPropertyChanging();
					this._Name = value;
					this.SendPropertyChanged("Name");
					this.OnNameChanged();
				}
			}
		}
		
		[global::System.Data.Linq.Mapping.AssociationAttribute(Name="USR_UserListAuthorizationType_USR_UserListAuthorization", Storage="_USR_UserListAuthorizations", ThisKey="ID", OtherKey="AuthorizationTypeID")]
		public EntitySet<USR_UserListAuthorization> USR_UserListAuthorizations
		{
			get
			{
				return this._USR_UserListAuthorizations;
			}
			set
			{
				this._USR_UserListAuthorizations.Assign(value);
			}
		}
		
		public event PropertyChangingEventHandler PropertyChanging;
		
		public event PropertyChangedEventHandler PropertyChanged;
		
		protected virtual void SendPropertyChanging()
		{
			if ((this.PropertyChanging != null))
			{
				this.PropertyChanging(this, emptyChangingEventArgs);
			}
		}
		
		protected virtual void SendPropertyChanged(String propertyName)
		{
			if ((this.PropertyChanged != null))
			{
				this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
			}
		}
		
		private void attach_USR_UserListAuthorizations(USR_UserListAuthorization entity)
		{
			this.SendPropertyChanging();
			entity.USR_UserListAuthorizationType = this;
		}
		
		private void detach_USR_UserListAuthorizations(USR_UserListAuthorization entity)
		{
			this.SendPropertyChanging();
			entity.USR_UserListAuthorizationType = null;
		}
	}
}
#pragma warning restore 1591
