Uses of Class
org.klojang.util.Path

Packages that use Path
Package
Description
Utility classes for working with strings, numbers, arrays, collections, etc.
  • Uses of Path in org.klojang.util

    Classes in org.klojang.util that implement interfaces with type arguments of type Path
    Modifier and Type
    Class
    Description
    final class 
    Specifies a path to a value within an object.
    Methods in org.klojang.util that return Path
    Modifier and Type
    Method
    Description
    Path.append(String path)
    Returns a new Path representing the concatenation of this Path and the specified Path.
    Path.append(Path other)
    Returns a new Path consisting of the segments of this Path plus the segments of the specified Path.
    static Path
    Path.empty()
    Returns an empty Path instance, consisting of zero path segments.
    static Path
    Path.from(String path)
    Returns a new Path instance for the specified path string.
    Returns a new Path containing only the segments of this Path that are not array indices.
    static Path
    Path.of(String segment)
    Returns a Path consisting of a single segment.
    static Path
    Path.of(String... segments)
    Returns a Path consisting of the specified segments.
    static Path
    Path.of(String segment0, String segment1)
    Returns a Path consisting of the specified segments.
    static Path
    Path.of(String segment0, String segment1, String segment2)
    Returns a Path consisting of the specified segments.
    static Path
    Path.of(String segment0, String segment1, String segment2, String segment3)
    Returns a Path consisting of the specified segments.
    static Path
    Path.of(String segment0, String segment1, String segment2, String segment3, String segment4)
    Returns a Path consisting of the specified segments.
    static Path
    Path.ofSegments(String[] segments)
    Returns a Path consisting of the specified segments.
    static Path
    Path.ofSegments(List<String> segments)
    Returns a Path consisting of the specified segments.
    Path.parent()
    Returns a Path with all segments of this Path except the last segment.
    Path.replace(int index, String newValue)
    Returns a new Path with the path segment at the specified array index set to the new value.
    Path.reverse()
    Returns a Path in which the order of the segments is reversed.
    Path.shift()
    Returns a Path with all segments of this Path except the first segment.
    Path.subPath(int offset)
    Returns a new Path starting with the segment at the specified array index.
    Path.subPath(int offset, int length)
    Returns a new Path consisting of length segments starting with segment offset.
    Methods in org.klojang.util with parameters of type Path
    Modifier and Type
    Method
    Description
    JSONObject.addElement(Path path, Object element)
    Appends the specified element to the Collection found at the specified path.
    Path.append(Path other)
    Returns a new Path consisting of the segments of this Path plus the segments of the specified Path.
    int
    Path.compareTo(Path other)
     
    <T> org.klojang.check.extra.Result<T>
    JSONObject.get(Path path)
    Returns a Result object containing the value of the specified path, or Result.notAvailable() if the path is not set.
    JSONObject.in(Path path)
    Returns a JSONObject for the map at the specified path.
    boolean
    JSONObject.isSet(Path path)
    Returns whether the specified path is set to a terminal value (and hence cannot be extended).
    JSONObject.jump(Path path)
    Jumps to another branch in the tree of nested maps.
    JSONObject.set(Path path, Object value)
    Sets the specified path to the specified value.
    JSONObject.unset(Path path)
    Unsets the value of the specified path.