Write a test client to test all your methods in your class

Assignment Help Computer Engineering
Reference no: EM132164233

Assignment

When a user signs in for the first time to a website, the user has to submit personal information, such as user_id, name, email address, telephone number and so on.

Typically, there are two fields for passwords, requiring the user to enter the password twice, to ensure that the user did not make a typo in the first password field.

Write a class encapsulating the concept of processing a form with the following elements:

User_id

Password

Reenter password

Email address

Name

Street Address

City

State

Zip

Telephone

You will store these values as strings in an array.

Write the following methods in your class:

1. A constructor with one parameter, an array of 10 strings (representing one element for each of the fields above), the only instance variable.

2. Accessor, mutator, toString methods

3. A method checking that no Strings are empty. If at least one is empty, return false; otherwise return true.

4. A method returning the number of characters in the user_id

5. A method checking if the two Strings representing the password fields are the same, if they are return true, otherwise false.

6. A method checking if the email address contains one and only one @ character and contains at least one "." after the @ character. If these conditions are met, return true; otherwise return false.

Write a test client to test all your methods in your class.

Reference no: EM132164233

Questions Cloud

Self the same or different than your everyday self : Is your leader "self" the same or different than your everyday "self"? Is this even a valid question?
Court should order the specific performance : The company sued and asked a court to order to fix it. Do you think the court should order the specific performance?
Discuss about the network security policies : Users are complaining that recently implemented changes to network security policies have resulted in password requirements that are too complex.
Describe what should be included in the front matter : Describe what should be included in the front matter? Provide Example.
Write a test client to test all your methods in your class : A constructor with one parameter, an array of 10 strings (representing one element for each of the fields above), the only instance variable.
Examples of successful application of knowledge : Examples of Successful Application of Knowledge of Specific Key Influences on Consumer Behaviour in the food and drink sector
Computes the total cost of the purchase : Develop a program that asks for the number of units sold and computes the total cost of the purchase. Input Validation: Make sure the number of units is greater
Comparing Frederick Douglas and Nat Turner slave narratives : Write a brief essay (4-5 pages, double-spaced, 12-pt. font, Times New Roman) comparing and contrasting the Frederick Douglas and Nat Turner slave narratives
How do squirrels adapt to rattlesnake venom : How do squirrels adapt to rattlesnake venom? How do rattlesnakes adapt to squirrel's defenses against rattlesnake venom?

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd