Skip to content
Snippets Groups Projects
Commit 202313a0 authored by Christopher R. Johnson's avatar Christopher R. Johnson Committed by CQ bot account: commit-bot@chromium.org
Browse files

[iquery] Refactor iquery to use new reader interface

This change replaces iquery's manual traversal code with the new
inspect/reader.h interface.

To simplify iquery path handling and to make parts of the path more
clear, this change also introduces a delimiter between the file part and
inspect part of a particular path.

Consider the inspect tree:
objects:
 table-0x0:
  row-0x1:
 table-0x2:

Previously we would write:
$ iquery --ls --full_paths objects/table-0x0
objects/table-0x0/row-0x1

Now we write:
$ iquery --ls --full_paths objects#table-0x0
objects#table-0x0/row-0x1

The delimiter '#' separates the file part of the path from the inspect
part, which makes the meaning more clear ("open inspect at this
location, then traverse to this child" vs. "expect to find an inspect
endpoint along this path and once that is open continue traversing to
the proper location").

CF-218: #progress

Change-Id: I31df97351aca4e3df5f53df4aa842c7207c2e18d
parent 917bcd9f
No related branches found
No related tags found
Loading
Showing
with 547 additions and 529 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment