Ejemplo n.º 1
0
 def getParams(self, **kwargs):
     found = {}
     for option in kwargs:
         if [l for l in CONFIG_DICT.values() if option in l]:
             section = reverseSearch(CONFIG_DICT, option)
             if section:
                 found[option] = self.settings.value(section[0] + option)
     return found
Ejemplo n.º 2
0
 def loadConfig(self):
     config = {}
     for section, options in CONFIG_DICT.iteritems():
         for option in options:
             config[option] = self.settings.value(section + option)
     # arrange by alphabet
     params = []
     for option in sorted(config):
         params.append(config[option])
     return params
Ejemplo n.º 3
0
 def updateConfig(self, **kwargs):
     for section, options in CONFIG_DICT.iteritems():
         for option in options:
             if option in kwargs:
                 self.settings.setValue(section + option, kwargs[option])