src/Config/Writer/SphinxConf.php
protected function getSectionConfig(Config $config, $section)
    {
        $string = '';
        if (isset($config[$section])) {
            /** @var Config $config */
            $config = $config[$section];
            // If there is at least one section
            if ($config->count() > 0) {
                /** @var Config $values */
                foreach ($config as $name => $values) {
                    if ($values->count() > 0) {
                        $string .= $this->sections[$section] . ' ' . $name . PHP_EOL . '{' . PHP_EOL . "\t";
                        $string .= $this->getValuesString($values->toArray());
                        $string .= PHP_EOL . '}' . PHP_EOL;
                    }
                }
            }
        }
        return $string;
    }
protected function getSectionConfig(Config $config, $section)
    {
        $string = '';
        if (isset($config[$section])) {
            /** @var Config $config */
            $config = $config[$section];
            // If there is at least one section
            if ($config->count() > 0) {
                /** @var Config $values */
                foreach ($config as $name => $values) {
                    if ($values->count() > 0) {
                        $string .= $this->sections[$section] . ' ' . $name . PHP_EOL . '{' . PHP_EOL . "\t";
                        $string .= $this->getValuesString($values->toArray());
                        $string .= PHP_EOL . '}' . PHP_EOL;
                    }
                }
            }
        }
        return $string;
    }
protected function getSectionConfig ( Config $ config , $ section ) { $ string = '' ; if ( isset ( $ config [ $ section ] ) ) { /** @var Config $config */ $ config = $ config [ $ section ] ; // If there is at least one section if ( $ config -> count ( ) > 0 ) { /** @var Config $values */ foreach ( $ config as $ name => $ values ) { if ( $ values -> count ( ) > 0 ) { $ string .= $ this -> sections [ $ section ] . ' ' . $ name . PHP_EOL . '{' . PHP_EOL . "\t" ; $ string .= $ this -> getValuesString ( $ values -> toArray ( ) ) ; $ string .= PHP_EOL . '}' . PHP_EOL ; } } } } return $ string ; }
Creates the config parts of the specified section

@param Config $config
@param $section
@return string
Creates the config parts of the specified section