view delete me/SilverlightValidation/Models/UserModel.cs @ 64:ba89e36631bc

Latest version
author Steven Hollidge <stevenhollidge@hotmail.com>
date Sun, 22 Apr 2012 14:20:52 +0100
parents 3591c26bd63e
children
line wrap: on
line source

using System;
using System.ComponentModel;
using SilverlightValidation.Interfaces;

namespace SilverlightValidation.Models
{
    public class UserModel : IUserModel, ICloneable<UserModel>
    {
        public string Username { get; set; }
        public string Email { get; set; }
        public string Password { get; set; }
        public DateTime? DateOfBirth { get; set; }
        public string Description { get; set; }

        public static UserModel Create()
        {
            return new UserModel() { Username = "", Email = "", Password = "", DateOfBirth = null, Description = "" };
        }

        public UserModel Clone()
        {
            return (UserModel) this.MemberwiseClone(); 
        }
    }
}