private function addItem()
    {
        $args = func_get_args();
        if (in_array($args[0], self::$appendableTransformations)) {
            $i = $this->findLastTransformation($args[0]);
            if ($i !== false) {
                $this->items[$i]['rendered'] .= ','.implode(':', array_slice($args, 1));

                return $this;
            }
        }
        if ($args[0] != '/' && $this->itemCount && in_array($this->items[$this->itemCount - 1]['type'], self::$forcedLastTransformations)) {
            $lastTransformation = array_pop($this->items);
        }
        $this->items[] = [
            'type' => $args[0],
            'rendered' => implode(':', $args),
        ];
        ++$this->itemCount;
        if (isset($lastTransformation)) {
            $this->items[] = $lastTransformation;
        }

        return $this;
    }
private function addItem()
    {
        $args = func_get_args();
        if (in_array($args[0], self::$appendableTransformations)) {
            $i = $this->findLastTransformation($args[0]);
            if ($i !== false) {
                $this->items[$i]['rendered'] .= ','.implode(':', array_slice($args, 1));

                return $this;
            }
        }
        if ($args[0] != '/' && $this->itemCount && in_array($this->items[$this->itemCount - 1]['type'], self::$forcedLastTransformations)) {
            $lastTransformation = array_pop($this->items);
        }
        $this->items[] = [
            'type' => $args[0],
            'rendered' => implode(':', $args),
        ];
        ++$this->itemCount;
        if (isset($lastTransformation)) {
            $this->items[] = $lastTransformation;
        }

        return $this;
    }
private function addItem ( ) { $ args = func_get_args ( ) ; if ( in_array ( $ args [ 0 ] , self :: $ appendableTransformations ) ) { $ i = $ this -> findLastTransformation ( $ args [ 0 ] ) ; if ( $ i !== false ) { $ this -> items [ $ i ] [ 'rendered' ] .= ',' . implode ( ':' , array_slice ( $ args , 1 ) ) ; return $ this ; } } if ( $ args [ 0 ] != '/' && $ this -> itemCount && in_array ( $ this -> items [ $ this -> itemCount - 1 ] [ 'type' ] , self :: $ forcedLastTransformations ) ) { $ lastTransformation = array_pop ( $ this -> items ) ; } $ this -> items [ ] = [ 'type' => $ args [ 0 ] , 'rendered' => implode ( ':' , $ args ) , ] ; ++ $ this -> itemCount ; if ( isset ( $ lastTransformation ) ) { $ this -> items [ ] = $ lastTransformation ; } return $ this ; }
Adds a new transformation item to the chain.

@return \self
Adds a new transformation item to the chain .