Allow SnmpQuery to optionally abort walks if one fails (#14255)

* Allow SnmpQuery to optionally abort walks if one fails

* style

* remove baseline
This commit is contained in:
Tony Murray
2022-08-28 19:47:20 -05:00
committed by GitHub
parent 969159f77a
commit 08c4d7f3b3
4 changed files with 79 additions and 22 deletions

View File

@@ -58,6 +58,12 @@ interface SnmpQueryInterface
*/
public function mibDir(?string $dir): SnmpQueryInterface;
/**
* When walking multiple OIDs, stop if one fails. Used when the first OID indicates if the rest are supported.
* OIDs will be walked in order, so you may want to put your OIDs in a specific order.
*/
public function abortOnFailure(): SnmpQueryInterface;
/**
* Do not error on out of order indexes.
* Use with caution as we could get stuck in an infinite loop.