<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def call(self, method, params, callback=None):
 """Call a method on the server Arguments: method - the remote server method params - an array of commands to send to the method Keyword Arguments: callback - a callback function containing the return data"""

        cur_id = self._next_id()
        if callback:
            self._callbacks[cur_id] = callback
        self.send({'msg': 'method', 'id': cur_id, 'method': method, 'params': params})