Fix app crash when attempting to edit a tree with no date planted value

Caused by ClassCastException, we were trying to cast to a String before
checking if the value was in fact a JSONObject.NULL value

Fixes #141
Merge pull request #142 from maurizi/fix-app-crash-date-fields

Fix app crash when attempting to edit a tree with no date planted value
Move Field and EcoField into their own package
Remove unused editViewOnly field

From what I can see, this was always set to false
Cleanup code

 - Iterate over values instead of entries when possible
 - Don't loop over a map when you can just get the value by the key
Fix a few comment line endings
Move getValueForLatestPendingEditByRelatedField to be a Plot method

Also puts Log calls in place of the auto-generated stack trace printing,
renames the method now that it no longer takes a "related field" and fixes
the JavaDoc
Remove irrelevant code dealing with relatedFields

Not needed anymore since the concept of a relatedField has been removed
Fix API compatability issues
Pull out choice code into subclass of Field
Refactor formatUnit to be more DRY
Pull species code out of Field into SpeciesField
Pull common code for rendering buttons into abstract super class
Remove the User parameter from renderForEdit

Nothing in the field rendering code needs the logged in user...
Pull out date handling code from Field into DateField subclass
Pull out TextField class from Field - Field is now abstract

This also requires some small changes to EcoField, which isn't an editable
field at all.
Make Field instance fields final for safer access
Rename formatUnit to formatValue, and provide a default implementation

Not all Fields have units, but they all need to format their values
Pull diameter code out of TextField and TreeEditDisplay into new class
Pull code for setting species based on intent result into SpeciesField

This should make it fairly simple to add more fields which start activities
and receive data in return.