code: def register(self, obj):
          '''
          register all methods for of an object as json rpc methods
  
          obj - object with methods
          '''
          for method in dir(obj):
              #ignore private methods
              if not method.startswith('_'):
                  fct = getattr(obj, method)
                  #only handle functions
                  try:
                      getattr(fct, '__call__')
                  except AttributeError:
                      pass
                  else:
                      logging.debug('JSONRPC: Found Method: "%s"' % method)
                      self._methods[method] = {
                          'argspec': inspect.getargspec(fct),
                          'fct': fct
                      f register(self, obj):
          '''
          register all methods for of an object as json rpc methods
  
          obj - object with methods
          '''
          for method in dir(obj):
              #ignore private methods
              if not method.startswith('_'):
                  fct = getattr(obj, method)
                  #only handle functions
                  try:
                      getattr(fct, '__call__')
                  except AttributeError:
                      pass
                  else:
                      logging.debug('JSONRPC: Found Method: "%s"' % method)
                      self._methods[method] = {
                          'argspec': inspect.getargspec(fct),
                          'fct': fct
                      }
docs: register all methods for of an object as json rpc methods
  
          obj - object with methods