1 from PLC.Method import Method
2 from PLC.Auth import Auth
3 from PLC.Faults import *
4 from PLC.Parameter import Parameter
6 class GetLeaseGranularity(Method):
8 Returns the granularity in seconds for the reservation system
11 roles = ['admin', 'pi', 'user', 'tech', 'node', 'anonymous']
17 # for now only return /etc/myplc-release verbatim
18 returns = Parameter (int, "the granularity in seconds for the reservation system")
22 return self.api.config.PLC_RESERVATION_GRANULARITY