Utils to normalizes params map to transform it to mango language
| Type Params | Return Type | Name and description |
|---|---|---|
|
static Map |
pathToMap(String path, Object val, Map map)Extends the map with nested value by specific path so pathToMap("a.b.c", 1, [:]) -> [a:[b:[c:1]]] or pathToMap("a.b.c", 1, [d:2]) -> [a:[b:[c:1]], d:2] |
|
static Map |
tidy(Map<String, Object> map)Transforms passed params map to normalized mango criteria map |
|
static Map |
toMangoOperator(Map map, Map result = [:])Adds mango operators based on values types |
Extends the map with nested value by specific path so pathToMap("a.b.c", 1, [:]) -> [a:[b:[c:1]]] or pathToMap("a.b.c", 1, [d:2]) -> [a:[b:[c:1]], d:2]
path - path in the nested map where value should be placedval - value that should be added to the nested mapmap - map that should be extended with the nested valueTransforms passed params map to normalized mango criteria map
map - params that should be transformed to mango language