1
0
Fork 0

plugins: create skelet for rfkill base class

This commit is contained in:
Jan Vcelak 2012-05-11 16:12:33 +02:00
parent d91a90a8ad
commit 21e2d51b50

28
tuned/plugins/rfkill.py Normal file
View file

@ -0,0 +1,28 @@
import tuned.plugins
import tuned.log
from tuned.utils.commands import *
log = tuned.log.get()
class RFKillPlugin(tuned.plugins.Plugin):
"""
Base class for plugins which can be enabled/disabled using rfkill.
"""
#
# TODO: ticket #25
#
@classmethod
def _get_default_options(cls):
return {
"disable" : None,
}
@command_set("disable", per_device=True)
def _set_disabled(self, value, device):
log.warn("RF killing is not implemented, ticket #25")
@command_get("disable")
def _get_disabled(self, device):
return False