concrete/src/Csv/Import/CsvSchema.php
public function getAttributesValues(array $cells)
    {
        $result = [];
        foreach ($this->fieldsMap as $cellIndex => $info) {
            switch ($info['kind']) {
                case 'singleAttributeHeader':
                    $attributeIndex = $info['attributeIndex'];
                    $result[$attributeIndex] = isset($cells[$cellIndex]) ? $cells[$cellIndex] : '';
                    break;
                case 'multipleAttributeHeader':
                    $attributeIndex = $info['attributeIndex'];
                    $attributeSubHeader = $info['attributeSubHeader'];
                    $value = isset($cells[$cellIndex]) ? $cells[$cellIndex] : '';
                    if (isset($result[$attributeIndex])) {
                        $result[$attributeIndex][$attributeSubHeader] = $value;
                    } else {
                        $result[$attributeIndex] = [$attributeSubHeader => $value];
                    }
                    break;
            }
        }

        return $result;
    }
public function getAttributesValues(array $cells)
    {
        $result = [];
        foreach ($this->fieldsMap as $cellIndex => $info) {
            switch ($info['kind']) {
                case 'singleAttributeHeader':
                    $attributeIndex = $info['attributeIndex'];
                    $result[$attributeIndex] = isset($cells[$cellIndex]) ? $cells[$cellIndex] : '';
                    break;
                case 'multipleAttributeHeader':
                    $attributeIndex = $info['attributeIndex'];
                    $attributeSubHeader = $info['attributeSubHeader'];
                    $value = isset($cells[$cellIndex]) ? $cells[$cellIndex] : '';
                    if (isset($result[$attributeIndex])) {
                        $result[$attributeIndex][$attributeSubHeader] = $value;
                    } else {
                        $result[$attributeIndex] = [$attributeSubHeader => $value];
                    }
                    break;
            }
        }

        return $result;
    }
public function getAttributesValues ( array $ cells ) { $ result = [ ] ; foreach ( $ this -> fieldsMap as $ cellIndex => $ info ) { switch ( $ info [ 'kind' ] ) { case 'singleAttributeHeader' : $ attributeIndex = $ info [ 'attributeIndex' ] ; $ result [ $ attributeIndex ] = isset ( $ cells [ $ cellIndex ] ) ? $ cells [ $ cellIndex ] : '' ; break ; case 'multipleAttributeHeader' : $ attributeIndex = $ info [ 'attributeIndex' ] ; $ attributeSubHeader = $ info [ 'attributeSubHeader' ] ; $ value = isset ( $ cells [ $ cellIndex ] ) ? $ cells [ $ cellIndex ] : '' ; if ( isset ( $ result [ $ attributeIndex ] ) ) { $ result [ $ attributeIndex ] [ $ attributeSubHeader ] = $ value ; } else { $ result [ $ attributeIndex ] = [ $ attributeSubHeader => $ value ] ; } break ; } } return $ result ; }
Get the values of the cells associated to the attributes.

@param array $cells

@return array keys are the index of the attribute keys, values are the field values.
In case of single-line attributes, values are strings.
In case of multi-column attributes, values are arrays whose keys are the sub-headers and values the strings.
Get the values of the cells associated to the attributes .