A Java class to ensure an inputted string is a Palindrome