| Conditions | 1 |
| Total Lines | 28 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | from .query import Query |
||
| 5 | def __init__(self, collection, |
||
| 6 | find: dict = None, |
||
| 7 | offset: int = 0, |
||
| 8 | size: int = 30, |
||
| 9 | sort: str = None, |
||
| 10 | start: int = 0): |
||
| 11 | """ |
||
| 12 | Args: |
||
| 13 | collection: |
||
| 14 | find (dict): |
||
| 15 | offset (int): |
||
| 16 | size (int): |
||
| 17 | sort (str): |
||
| 18 | start (int): |
||
| 19 | """ |
||
| 20 | |||
| 21 | super().__init__(None) |
||
| 22 | |||
| 23 | # database |
||
| 24 | self.objectify = collection.objectify |
||
| 25 | self.collection = collection.collection |
||
| 26 | |||
| 27 | # parameters |
||
| 28 | self.current = start |
||
| 29 | self.find = find |
||
| 30 | self.offset = offset |
||
| 31 | self.sort = sort |
||
| 32 | self.size = size |
||
| 33 | |||
| 63 |