In this recipe, we’ll make use of a PyEZ framework feature that greatly eases the complexity of calling RPCs and parsing XML result sets with XPath expressions. Tables are used to map data atoms from the XML responses structured returned by RPCs into Python-friendly data structures for easy use and analysis by automation software.
In this case, we’ll use a table and a view in order to inspect the Junos device hardware inventory.