Like most new programmers I have a small but significant issue that i cannot figure out. My program will not pull my constructor. I have tried quite a few different ways and cant seem to figure it out. Any help would be greatly appreciated.
Error
EmployeeTest.java:13: cannot find symbol
symbol : constructor Employee()
location: class Employee
Employee x = new Employee();
^
EmployeeTest.java:14: cannot find symbol
symbol : constructor Employee()
location: class Employee
Employee y = new Employee();
public class Employee
{
private double salaryValue; // variable that stores monthlySalary
private String firstName; // instance variable that stores first name
private String lastName; // variable that stores last name
public Employee( String firstNameParameter , String lastNameParameter , double salaryValueParameter )
{
if ( salaryValueParameter < 0.0 ) // validate monthlySalary > 0.0
salaryValue = 0.0; // if not salary is intitalized to default
else
firstName = firstNameParameter;
lastName = lastNameParameter;
salaryValue = salaryValueParameter;
}
public class EmployeeTest
{
public static void main( String[] args )
{
String temp;
Double temp2;
Double temp3;
Employee x = new Employee();
Employee y = new Employee();
doubleis often not the best data type to model currency quantities due to the rounding errors that can accumulate over time.