public function add(Task $task) : void
    {
        $this->index++;
        Util::put($this -> storage().$this->index.'.queue', serialize($task));
        $this -> updateIterator();
        Util::put($this -> storage().'_index', $this -> index);
    }
public function add(Task $task) : void
    {
        $this->index++;
        Util::put($this -> storage().$this->index.'.queue', serialize($task));
        $this -> updateIterator();
        Util::put($this -> storage().'_index', $this -> index);
    }
public function add ( Task $ task ) : void { $ this -> index ++ ; Util :: put ( $ this -> storage ( ) . $ this -> index . '.queue' , serialize ( $ task ) ) ; $ this -> updateIterator ( ) ; Util :: put ( $ this -> storage ( ) . '_index' , $ this -> index ) ; }
Add new task to queue top
@param Task $task
Add new task to queue top