mirror of https://github.com/apache/nifi.git
Adjusting scope of methods as they are specific to the JsonPath related processors
This commit is contained in:
parent
46bf048b24
commit
d6948601cd
|
@ -61,7 +61,7 @@ public abstract class AbstractJsonPathProcessor extends AbstractProcessor {
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
public static DocumentContext validateAndEstablishJsonContext(ProcessSession processSession, FlowFile flowFile) {
|
static DocumentContext validateAndEstablishJsonContext(ProcessSession processSession, FlowFile flowFile) {
|
||||||
|
|
||||||
final BooleanHolder validJsonHolder = new BooleanHolder(false);
|
final BooleanHolder validJsonHolder = new BooleanHolder(false);
|
||||||
processSession.read(flowFile, new InputStreamCallback() {
|
processSession.read(flowFile, new InputStreamCallback() {
|
||||||
|
@ -101,7 +101,7 @@ public abstract class AbstractJsonPathProcessor extends AbstractProcessor {
|
||||||
return !(obj instanceof Map || obj instanceof List);
|
return !(obj instanceof Map || obj instanceof List);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String getResultRepresentation(Object jsonPathResult) {
|
static String getResultRepresentation(Object jsonPathResult) {
|
||||||
if (isJsonScalar(jsonPathResult)) {
|
if (isJsonScalar(jsonPathResult)) {
|
||||||
return jsonPathResult.toString();
|
return jsonPathResult.toString();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue