<?php
    /**
     * ./modules/WBL/ArticleData/UtilsFile.php
     * @author     blange <code@wbl-konzept.de>
     * @category   modules
     * @package    WBL_ArticleData
     * @version    $id$
     */

    /**
     * Adds more images.
     * @author     blange <code@wbl-konzept.de>
     * @category   modules
     * @package    WBL_ArticleData
     * @version    $id$
     */
    class WBL_ArticleData_UtilsFile extends WBL_ArticleData_UtilsFile_parent {
        /**
         * Construct.
         */
        public function __construct()
        {
            parent::__construct();

            $this->_changeSettingsWithConfig();
        } // function

        /**
         * Adds more types with the config.
         * @return WBL_ArticleData_UtilsFile
         */
        public function _changeSettingsWithConfig()
        {
            for ($iRound = 1; $iRound < $this->_iMaxPicImgCount; ++$iRound) {
                if (!isset($this->_aTypeToPath['M' . $iRound])) {
                    $this->_aTypeToPath['M' . $iRound] = 'master/product/' . $iRound;
                } // if

                if (!isset($this->_aTypeToPath['P' . $iRound])) {
                    $this->_aTypeToPath['P' . $iRound] = $iRound;
                } // if
            } // for

            for ($iRound = 1; $iRound < $this->_iMaxZoomImgCount; ++$iRound) {
                if (!isset($this->_aTypeToPath['Z' . $iRound])) {
                    $this->_aTypeToPath['Z' . $iRound] = 'z' . $iRound;
                } // if
            } // for

            return $this;
        } // function
    } // class