factor out abstract base class EarlySegmentTerminatingCollector

factor out abstract base class EarlySegmentTerminatingCollector and change existing EarlyTerminatingSortingCollector to inherit from it

For https://issues.apache.org/jira/i#browse/LUCENE-5445 ticket and also https://issues.apache.org/jira/i#browse/SOLR-5730 ticket (CommonParams.java comment references EarlySegmentTerminatingCollector class)