X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=application%2Fhub%2Fmain%2Fcruncher%2Fclass_BaseHubCruncher.php;h=cbaa0e3ad861cf9da09991d6132a1a24ce960d51;hb=742af702fef26fa6eed5e7deff237d95a84abf10;hp=5e09d9e385d4ceccd9d1c674651a778b4f827288;hpb=0238d7ac079b405bcce4546880d662a9906f2be8;p=hub.git diff --git a/application/hub/main/cruncher/class_BaseHubCruncher.php b/application/hub/main/cruncher/class_BaseHubCruncher.php index 5e09d9e38..cbaa0e3ad 100644 --- a/application/hub/main/cruncher/class_BaseHubCruncher.php +++ b/application/hub/main/cruncher/class_BaseHubCruncher.php @@ -21,7 +21,7 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -class BaseHubCruncher extends BaseHubSystem implements Updateable { +abstract class BaseHubCruncher extends BaseHubSystem implements Updateable { /** * Version information */ @@ -81,6 +81,27 @@ class BaseHubCruncher extends BaseHubSystem implements Updateable { return $isFilled; } + /** + * This method fills the in-buffer with (a) test unit(s) which are mainly + * used for development of the crunching part. They must be enabled in + * configuration, or else your cruncher runs out of WUs and waits for more + * to show up. + * + * In this method we already know that the in-buffer is going depleted so + * we don't need to double-check it here. + * + * @return void + */ + abstract protected function fillInBufferQueueWithTestUnits (); + + /** + * This method fills the in-buffer with (real) WUs which will be crunched + * and the result be sent back to the key producer instance. + * + * @return void + */ + abstract protected function fillInBufferQueueWithWorkUnits (); + /** * Enables/disables the cruncher (just sets a flag) *