ohtarr/parser

There is no license information available for the latest version (dev-master) of this package.

PHP7 library to parse device cli to php object

dev-master 2021-05-24 19:29 UTC

This package is auto-updated.

Last update: 2024-12-25 03:13:29 UTC


README

Parsing Library to parse text output from CLI sessions.

Parser designed to be simple to use. Simply feed it specific show commands and it will parse and output usable results.

The "input_data" method takes raw SHOW commands from cisco devices and stores them in the INPUT property. The "update" method triggers any and all parsing and stores results in the "output" property for use.

example use: $cp = new \ohtarr\Parser(); $cp->input_data($SHRUN,"run"); $cp->input_data($SHINT,"interfaces"); $cp->input_data($SHVER,"version"); $cp->input_data($SHINV,"inventory"); //$cp->update(); This is ran automatically when you input_data. print_r($cp->output);