flesh out cursor, add inits, totalRecords

This commit is contained in:
Jonathan Guthrie 2016-09-25 00:18:32 -04:00
parent 9b03d8b28c
commit 5fac1dcac0
1 changed files with 17 additions and 3 deletions

View File

@ -8,8 +8,22 @@
import Foundation
struct PerfectCRUDCursor {
var offset: Int = 0
var limit: Int = 0
public struct PerfectCRUDCursor {
public var limit: Int = 50
public var offset: Int = 0
public var totalRecords: Int = 0
public init() {}
public init(limit: Int, offset: Int) {
self.limit = limit
self.offset = offset
}
public init(limit: Int, offset: Int, totalRecords: Int) {
self.limit = limit
self.offset = offset
self.totalRecords = totalRecords
}
}