add a simple user login system. Figures 2 and 3 show the layout and the required controls. The application should meet the following specifications: 1. Upon starting the application, display a form that asks the user to enter a username and password. 2. Validate the user's username and password, if it matches the required credentials.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question
14
Cashier Application_Surname from Question 26 and
add a simple user login system. Figures 2 and 3 show
the layout and the required controls. The application
should meet the following specifications:
1. Upon starting the application, display a form
that asks the user to enter a username and
password.
2. Validate the user's username and password, if
it matches the required credentials.
3. If the user has successfully logged in, close the
login form and display the full name and
department of the user.
4. Users can select Logout and Exit.
5. The application should contain two (2) separate
classes: User Account and Cashier. The Cashier
class should inherit from the UserAccount
class. Make these classes members of the
namespace User AccountNamespace. Refer to
the UML class diagram below.
Legend
(+)-public
(-)-private
(*) - protected
italicized abstract members
User Login
Username
cashier101
Password
File
-full_name: string
#user_name: string
#user_password: string
+ UserAccount (string name, string uName,
string password)
validateLogin(string uName,
string password): bool
getFullName(): string
4
Cashier
Purchase Discounted Item
- department: string
+Cashier(string name, string department,
string uName, string password)
validateLogin(string uName,
string password): bool
+ getDepartment(): string
Price:
Logout
Exit Application
Login
Figure 2. Example frmLoginAccount form layout and welcome message after
successfully logging in
User Account
Total amount: 0.00
Payment received:
Welcome Clarisa Castro of Financa
Compute
Change: 0.00
Discount (%):
OK
Quantity:
X
...
Submit
Figure 3. Example frmPurchaseDiscounted Item with a menu strip control
Transcribed Image Text:Cashier Application_Surname from Question 26 and add a simple user login system. Figures 2 and 3 show the layout and the required controls. The application should meet the following specifications: 1. Upon starting the application, display a form that asks the user to enter a username and password. 2. Validate the user's username and password, if it matches the required credentials. 3. If the user has successfully logged in, close the login form and display the full name and department of the user. 4. Users can select Logout and Exit. 5. The application should contain two (2) separate classes: User Account and Cashier. The Cashier class should inherit from the UserAccount class. Make these classes members of the namespace User AccountNamespace. Refer to the UML class diagram below. Legend (+)-public (-)-private (*) - protected italicized abstract members User Login Username cashier101 Password File -full_name: string #user_name: string #user_password: string + UserAccount (string name, string uName, string password) validateLogin(string uName, string password): bool getFullName(): string 4 Cashier Purchase Discounted Item - department: string +Cashier(string name, string department, string uName, string password) validateLogin(string uName, string password): bool + getDepartment(): string Price: Logout Exit Application Login Figure 2. Example frmLoginAccount form layout and welcome message after successfully logging in User Account Total amount: 0.00 Payment received: Welcome Clarisa Castro of Financa Compute Change: 0.00 Discount (%): OK Quantity: X ... Submit Figure 3. Example frmPurchaseDiscounted Item with a menu strip control
Question 26
[MO31] Assume you have declared a method as
follows:
private static double CalculateDiscount (int acct =0,
double price = 0, double discount= 0), Which of the
following is a legal method call?
A) CalculateDiscount (3000.00, 0.02)
B) CalculateDiscount();
None of these is legal
D) CalculateDiscount (200.00)
Transcribed Image Text:Question 26 [MO31] Assume you have declared a method as follows: private static double CalculateDiscount (int acct =0, double price = 0, double discount= 0), Which of the following is a legal method call? A) CalculateDiscount (3000.00, 0.02) B) CalculateDiscount(); None of these is legal D) CalculateDiscount (200.00)
Expert Solution
steps

Step by step

Solved in 3 steps

Blurred answer
Knowledge Booster
MacOS
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education