Add an abstraction to handle dmstats operations, rather than open-coding calls to _get_cmd_output() all over the code.
The operations currently used by dmioscope are:
list
create
delete
report
Provide a DmStats class that when instantiated with a device identifier (name, UUID, maj/min) provides methods to invoke the required operation. Each method should build the appropriate command string, call _get_cmd_output() to obtain the result, and print any necessary message before raising a DmstatsException on error.
Add an abstraction to handle
dmstats
operations, rather than open-coding calls to_get_cmd_output()
all over the code.The operations currently used by
dmioscope
are:Provide a
DmStats
class that when instantiated with a device identifier (name, UUID, maj/min) provides methods to invoke the required operation. Each method should build the appropriate command string, call_get_cmd_output()
to obtain the result, and print any necessary message before raising aDmstatsException
on error.