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

[assembly: global::System.Data.Objects.DataClasses.EdmSchemaAttribute()]

// Original file name:
// Generation date: 4/10/2009 3:48:56 PM
namespace SilverlightDataApp.Web
{
    
    /// <summary>
    /// There are no comments for PeopleDBEntities in the schema.
    /// </summary>
    public partial class PeopleDBEntities : global::System.Data.Objects.ObjectContext
    {
        /// <summary>
        /// Initializes a new PeopleDBEntities object using the connection string found in the 'PeopleDBEntities' section of the application configuration file.
        /// </summary>
        public PeopleDBEntities() : 
                base("name=PeopleDBEntities", "PeopleDBEntities")
        {
            this.OnContextCreated();
        }
        /// <summary>
        /// Initialize a new PeopleDBEntities object.
        /// </summary>
        public PeopleDBEntities(string connectionString) : 
                base(connectionString, "PeopleDBEntities")
        {
            this.OnContextCreated();
        }
        /// <summary>
        /// Initialize a new PeopleDBEntities object.
        /// </summary>
        public PeopleDBEntities(global::System.Data.EntityClient.EntityConnection connection) : 
                base(connection, "PeopleDBEntities")
        {
            this.OnContextCreated();
        }
        partial void OnContextCreated();
        /// <summary>
        /// There are no comments for RegTable in the schema.
        /// </summary>
        public global::System.Data.Objects.ObjectQuery<RegTable> RegTable
        {
            get
            {
                if ((this._RegTable == null))
                {
                    this._RegTable = base.CreateQuery<RegTable>("[RegTable]");
                }
                return this._RegTable;
            }
        }
        private global::System.Data.Objects.ObjectQuery<RegTable> _RegTable;
        /// <summary>
        /// There are no comments for RegTable in the schema.
        /// </summary>
        public void AddToRegTable(RegTable regTable)
        {
            base.AddObject("RegTable", regTable);
        }
    }
    /// <summary>
    /// There are no comments for PeopleDBModel.RegTable in the schema.
    /// </summary>
    /// <KeyProperties>
    /// id
    /// </KeyProperties>
    [global::System.Data.Objects.DataClasses.EdmEntityTypeAttribute(NamespaceName="PeopleDBModel", Name="RegTable")]
    [global::System.Runtime.Serialization.DataContractAttribute(IsReference=true)]
    [global::System.Serializable()]
    public partial class RegTable : global::System.Data.Objects.DataClasses.EntityObject
    {
        /// <summary>
        /// Create a new RegTable object.
        /// </summary>
        /// <param name="id">Initial value of id.</param>
        /// <param name="eesnimi">Initial value of eesnimi.</param>
        /// <param name="perenimi">Initial value of perenimi.</param>
        /// <param name="vanus">Initial value of vanus.</param>
        /// <param name="eriala">Initial value of eriala.</param>
        /// <param name="kursus">Initial value of kursus.</param>
        public static RegTable CreateRegTable(int id, string eesnimi, string perenimi, int vanus, string eriala, int kursus)
        {
            RegTable regTable = new RegTable();
            regTable.id = id;
            regTable.eesnimi = eesnimi;
            regTable.perenimi = perenimi;
            regTable.vanus = vanus;
            regTable.eriala = eriala;
            regTable.kursus = kursus;
            return regTable;
        }
        /// <summary>
        /// There are no comments for Property id in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(EntityKeyProperty=true, IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public int id
        {
            get
            {
                return this._id;
            }
            set
            {
                this.OnidChanging(value);
                this.ReportPropertyChanging("id");
                this._id = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
                this.ReportPropertyChanged("id");
                this.OnidChanged();
            }
        }
        private int _id;
        partial void OnidChanging(int value);
        partial void OnidChanged();
        /// <summary>
        /// There are no comments for Property eesnimi in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public string eesnimi
        {
            get
            {
                return this._eesnimi;
            }
            set
            {
                this.OneesnimiChanging(value);
                this.ReportPropertyChanging("eesnimi");
                this._eesnimi = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false);
                this.ReportPropertyChanged("eesnimi");
                this.OneesnimiChanged();
            }
        }
        private string _eesnimi;
        partial void OneesnimiChanging(string value);
        partial void OneesnimiChanged();
        /// <summary>
        /// There are no comments for Property perenimi in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public string perenimi
        {
            get
            {
                return this._perenimi;
            }
            set
            {
                this.OnperenimiChanging(value);
                this.ReportPropertyChanging("perenimi");
                this._perenimi = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false);
                this.ReportPropertyChanged("perenimi");
                this.OnperenimiChanged();
            }
        }
        private string _perenimi;
        partial void OnperenimiChanging(string value);
        partial void OnperenimiChanged();
        /// <summary>
        /// There are no comments for Property vanus in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public int vanus
        {
            get
            {
                return this._vanus;
            }
            set
            {
                this.OnvanusChanging(value);
                this.ReportPropertyChanging("vanus");
                this._vanus = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
                this.ReportPropertyChanged("vanus");
                this.OnvanusChanged();
            }
        }
        private int _vanus;
        partial void OnvanusChanging(int value);
        partial void OnvanusChanged();
        /// <summary>
        /// There are no comments for Property eriala in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public string eriala
        {
            get
            {
                return this._eriala;
            }
            set
            {
                this.OnerialaChanging(value);
                this.ReportPropertyChanging("eriala");
                this._eriala = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value, false);
                this.ReportPropertyChanged("eriala");
                this.OnerialaChanged();
            }
        }
        private string _eriala;
        partial void OnerialaChanging(string value);
        partial void OnerialaChanged();
        /// <summary>
        /// There are no comments for Property kursus in the schema.
        /// </summary>
        [global::System.Data.Objects.DataClasses.EdmScalarPropertyAttribute(IsNullable=false)]
        [global::System.Runtime.Serialization.DataMemberAttribute()]
        public int kursus
        {
            get
            {
                return this._kursus;
            }
            set
            {
                this.OnkursusChanging(value);
                this.ReportPropertyChanging("kursus");
                this._kursus = global::System.Data.Objects.DataClasses.StructuralObject.SetValidValue(value);
                this.ReportPropertyChanged("kursus");
                this.OnkursusChanged();
            }
        }
        private int _kursus;
        partial void OnkursusChanging(int value);
        partial void OnkursusChanged();
    }
}
