Fixed problems with == and .equals

In converting between C# and Java, I neglected to switch from == to
.equals in a number of places.  This should take care of most of those
issues.
Upate gitignore
Update gitignore again.