public class Payee
extends java.lang.Object
Constructor and Description |
---|
Payee()
No parameter constructor for objects of class Payee.
|
Payee(double hoursWorked,
double payRate)
Constructor for objects of class Payee with parameters that initialize
the hours worked and pay rate data fields.
|
Modifier and Type | Method and Description |
---|---|
double |
getGrossPay()
Calculates and returns employee gross pay.
|
double |
getHoursWorked()
Accessor method for the hours worked data field.
|
double |
getPayRate()
Accessor method for the pay rate data field.
|
void |
setHoursWorked(double hoursWorked)
Mutator method for the hours worked data field.
|
void |
setPayRate(double payRate)
Mutator method for the pay rate data field.
|
java.lang.String |
toString()
Returns a string represention of a Payee with labels.
|
public Payee()
public Payee(double hoursWorked, double payRate)
hoursWorked
- the employee number of hours workedpayRate
- the employee hourly rate of paypublic double getGrossPay()
public double getHoursWorked()
public double getPayRate()
public void setHoursWorked(double hoursWorked)
hoursWorked
- the employee number of hours workedpublic void setPayRate(double payRate)
payRate
- the employee hourly rate of paypublic java.lang.String toString()
toString
in class java.lang.Object