public enum PathType extends Enum<PathType>
| Enum Constant and Description |
|---|
JSON_PATH
Paths as JSONPath expressions.
|
JSON_POINTER
Paths as JSONPointer expressions.
|
LEGACY
The legacy approach, loosely based on JSONPath (but not guaranteed to give valid JSONPath expressions).
|
| Modifier and Type | Field and Description |
|---|---|
static PathType |
DEFAULT
The default path generation approach to use.
|
| Modifier and Type | Method and Description |
|---|---|
String |
append(String currentPath,
int index)
Append the given index to the provided current path.
|
String |
append(String currentPath,
String child)
Append the given child token to the provided current path.
|
String |
convertToJsonPointer(String path) |
String |
getRoot()
Return the representation of the document root.
|
static PathType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static PathType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PathType LEGACY
public static final PathType JSON_PATH
public static final PathType JSON_POINTER
public static final PathType DEFAULT
public static PathType[] values()
for (PathType c : PathType.values()) System.out.println(c);
public static PathType valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic String append(String currentPath, String child)
currentPath - The path to append to.child - The child token.public String append(String currentPath, int index)
currentPath - The path to append to.index - The index to append.public String getRoot()
Copyright © 2023. All rights reserved.