activity/translator/translator.php
protected function _getOverrides($format, $parameters = array())
    {
        $overrides = array();

        if (!empty($parameters))
        {
            // Get the power set of the set of parameters and construct a list of string overrides from it.
            foreach ($this->_getPowerSet(array_keys($parameters)) as $subset)
            {
                $override = $format;

                foreach ($subset as $key) {
                    $override = str_replace(sprintf('{%s}', $key), $parameters[$key], $override);
                }

                $overrides[] = $override;
            }
        }

        return $overrides;
    }
protected function _getOverrides($format, $parameters = array())
    {
        $overrides = array();

        if (!empty($parameters))
        {
            // Get the power set of the set of parameters and construct a list of string overrides from it.
            foreach ($this->_getPowerSet(array_keys($parameters)) as $subset)
            {
                $override = $format;

                foreach ($subset as $key) {
                    $override = str_replace(sprintf('{%s}', $key), $parameters[$key], $override);
                }

                $overrides[] = $override;
            }
        }

        return $overrides;
    }
protected function _getOverrides ( $ format , $ parameters = array ( ) ) { $ overrides = array ( ) ; if ( ! empty ( $ parameters ) ) { // Get the power set of the set of parameters and construct a list of string overrides from it. foreach ( $ this -> _getPowerSet ( array_keys ( $ parameters ) ) as $ subset ) { $ override = $ format ; foreach ( $ subset as $ key ) { $ override = str_replace ( sprintf ( '{%s}' , $ key ) , $ parameters [ $ key ] , $ override ) ; } $ overrides [ ] = $ override ; } } return $ overrides ; }
Returns a list of activity format overrides.

@param  string $format     The activity format.
@param  array  $parameters Associative array containing parameters.
@return array A list of activity format overrides.
Returns a list of activity format overrides .