Fixed field name
This commit is contained in:
parent
2654e5d000
commit
5387f6ce04
|
@ -18,6 +18,11 @@ import java.util.regex.Pattern;
|
|||
@Slf4j
|
||||
public class JSONPathWrapper {
|
||||
|
||||
/**
|
||||
* Based on
|
||||
*
|
||||
* https://github.com/json-path/JsonPath
|
||||
*/
|
||||
|
||||
public static Configuration JSON_PATH_ALWAYS_LIST_CONFIG=null;
|
||||
public static Configuration JSON_PATH_PATHS_CONFIGURATION=null;
|
||||
|
@ -63,7 +68,11 @@ public class JSONPathWrapper {
|
|||
return getByPath(path,Object.class);
|
||||
}
|
||||
|
||||
public List<String> getMatchingPaths(String path){return pathsCTX.read(path); }
|
||||
public List<String> getMatchingPaths(String path){
|
||||
List<String> l=pathsCTX.read(path);
|
||||
l.removeIf(p->p==null);
|
||||
return l;
|
||||
}
|
||||
|
||||
public <T> List<T> getByPath(String path,Class<T> clazz){
|
||||
List<T> l= valueCTX.read(path, new TypeRef<List<T>>() {});
|
||||
|
|
|
@ -8,7 +8,7 @@ import org.bson.Document;
|
|||
public class HandlerDeclaration {
|
||||
|
||||
public static final String ID="_id";
|
||||
public static final String TYPE="_TYPE";
|
||||
public static final String TYPE="_type";
|
||||
public static final String CONFIGURATION="_configuration";
|
||||
|
||||
@JsonProperty(ID)
|
||||
|
|
Loading…
Reference in New Issue