It is easy. To convert the string to lower case:
str = str.toLowerCase();
To remove whitespaces at the beginning and the end.
str = str.trim();
Check if a string starts with something:
if...
Type: Posts; User: Kerr
It is easy. To convert the string to lower case:
str = str.toLowerCase();
To remove whitespaces at the beginning and the end.
str = str.trim();
Check if a string starts with something:
if...
If-else would be easiest :). A regex could maybe work very well.
Lesson: Regular Expressions (The Java™ Tutorials > Essential Classes)
Even though there may be a better and simpler way (not that...