I have a deceptively simple scenario, and I want a simple solution, but it\'s not obvious which is \"most correct\" or \"most Java\".
Let\'s say I have a small authe
You could use exceptions....
try { AuthenticateMethod(); } catch (AuthenticateError ae) { // Display ae.getMessage() to user.. System.out.println(ae.getMessage()); //ae.printStackTrace(); }
and then if an error occurs in your AuthenticateMethod you send a new AuthenticateError (extends Exception)