Reference no: EM13167016
You will create a Java class named Date that is used to work with date operations. Then you will write a Driver to test each method you wrote in the Dare class and display, on the screen, a clear explanation and result of each test.
For documentation, use inline comments AND javadoc comments above each class and above each method. Use the tags : @author, @version, @param, @return
Mandatory methods for the Date class:
- At least three constructor methods, including the default constructor and the copy constructor.
- A toString( ) method.
- An equals( ) method.
- A compareTo( ) method.
- an add( ) method that adds an integer number of days to an existing Date and returns the new Date object:
Date myDate = new Date(3, 20, 2014);
Date result;
result = Date.add(15);
System.out.println(result);
- A subtract( ) method that subtracts an integer number of days from an exisiting Date and returns a new Date object.
Date myDate = new Date(3, 20, 2014);
Date result;
result = myDate.subtract(5);
System.out.println(result);
A dateDiff( ) methods that calculates and returns the number of days between the parameters and the Date object.
Date dateOne = new Date(3,15, 2014);
Date dateTwo = new Date(4, 18, 2014);
int difference;
difference = dateOne.difference(dateTwo);
System.out.println("the difference between " + dateOne + " and " + dateTwo + " is" + difference + " days");
The code must take into account leap year and adding or subtracting between years. Write two additional methods that you come with on your own as well.
Strengths and weaknesses of three dbms software
: Research Report around 800 words strengths and weaknesses of three DBMS software packages for utilization as a company-wide customer information database. Please compare Microsoft Access, Microsoft SQL Server, and Oracle.
|
Explain how entities are transformed into tables
: 5.1-Explain how entities are transformed into tables?
|
String converter
: String Converter: Implement a program that asks the user to input up to 20 strings (stopping when the user inputs 0). Store these strings in a 2-dimensional array. Replace all the characters that are upper-cased to their lower-case equivalent.
|
Prefetching is a technique that leverages predictable
: Prefetching is a technique that leverages predictable address patterns to speculatively bring in additional cache blocks when a particular cache block is accessed. One example of prefetching is a stream buffer that prefetches sequentially adjacent..
|
The code must take into account
: The code must take into account leap year and adding or subtracting between years. Write two additional methods that you come with on your own as well.
|
Becoming cluster master and successfully
: HCHLock lock, what will happen if the time between becoming cluster master and successfully splicing the local queue into the global queue is too small? Suggest a remedy to this problem.
|
Detennine the transition width in hz
: 1. A rectangular window with 25 terms is used to design a low pass FIR filter. The pass band edge is located at 2 kHz and the pass band gain is about 0 dB. For a samplin frequency of 20 kHz:
|
Distribute music on the internet.
: an architecture for a system (such as iTunes) that is used to sell and distribute music on the Internet. What architectural patterns did you use as the basis for this architecture? Why are these patterns appropriate?
|
Express the relationships graphically with an e-r diagram.
: A vendor builds multiple types of tablet computers. Each hs a type identification number and a name. The key specifications for each type include amount of storage and display type.
|