def _gen_get_more_command(cursor_id, coll, batch_size, max_await_time_ms):
 cmd = SON([('getMore', cursor_id), ('collection', coll)])
 if batch_size:
  cmd['batchSize'] = batch_size
 if (max_await_time_ms is not None):
  cmd['maxTimeMS'] = max_await_time_ms
 return cmd

def _gen_get_more_command ( cursor_id , coll , batch_size , max_await_time_ms ) : cmd = SON ( [ ( 'getMore' , cursor_id ) , ( 'collection' , coll ) ] ) if batch_size : cmd [ 'batchSize' ] = batch_size if ( max_await_time_ms is not None ) : cmd [ 'maxTimeMS' ] = max_await_time_ms return cmd
generate a getmore command document .