u.go
2015-11-08T05:29:01Z

Page.scala

| case class Page[A](items: Seq[A], page: Int, offset: Long, total: Long) {
| lazy val prev = Option(page - 1).filter(_ >= 0)
| lazy val next = Option(page + 1).filter(_ => (offset + items.size) < total)
| }