//------------------------------------------------------------------------------ // // This code was generated from a template. // // Manual changes to this file may cause unexpected behavior in your application. // Manual changes to this file will be overwritten if the code is regenerated. // //------------------------------------------------------------------------------ using System; using System.Data.Objects; using System.Data.Objects.DataClasses; using System.Data.EntityClient; using System.ComponentModel; using System.Xml.Serialization; using System.Runtime.Serialization; [assembly: EdmSchemaAttribute()] namespace Zepheus.Login.Data { #region Contexts /// /// No Metadata Documentation available. /// public partial class AccountEntity : ObjectContext { #region Constructors /// /// Initializes a new AccountEntity object using the connection string found in the 'AccountEntity' section of the application configuration file. /// public AccountEntity() : base("name=AccountEntity", "AccountEntity") { this.ContextOptions.LazyLoadingEnabled = true; OnContextCreated(); } /// /// Initialize a new AccountEntity object. /// public AccountEntity(string connectionString) : base(connectionString, "AccountEntity") { this.ContextOptions.LazyLoadingEnabled = true; OnContextCreated(); } /// /// Initialize a new AccountEntity object. /// public AccountEntity(EntityConnection connection) : base(connection, "AccountEntity") { this.ContextOptions.LazyLoadingEnabled = true; OnContextCreated(); } #endregion #region Partial Methods partial void OnContextCreated(); #endregion #region ObjectSet Properties /// /// No Metadata Documentation available. /// public ObjectSet Users { get { if ((_Users == null)) { _Users = base.CreateObjectSet("Users"); } return _Users; } } private ObjectSet _Users; #endregion #region AddTo Methods /// /// Deprecated Method for adding a new object to the Users EntitySet. Consider using the .Add method of the associated ObjectSet<T> property instead. /// public void AddToUsers(User user) { base.AddObject("Users", user); } #endregion } #endregion #region Entities /// /// No Metadata Documentation available. /// [EdmEntityTypeAttribute(NamespaceName="AccountModel", Name="User")] [Serializable()] [DataContractAttribute(IsReference=true)] public partial class User : EntityObject { #region Factory Method /// /// Create a new User object. /// /// Initial value of the ID property. /// Initial value of the Username property. /// Initial value of the Password property. /// Initial value of the Admin property. /// Initial value of the Banned property. public static User CreateUser(global::System.Int32 id, global::System.String username, global::System.String password, global::System.Byte admin, global::System.Boolean banned) { User user = new User(); user.ID = id; user.Username = username; user.Password = password; user.Admin = admin; user.Banned = banned; return user; } #endregion #region Primitive Properties /// /// No Metadata Documentation available. /// [EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)] [DataMemberAttribute()] public global::System.Int32 ID { get { return _ID; } set { if (_ID != value) { OnIDChanging(value); ReportPropertyChanging("ID"); _ID = StructuralObject.SetValidValue(value); ReportPropertyChanged("ID"); OnIDChanged(); } } } private global::System.Int32 _ID; partial void OnIDChanging(global::System.Int32 value); partial void OnIDChanged(); /// /// No Metadata Documentation available. /// [EdmScalarPropertyAttribute(EntityKeyProperty=false, IsNullable=false)] [DataMemberAttribute()] public global::System.String Username { get { return _Username; } set { OnUsernameChanging(value); ReportPropertyChanging("Username"); _Username = StructuralObject.SetValidValue(value, false); ReportPropertyChanged("Username"); OnUsernameChanged(); } } private global::System.String _Username; partial void OnUsernameChanging(global::System.String value); partial void OnUsernameChanged(); /// /// No Metadata Documentation available. /// [EdmScalarPropertyAttribute(EntityKeyProperty=false, IsNullable=false)] [DataMemberAttribute()] public global::System.String Password { get { return _Password; } set { OnPasswordChanging(value); ReportPropertyChanging("Password"); _Password = StructuralObject.SetValidValue(value, false); ReportPropertyChanged("Password"); OnPasswordChanged(); } } private global::System.String _Password; partial void OnPasswordChanging(global::System.String value); partial void OnPasswordChanged(); /// /// No Metadata Documentation available. /// [EdmScalarPropertyAttribute(EntityKeyProperty=false, IsNullable=false)] [DataMemberAttribute()] public global::System.Byte Admin { get { return _Admin; } set { OnAdminChanging(value); ReportPropertyChanging("Admin"); _Admin = StructuralObject.SetValidValue(value); ReportPropertyChanged("Admin"); OnAdminChanged(); } } private global::System.Byte _Admin; partial void OnAdminChanging(global::System.Byte value); partial void OnAdminChanged(); /// /// No Metadata Documentation available. /// [EdmScalarPropertyAttribute(EntityKeyProperty=false, IsNullable=true)] [DataMemberAttribute()] public global::System.String Email { get { return _Email; } set { OnEmailChanging(value); ReportPropertyChanging("Email"); _Email = StructuralObject.SetValidValue(value, true); ReportPropertyChanged("Email"); OnEmailChanged(); } } private global::System.String _Email; partial void OnEmailChanging(global::System.String value); partial void OnEmailChanged(); /// /// No Metadata Documentation available. /// [EdmScalarPropertyAttribute(EntityKeyProperty=false, IsNullable=false)] [DataMemberAttribute()] public global::System.Boolean Banned { get { return _Banned; } set { OnBannedChanging(value); ReportPropertyChanging("Banned"); _Banned = StructuralObject.SetValidValue(value); ReportPropertyChanged("Banned"); OnBannedChanged(); } } private global::System.Boolean _Banned; partial void OnBannedChanging(global::System.Boolean value); partial void OnBannedChanged(); #endregion } #endregion }