Class TreeNavigator<M extends Map<String,​Object>,​L extends List<Object>>

  • Direct Known Subclasses:
    JSONNavigator

    public class TreeNavigator<M extends Map<String,​Object>,​L extends List<Object>>
    extends Object
    Navigates only the branches of a JSONObject corresponding to the paths specified.

    For each specified path to navigate, the TreeNavigator only traverses the matching branch.

    The navigator accepts an action and provides callback hooks for it to act on the traversed nodes at each significant step. See NavigateAction.

    See package-info for more details

    Example:

    To navigate the branch k1.k2 of the object {"k1":{"k2":"v1"}, "k3":{"k4":"v2"}} instantiate the navigator like so: new JSONNavigator("k1.k2")

    Since:
    15 June 2016.
    Author:
    adoneitan@gmail.com