plestylib.solver#

Submodules#

Classes#

ConfigParameter

Represents a single configuration parameter for a device.

CmdSolver

Helper class that provides a standard way to create an ABC using

OpSolver

Helper class that provides a standard way to create an ABC using

Package Contents#

class plestylib.solver.ConfigParameter#

Represents a single configuration parameter for a device.

name: str#
default: Any = None#
value: Any = None#
dtype: type | None = None#
unit: str | None = None#
read_only: bool = False#
write_only: bool = False#
min_value: float | int | None = None#
max_value: float | int | None = None#
options: list[Any] | None = None#
command: str | None = None#
parser: plestylib.device.device_utils.ResponseParser | None = None#
description: str | None = None#
class plestylib.solver.CmdSolver#

Bases: abc.ABC

Helper class that provides a standard way to create an ABC using inheritance.

abstractmethod get_write_cmd(cfg_param: plestylib.device.params.ConfigParameter, value: Any) str | None#
Parameters:
Return type:

str | None

abstractmethod get_query_cmd(cfg_param: plestylib.device.params.ConfigParameter) str | None#
Parameters:

cfg_param (plestylib.device.params.ConfigParameter)

Return type:

str | None

class plestylib.solver.OpSolver#

Bases: abc.ABC

Helper class that provides a standard way to create an ABC using inheritance.

abstractmethod solve_request(request: dict) dict#
Parameters:

request (dict)

Return type:

dict