[UIMA-3969] add scaffolding to wrap JsonGenerator method's IOExceptions into SAXExceptions to fit into our XmiCasSerialization.  Fix test case for getNumberOfChildren to access the value in the inner class.  Add some structures needed for JSON serialization, make many things in the inner class "final", update constructor for that.

git-svn-id: https://svn.apache.org/repos/asf/uima/uimaj/branches/2.6.0-json@1617505 13f79535-47bb-0310-9956-ffa450edef68
[UIMA-3969] remove duplicated stuff in serialize calls, add more json scaffolding, update javadocs.

git-svn-id: https://svn.apache.org/repos/asf/uima/uimaj/branches/2.6.0-json@1617511 13f79535-47bb-0310-9956-ffa450edef68