示例#1
0
 /// <summary>
 /// Creates an user library account
 /// </summary>
 /// <param name="name">Name of the User</param>
 /// <param name="phonenumber">User Phone Number</param>
 /// <param name="address">User Address</param>
 /// <returns>Account Number</returns>
 public static LibraryAccount CreateAccount(string name,string phonenumber,string address)
 {
     LibraryAccount account = new LibraryAccount(name);
     account.PhoneNumber = phonenumber;
     accounts.Add(account);
     return account;
 }
示例#2
0
        /// <summary>
        /// Creates an user library account
        /// </summary>
        /// <param name="name">Name of the User</param>
        /// <param name="phonenumber">User Phone Number</param>
        /// <param name="address">User Address</param>
        /// <returns>Account Number</returns>
        public static LibraryAccount CreateAccount(string name, string phonenumber, string address)
        {
            LibraryAccount account = new LibraryAccount(name);

            account.PhoneNumber = phonenumber;
            accounts.Add(account);
            return(account);
        }
示例#3
0
        static void Main(string[] args)
        {
            LibraryAccount myAccount = LibraryFactory.CreateAccount("Madhu", "425-657-988", "Redmond");

            Console.WriteLine("Account Number: {0}, Name: {1},Address: {2}",
                              myAccount.AccountNumber, myAccount.UserName, myAccount.Address);

            LibraryFactory.CreateSummary();
            Console.WriteLine(LibraryFactory.CheckOutReport);
        }