<commit_before><?php

namespace helpers;

/**
 * Helps in formatting currency values by catering for the right symbols and
 * their placement against the number.
 */
class CurrencyFormatter {

	/** Currency configuration */
	const currencies = [
		'EUR' => ['symbol' => '€'],
		'PLN' => ['symbol' => 'zł', 'suffix' => true],
	];

	/**
	 * Formats a number for a given currency.
	 *
	 * @param currency The ISO code for the currency to use.
	 * @param number The numeric value to display.
	 * @param decimals How many decimal numbers to include.
	 * @return String with the official currency display, value and symbol.
	 */
	static function moneyFormat($currency, $number, $decimals = 2) {
		return array_key_exists('suffix', self::currencies[$currency])
				&& self::currencies[$currency]['suffix']
			? number_format($number, 2) . self::currencies[$currency]['symbol']
			: self::currencies[$currency]['symbol'] . ' ' . number_format($number, $decimals);
	}

	/**
	 * Retrieves the custom symbol for a currency.
	 *
	 * @param currency ISO currency code.
	 * @return Sumbol for the currency.
	 */
	static function getSymbol($currency) {
		return self::currencies[$currency]['symbol'];
	}

}<commit_msg>Changing currencies from const to private, static field<commit_after><?php

namespace helpers;

/**
 * Helps in formatting currency values by catering for the right symbols and
 * their placement against the number.
 */
class CurrencyFormatter {

	/** Currency configuration */
	private static $currencies = [
		'EUR' => ['symbol' => '€'],
		'PLN' => ['symbol' => 'zł', 'suffix' => true],
	];

	/**
	 * Formats a number for a given currency.
	 *
	 * @param currency The ISO code for the currency to use.
	 * @param number The numeric value to display.
	 * @param decimals How many decimal numbers to include.
	 * @return String with the official currency display, value and symbol.
	 */
	static function moneyFormat($currency, $number, $decimals = 2) {
		return array_key_exists('suffix', self::$currencies[$currency])
				&& self::$currencies[$currency]['suffix']
			? number_format($number, 2) . self::$currencies[$currency]['symbol']
			: self::$currencies[$currency]['symbol'] . ' ' . number_format($number, $decimals);
	}

	/**
	 * Retrieves the custom symbol for a currency.
	 *
	 * @param currency ISO currency code.
	 * @return Sumbol for the currency.
	 */
	static function getSymbol($currency) {
		return self::$currencies[$currency]['symbol'];
	}

}
{'fraction_non_alphanumeric': 0.14332115306536744, 'fraction_numerical': 0.0016240357287860333, 'mean_word_length': 4.122661122661123, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5374591', 'n_tokens_mistral': 774, 'n_tokens_neox': 694, 'n_words': 236}