Remove CP friend class

.. its a hack, and wasn't really needed

.. also reimplemented getBest() functions since they
   incorreclty assumed that bestsCache would never be NULL