LPS-47465 Add ServiceTrackerMap interface
LPS-47465 Added empty default implementation

This class will contain the common logic for maintaining the mapping
with the services.
LPS-47465 Use a ServiceTracker from the Registry to track the services.

We need the class to track and a filter to feed the ServiceTracker. We
add a new type parameter S to the class. This is the service the tracker
is going to track, that does not necessarily be the same type that the
map will return.
LPS-47465 Add a ServiceTrackerCustomizer to the ServiceTracker

This customizer will be the responsible to maintain the services in the
map.

The customizer returns the ServiceReference so the ServiceTracker will
track the references and provide the customizer with them. This way we
will use internally the references as handles and keep the services
ourselves to return them to the clients of the API.
LPS-47465 Add Bucket interface and use ConcurentHashMap to store the
buckets.

The buckets are the holders of the services tracked by the map. These
buckets will be responsible for arranging the services when key clashes
occur.
LPS-47465 Obtain the services from the bucket
LPS-47465 add ServiceReferenceMapper interface

Users of ServiceTrackerMap must provice an implementation of
ServiceReferenceMapper in order for the Map to obtain the keys under
which store the services related to a ServiceReference.

The way to provide the keys is invoking Emitter.emit(K key) with each
key under which the service must be stored.

I chose this interface because:

* It allows to provide 0, 1 or N keys for the same object
* It does not force the client of the API to reserve any memory

It is also a common pattern when some logic needs to provide keys for an
object, see:

http://hadooptutorial.wikispaces.com/MapReduce <-- look for
Emit(intermediateKey, intermediateValue);

http://wiki.apache.org/couchdb/Introduction_to_CouchDB_views#Map_Functions

http://docs.cloudant.com/guides/mapreduce.html#map

http://docs.mongodb.org/manual/reference/command/mapReduce/#mapreduce-map-cmd

In our case emit signature only has the key since this is an implementation
bounded to services and ServiceReferences from the Registry.
LPS-47465 Add ServiceTrackerMapBucketFactory

Implementors of this interface will create implementations of
ServiceTrackerMapImpl.Bucket. By providing different implementations we
can configure what the ServiceTrackerMap will return and how the Buckets
will behave (i.e. single service implementation vs servicecollection).
LPS-47465 Allow to pass a ServiceReferenceMapper and a
ServiceTrackerMapBucketfactory.

This will fully parameterize ServiceTrackerMapImpl.
LPS-47465 Implement logic when adding a service

It asks the mapper for the corresponding key and look for a bucket. If a
bucket does not exist we ask the bucket factory for a new one, handling
contention.

Once it has a bucket store the service into it.
LPS-47465 Implement removingService

Find the corresponding bucket asking the mapper. If a bucket is found
ask it to remove the service and check if the bucket can be disposed of.
If so remove it.
LPS-47465 Implement modifiedService by calling removedService and
addingService
LPS-47465 Add the skeleton of SingleItemBucketFactory

This factory returns buckets of type SingleBucket<S, S>.
These buckets return just one service each time Bucket.getContent() is
called.

When more than one service falls into the same bucket the bucket must
keep a queue of services and return the one with the biggest priority.
A comparator must be provided to calculate priorities.
LPS-47465 Added comparator and priority queue
LPS-47465 Keep the service with highest priority available for access
without blocking.
LPS-47465 When a new serviceReference is added to the bucket we toss it
into the priorityQueue and keep the one with the highest priority
LPS-47465 When a serviceReference is removed we delete it from the
queue. Then we check the peek for the next highest priority service.

If there are no more services available we set the content to null
LPS-47465 The bucket is disposable when no elements are left in the
queue.
LPS-47465 Add MultipleItemsBucketFactory.

This factory returns CollectionBuckets. These buckets hold and return a
collection of the services.

In this case the comparator is used to sort the services in the
collection, so they are going to be returned in this order to the
consumer of the API.
LPS-47465 Keep a sorted set with the references using the comparator.

Then we keep a collection (list) that is the one that we are going to
return to the consumers without contention. The class synchronizes the
rest of the operations.