diff --git a/core/src/main/kotlin/com/insanusmokrassar/postssystem/core/utils/pagination/Pagination.kt b/core/src/main/kotlin/com/insanusmokrassar/postssystem/core/utils/pagination/Pagination.kt index 6f419c4d..5e97a362 100644 --- a/core/src/main/kotlin/com/insanusmokrassar/postssystem/core/utils/pagination/Pagination.kt +++ b/core/src/main/kotlin/com/insanusmokrassar/postssystem/core/utils/pagination/Pagination.kt @@ -1,6 +1,20 @@ package com.insanusmokrassar.postssystem.core.utils.pagination +/** + * Base interface of pagination + * + * If you want to request something, you should use [SimplePagination]. If you need to return some result including + * pagination - [PaginationResult] + */ interface Pagination { + /** + * Started with 0. + * Number of page inside of pagination. Offset can be calculated as [page] * [size] + */ val page: Int + /** + * Can be 0, but can't be < 0 + * Size of current page. Offset can be calculated as [page] * [size] + */ val size: Int } \ No newline at end of file