This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I have marked the no-argument constructor of Employee class as private as I want to make it singleton.
I have a form page asking username and password (with form field names emp.name and emp.password) that is mapped to Login.java Action. But when I submit form, I get an exception that saying it cannot create Employee object as its constructor is marked as private.
So how do I solve this problem still keeping the Employee object as singleton?