public function loop()
{
$manual = false;
if (array_key_exists("manual", $this->options) && $this->options["manual"] == true) {
$manual = true;
}
$this->setDefault();
if ($this->current > 0) {
if (!$manual) {
$this->blockDestruct();
$this->blockEnd();
}
} else {
if (!$manual) {
$this->start();
}
}
if ($this->current < count($this->indices) && $this->current < $this->options["limit"]) {
if (!$manual) {
$this->blockConstruct();
$this->blockStart();
}
return true;
} else {
if (!$manual) {
$this->end();
}
return false;
}
}