<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

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
                    }