public class JSONFlattener extends Object
| Constructor and Description |
|---|
JSONFlattener() |
| Modifier and Type | Method and Description |
|---|---|
static com.fasterxml.jackson.databind.node.ObjectNode |
generateFlatJSON(com.fasterxml.jackson.databind.node.ObjectNode flatJsonNode,
com.fasterxml.jackson.databind.JsonNode node,
String prefix,
Set<String> excludedAttributes)
Generate a flattened json node from the given hierarchical json node.
|
public static com.fasterxml.jackson.databind.node.ObjectNode generateFlatJSON(com.fasterxml.jackson.databind.node.ObjectNode flatJsonNode,
com.fasterxml.jackson.databind.JsonNode node,
String prefix,
Set<String> excludedAttributes)
flatJsonNode - flat json node to be created.node - Hierarchical JSON node.prefix - prefix is used to preserve hierarchy in flat node.excludedAttributes - attributes to exclude when converting to flat JSON.Copyright © 2023 WSO2. All rights reserved.