The java
string class has methods to do each of the things you're asking about.
.equals() and .length() for the first two.
While you can manually tear the string apart, there is a method .split() which will parse out comma separated (or any regular expression separated) substrings.