protected function format()
    {
        $number = $this->getParameter('number');

        if($number instanceof Meta) {
            $number = $number->getValue();
        }

        if(empty($number) || !is_numeric($number)) {
            return 0;
        }
        $decimals = $this->getParameter('decimals');
        $decimal_sep = $this->getParameter('decimal_separator');
        $thousands_sep = $this->getParameter('thousands_separator');

        return number_format((double)$number, $decimals, $decimal_sep, $thousands_sep);
    }
protected function format()
    {
        $number = $this->getParameter('number');

        if($number instanceof Meta) {
            $number = $number->getValue();
        }

        if(empty($number) || !is_numeric($number)) {
            return 0;
        }
        $decimals = $this->getParameter('decimals');
        $decimal_sep = $this->getParameter('decimal_separator');
        $thousands_sep = $this->getParameter('thousands_separator');

        return number_format((double)$number, $decimals, $decimal_sep, $thousands_sep);
    }
protected function format ( ) { $ number = $ this -> getParameter ( 'number' ) ; if ( $ number instanceof Meta ) { $ number = $ number -> getValue ( ) ; } if ( empty ( $ number ) || ! is_numeric ( $ number ) ) { return 0 ; } $ decimals = $ this -> getParameter ( 'decimals' ) ; $ decimal_sep = $ this -> getParameter ( 'decimal_separator' ) ; $ thousands_sep = $ this -> getParameter ( 'thousands_separator' ) ; return number_format ( ( double ) $ number , $ decimals , $ decimal_sep , $ thousands_sep ) ; }
wrapper for number_format

@return int|string
wrapper for number_format