JCBC-241: Refactoring Paginator

This changeset represents a complete refactoring of the Paginator
class, while keeping the old API the same.

Some of the changes included:

  - Only use one query against the Cluster.
  - It now works against reduced views as well.
  - Improved documentation.
  - Various other smaller bugfixes.

The PaginatorTest class has been extended to test against reduced
views as well (the old test have not been modified on order to
ensure backwards compatibility).

Change-Id: I50e9030c1c1efa46f5f65ca45d1c4945eeb78254
Reviewed-on: http://review.couchbase.org/25229
Reviewed-by: Michael Nitschinger <michael.nitschinger@couchbase.com>
Tested-by: Michael Nitschinger <michael.nitschinger@couchbase.com>
JCBC-177: Added code to support single null in view query

Change-Id: If3b1e2cddda8ddad5d1568d96052347311569d41
Reviewed-on: http://review.couchbase.org/25415
Reviewed-by: Michael Nitschinger <michael.nitschinger@couchbase.com>
Tested-by: Deepti Dawar <deepti.dawar@globallogic.com>
JCBC-268: Optimize ReplicateTo.ZERO & PersistTo.ZERO

This changeset optimizes the persistence constraint methods
when both are zero, which basically means do not check at
all. Without this change, added latency is involved because
"observe" is alaways called, even when not necessary.

Change-Id: I8dd6b6226dc797ee066b2113ff7b67f48735baf8
Reviewed-on: http://review.couchbase.org/26182
Reviewed-by: Deepti Dawar <deepti.dawar@globallogic.com>
Reviewed-by: Matt Ingenthron <matt@couchbase.com>
Tested-by: Michael Nitschinger <michael.nitschinger@couchbase.com>
Merge remote-tracking branch 'upstream/master' into queryparams