Collatejson API tuning.

Encode() and Decode() can accept buffer created via,
    make([]byte, 0, capacity)
    make([]byte, capacity)

Change-Id: Iad539f91a9bf68b59b74eddb6cb3b8a396e0a3c3
Reviewed-on: http://review.couchbase.org/43343
Reviewed-by: Deepkaran Salooja <deepkaran.couchbase@gmail.com>
Reviewed-by: Pratap Chakravarthy <prataprc@couchbase.com>
Tested-by: Pratap Chakravarthy <prataprc@couchbase.com>