Esempio n. 1
0
        public login(DataRow row)
        {
            // Assign default persister to instance persister
            _Persister = _DefaultPersister;

            // Assign column values to private members
            for (int i = 0; i < row.Table.Columns.Count; i++)
            {
                switch (row.Table.Columns[i].ColumnName.ToUpper())
                {
                case "ID":
                    this.id = Convert.ToInt32(row[i, DataRowVersion.Current]);
                    break;

                case "NAME":
                    this.name = (string)row[i, DataRowVersion.Current];
                    break;

                case "EMAIL":
                    this.email = (string)row[i, DataRowVersion.Current];
                    break;

                case "PASSWORD":
                    this.password = (string)row[i, DataRowVersion.Current];
                    break;
                }
            }
        }
Esempio n. 2
0
        public login(int _id)
        {
            // Assign default persister to instance persister
            _Persister = _DefaultPersister;

            // Assign method parameter to private fields
            this._id = _id;

            // Call associated retrieve method
            Retrieve();
        }
Esempio n. 3
0
 public login()
 {
     // Assign default persister to instance persister
     _Persister = _DefaultPersister;
 }
Esempio n. 4
0
 static login()
 {
     // Assign default persister
     _DefaultPersister = new SqlServerloginPersister();
 }