My code is breaking on the following line with a nullpointerexception:
if (stringVariable.equals(null)){
Previous to this statement, I dec
if stringvariableis already null, it doesn't exist as a String object anymore, so it won't even have a .equals method! So in the event when stringvariable is null, what you are really doing is null.equals(null), at which point you'll get the NullPointerException because null doesn't have a .equals() method.