Skip to content

Commit

Permalink
Merge pull request #22 from embulk/allow-multiple-matches
Browse files Browse the repository at this point in the history
Allow multiple matches with JsonPointerBasedFilter
  • Loading branch information
dmikurube authored Jul 3, 2023
2 parents 3428732 + fc4971f commit ca30dca
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/main/java/org/embulk/util/json/JsonParser.java
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,12 @@ private static String sampleJsonString(final String json) {

private static com.fasterxml.jackson.core.JsonParser wrapWithPointerFilter(
final com.fasterxml.jackson.core.JsonParser baseParser, final String offsetInJsonPointer) {
return new FilteringParserDelegate(baseParser, new JsonPointerBasedFilter(offsetInJsonPointer), false, false);
return new FilteringParserDelegate(
baseParser,
new JsonPointerBasedFilter(offsetInJsonPointer),
false,
true // Allow multiple matches
);
}

private static class StreamParseContext extends AbstractParseContext implements Stream {
Expand Down

0 comments on commit ca30dca

Please sign in to comment.