After an insert, shift all nodes down using the base index.

@param \Titon\Event\Event $event
@param int|int[] $id
@Param int $count
174369
public function postSave(Event $event, $id, $count) {
        if (!$this->getConfig('onSave') || !$this->_saveIndex) {
            return;
        }

        $this->_insertNode($id, $this->_saveIndex);
        $this->_saveIndex = null;
    }
415254
public function limit($sql, $count, $offset = 0)
    {
       $this->_connect();
       return $this->_serverType->limit($sql, $count, $offset);
    }
1179586
public function onSectionDelete($id, $table = '')
    {
        if (count($this->dbTable($table)))
        {
            $this->dbDelete($table, $id, 'section');
        }
    }
650563
public void insertNodeAfter(Node insert, Node after, double split) {
        addChild(insert, children.indexOf(after) + 1, split);
        notifyStateChange();
    }
1267752
public function endListValues($tableName, $count = 0)
    {
        if ($this->dumpSettings['disable-keys']) {
            $this->compressManager->write(
                $this->typeAdapter->end_add_disable_keys($tableName)
            );
        }

        if ($this->dumpSettings['add-locks']) {
            $this->compressManager->write(
                $this->typeAdapter->end_add_lock_table($tableName)
            );
        }

        if ($this->dumpSettings['single-transaction']) {
            $this->dbHandler->exec($this->typeAdapter->commit_transaction());
        }

        if ($this->dumpSettings['lock-tables']) {
            $this->typeAdapter->unlock_table($tableName);
        }

        // Commit to enable autocommit
        if ($this->dumpSettings['no-autocommit']) {
            $this->compressManager->write(
                $this->typeAdapter->end_disable_autocommit()
            );
        }

        $this->compressManager->write(PHP_EOL);

        if (!$this->dumpSettings['skip-comments']) {
            $this->compressManager->write(
                "-- Dumped table `".$tableName."` with $count row(s)".PHP_EOL.
                '--'.PHP_EOL.PHP_EOL
            );
        }

        return;
    }
843442
protected function loadQueue($eventname, $count)
    {
        $queueEvent = new LoadQueueEvent();
        $queueEvent->setKind($eventname);
        $queueEvent->setCount($count);
        $this->dispatcher->dispatch($queueEvent::NAME, $queueEvent);
        return $queueEvent->getEvents();
    }
168022
protected function withDebugTriggerCount(int $debugId, int $count)
	{
		$this->debugCount[$debugId]['trigger'] = $count;
		
		return $this;
	}
1296852
public function getListeners($id, $event)
    {
        $this->addConfigListeners($id, $event);
        return parent::getListeners($id, $event);
    }
558218
protected static function arrayRemoveFirst(Array $array, Int $count = 1) : Array
    {
        for( $i = 0; $i < $count; $i++ )
        {
            array_shift($array);
        }

        return $array;
    }
459459
public function addRow($id, $cells = array(), $replace = false)
    {
        $returnValue = (bool) false;

        
		if(!$replace && isset($this->rows[$id])){
			throw new common_Exception('the row with the id '.$id.' already exists');
		}else{
			$this->rows[$id] = $cells;
			//@TODO: implement a sort funciton?

			$returnValue = true;
		}
        

        return (bool) $returnValue;
    }
469413
public function limit($sql, $count, $offset = 0)
    {
        $count = intval($count);
        if ($count <= 0) {
            /**
             * @see Zend_Db_Adapter_Mysqli_Exception
             */
            // require_once 'Zend/Db/Adapter/Mysqli/Exception.php';
            throw new Zend_Db_Adapter_Mysqli_Exception("LIMIT argument count=$count is not valid");
        }

        $offset = intval($offset);
        if ($offset < 0) {
            /**
             * @see Zend_Db_Adapter_Mysqli_Exception
             */
            // require_once 'Zend/Db/Adapter/Mysqli/Exception.php';
            throw new Zend_Db_Adapter_Mysqli_Exception("LIMIT argument offset=$offset is not valid");
        }

        $sql .= " LIMIT $count";
        if ($offset > 0) {
            $sql .= " OFFSET $offset";
        }

        return $sql;
    }
1277048
public function setCount( $count )
	{
		if ( $count == $this->getCount() ) { return; }

		$this->_values['count'] = (string) $count;
		$this->setModified();
	}
443624
public function incrementPosition($count = 1)
    {
        if ($this->isNotInList()) return $this;

        $this->setListifyPosition($this->getListifyPosition() + $count);

        return $this;
    }
185008
public function shuffleProfileUpdates($id, $count = null, $utc = false)
    {
        $payload = $this->buildShuffleProfileUpdatesPayload($count, $utc);

        return $this->send($this->getHttp()->post($this->url.'profiles/'.$id.'/updates/shuffle.json', null, $payload));
    }
178508
public function afterCreate(PersistenceEvent $event) {
    if ($event->getAction() == PersistenceAction::CREATE) {
      $oldOid = $event->getOldOid();
      $oldOidStr = $oldOid != null ? $oldOid->__toString() : null;
      if ($oldOidStr != null && isset($this->createdTranslations[$oldOidStr])) {
        foreach ($this->createdTranslations[$oldOidStr] as $translation) {
          $translation->setValue('objectid', $event->getObject()->getOID()->__toString());
        }
      }
    }
  }
385105
public function decrementCount($tag, $count)
	{
		if($count <= 0) { return; }

		$tag->count = $tag->count - $count;
		if($tag->count < 0) {
			$tag->count = 0;
			$model = $this->tagModelString();
			\Log::warning("The '.$model.' count for `$tag->name` was a negative number. This probably means your data got corrupted. Please assess your code and report an issue if you find one.");
		}
		$tag->save();
	}
449852
public function deleteDependents(Event $event, $ids, $count) {
        $pfk = $this->getPrimaryForeignKey();

        $this->getJunctionRepository()->deleteMany(function(Query $query) use ($pfk, $ids) {
            $query->where($pfk, $ids);
        });
    }