1
0
Fork 1
mirror of https://github.com/thatmattlove/hyperglass.git synced 2026-01-17 08:48:05 +00:00
thatmattlove-hyperglass/hyperglass/plugins/_output.py
2021-09-12 15:06:34 -07:00

22 lines
619 B
Python

"""Device output plugins."""
# Standard Library
from typing import TYPE_CHECKING, Union
# Local
from ._base import HyperglassPlugin
if TYPE_CHECKING:
# Project
from hyperglass.models.config.devices import Device
from hyperglass.models.parsing.serialized import ParsedRoutes
OutputPluginReturn = Union[None, "ParsedRoutes", str]
class OutputPlugin(HyperglassPlugin):
"""Plugin to interact with device command output."""
def process(self, output: Union["ParsedRoutes", str], device: "Device") -> OutputPluginReturn:
"""Process or manipulate output from a device."""
return None