<commit_before><?php
declare(ENCODING = 'utf-8');
namespace F3::Beer3::Core::SyntaxTree;

/*                                                                        *
 * This script is part of the TYPO3 project - inspiring people to share!  *
 *                                                                        *
 * TYPO3 is free software; you can redistribute it and/or modify it under *
 * the terms of the GNU General Public License version 2 as published by  *
 * the Free Software Foundation.                                          *
 *                                                                        *
 * This script is distributed in the hope that it will be useful, but     *
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHAN-    *
 * TABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General      *
 * Public License for more details.                                       *
 *                                                                        */

/**
 * @package Beer3
 * @subpackage Core
 * @version $Id:$
 */
/**
 * Text Syntax Tree Node - is a container for strings.
 *
 * @package Beer3
 * @subpackage Core
 * @version $Id:$
 * @license http://opensource.org/licenses/gpl-license.php GNU Public License, version 2
 * @scope prototype
 */
class TextNode extends F3::Beer3::Core::SyntaxTree::AbstractNode {
	
	/**
	 * Contents of the text node
	 * @var string
	 */
	protected $text;
	
	/**
	 * Constructor.
	 * 
	 * @param string $text text to store in this textNode
	 * @author <NAME> <<EMAIL>>
	 */
	public function __construct($text) {
		if (!is_string($text)) throw new F3::Beer3::Core::ParsingException('Text node requires an argument of type string, "' . gettype($text) . '" given.');
		$this->text = $text;
	}
	
	/**
	 * Return the text associated to the syntax tree.
	 * 
	 * @param F3::Beer3::Core::VariableContainer $variableContainer Variable Container where all variables are stored in
	 * @return string the text stored in this node.
	 * @author <NAME> <<EMAIL>>
	 */
	public function evaluate(F3::Beer3::Core::VariableContainer $variableContainer) {
		return $this->text;
	}
}


?><commit_msg>Beer3: * Committing a fix for javascript... but it is not really nice Original-Commit-Hash: fd467d6ee090fea777a99cf4de0c5dd74ec57a26<commit_after><?php
declare(ENCODING = 'utf-8');
namespace F3::Beer3::Core::SyntaxTree;

/*                                                                        *
 * This script is part of the TYPO3 project - inspiring people to share!  *
 *                                                                        *
 * TYPO3 is free software; you can redistribute it and/or modify it under *
 * the terms of the GNU General Public License version 2 as published by  *
 * the Free Software Foundation.                                          *
 *                                                                        *
 * This script is distributed in the hope that it will be useful, but     *
 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHAN-    *
 * TABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General      *
 * Public License for more details.                                       *
 *                                                                        */

/**
 * @package Beer3
 * @subpackage Core
 * @version $Id:$
 */
/**
 * Text Syntax Tree Node - is a container for strings.
 *
 * @package Beer3
 * @subpackage Core
 * @version $Id:$
 * @license http://opensource.org/licenses/gpl-license.php GNU Public License, version 2
 * @scope prototype
 */
class TextNode extends F3::Beer3::Core::SyntaxTree::AbstractNode {
	
	/**
	 * Contents of the text node
	 * @var string
	 */
	protected $text;
	
	/**
	 * Constructor.
	 * 
	 * @param string $text text to store in this textNode
	 * @author <NAME> <<EMAIL>>
	 */
	public function __construct($text) {
		if (!is_string($text)) throw new F3::Beer3::Core::ParsingException('Text node requires an argument of type string, "' . gettype($text) . '" given.');
		$this->text = $text;
	}
	
	/**
	 * Return the text associated to the syntax tree.
	 * 
	 * @param F3::Beer3::Core::VariableContainer $variableContainer Variable Container where all variables are stored in
	 * @return string the text stored in this node.
	 * @author <NAME> <<EMAIL>>
	 */
	public function evaluate(F3::Beer3::Core::VariableContainer $variableContainer) {
		return str_replace('\{', '{', $this->text);
		// TODO: THIS IS A QUICK AND REALLY DIRTY FIX!!!!!!!
	}
}


?>
{'fraction_non_alphanumeric': 0.10485651214128035, 'fraction_numerical': 0.012362030905077263, 'mean_word_length': 1.9288946347769877, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 21, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 28, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5710926', 'n_tokens_mistral': 1215, 'n_tokens_neox': 1125, 'n_words': 415}