src/Jsonq.php
public function transform(callable $fn)
    {
        $this->prepare();

        $new_data = [];
        foreach ($this->_map as $key => $val) {
            $new_data[$key] = $fn($val);
        }

        return $this->prepareResult($new_data, false);
    }
public function transform(callable $fn)
    {
        $this->prepare();

        $new_data = [];
        foreach ($this->_map as $key => $val) {
            $new_data[$key] = $fn($val);
        }

        return $this->prepareResult($new_data, false);
    }
public function transform ( callable $ fn ) { $ this -> prepare ( ) ; $ new_data = [ ] ; foreach ( $ this -> _map as $ key => $ val ) { $ new_data [ $ key ] = $ fn ( $ val ) ; } return $ this -> prepareResult ( $ new_data , false ) ; }
transform prepared data by using callable function

@param callable $fn
@return object|array
@throws ConditionNotAllowedException
transform prepared data by using callable function