Create a new id. Auto incrementing number that avoids conflicts with ids already used. Returns: string, a new unique id.
(self)
| 1395 | return resp, content |
| 1396 | |
| 1397 | def _new_id(self): |
| 1398 | """Create a new id. |
| 1399 | |
| 1400 | Auto incrementing number that avoids conflicts with ids already used. |
| 1401 | |
| 1402 | Returns: |
| 1403 | string, a new unique id. |
| 1404 | """ |
| 1405 | self._last_auto_id += 1 |
| 1406 | while str(self._last_auto_id) in self._requests: |
| 1407 | self._last_auto_id += 1 |
| 1408 | return str(self._last_auto_id) |
| 1409 | |
| 1410 | @util.positional(2) |
| 1411 | def add(self, request, callback=None, request_id=None): |
no outgoing calls