Implement key count estimation via AAE trees

This pull-request adds `hashtree:estimate_keys/1` which can be used to estimate the number of keys in a partition by sampling the segments in the relevant AAE tree.

The estimation is calculated by computing a keys-per-segment estimate and then multiplying that estimate by the total number of segments.

The keys-per-segment estimate is determined by traversing over segments until either 1% of segments have been sampled or 1000 keys have been seen.

This key count estimation is used as part of an improvement to AAE-based fullsync replication.

Sibling pull-requests: basho/riak_kv#1030, basho/riak_repl#623

When segment 0 is read in line 458, the next step is to increment its number and call estimate_keys again in line 459. If at that point the limits have been hit, CurrentSegment is already 1. The only case you will match the condition on 452 with CurrentSegment equals to zero is if Segments is zero, or MaxKeys is zero, or if a silly user starts with Keys set to something that already hits MaxKeys.