0

EInterface: this Interface has an attribute NOW that holds the current date. DEFAULT_DATE holds a default date (May 1, 1990), and a series of formatters for currency, two decimals, and percentage (labeled as CURRENCY_FORMATTER, TWO_DIGIT_FORMATTER, and PERCENTAGE_FORMATTER respectively). Additionally, EInterface defines two methods: findGross and findNet. (Hint: explore a series of classes including Calendar, GregorianCalendar, NumberFormat, DecimalFormat, etc).

What am I doing with NOW? and I think I'm supposed to initialize it but how?
I don't get the last sentence at all. I understand that they are methods but how would I write them?

public interface EmployeeInterface{
public static final DefaultDate DEFAULT_DATE = new DefaultDate ("May 1, 1990");
public static final CurrencyFormatter CURRENCYFORMATTER = new CurrencyFormatter ("0.00");
public static final PercentageFormatter PERCENTAGE_FORMATTER = new PercentageFormatter ("0.00");
//not sure if I should use this one or the first default Date
public static final GregorianCalendar DEFAULT_DATE = new Gregorian Calendar();
}
2
Contributors
1
Reply
2
Views
7 Years
Discussion Span
Last Post by Taywin
0

This is Javascript forum, not Java. They are two different languages.

Anyway, it looks like something like your homework. What you need to understand is what findGross() and findNet() are going to produce. They are methods you need to implement using existing instance variable declared above.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.