Package com.northconcepts.datapipeline.json.builder
package com.northconcepts.datapipeline.json.builder
Programmatic JSON creation.
-
ClassDescriptionA JSON array in a
JsonTemplate; elements are added withJsonArray.object(),JsonArray.array()andJsonArray.value(String).A fragment of aJsonTemplatewhose nodes are written only when its logical expression is true; created bywhen(String).Marks where records go in aJsonTemplate; the nodes added to it are written once for each record.An expression for a field name or value in aJsonTemplate, parsed once and evaluated on each write.A field of a JSON object in aJsonTemplate: an expression for its name plus aJsonValue.Base class for template nodes that write only their children, not JSON of their own, and take their type from the parent node.A boolean expression that decides whether aJsonConditionalNode's nodes are written.Base class for the nodes of aJsonTemplate; each writes its opening and closing JSON to a Jackson generator.The kinds of nodes in aJsonTemplate: scalar values, arrays, objects and object fields.Walks aJsonTemplate's node tree depth-first, writing one node to a Jackson generator per step.A JSON object in aJsonTemplate; fields are added withJsonObject.field(String, String),JsonObject.object(String)andJsonObject.array(String).A scalar value in aJsonTemplatecomputed from an expression; dates, times and datetimes are written asyyyy-MM-dd,HH:mm:ss.SSSandyyyy-MM-dd'T'HH:mm:ss.SSS'Z'strings.Describes the JSON aJsonWriterproduces: nodes before theJsonFragment.detail()marker form the header, the marker's nodes are written once per record and the remaining nodes form the footer.Base class for the objects, arrays and scalar values of aJsonTemplate.