3 require_once 'HTMLPurifier/Strategy.php';
4 require_once 'HTMLPurifier/Config.php';
7 * Composite strategy that runs multiple strategies on tokens.
9 class HTMLPurifier_Strategy_Composite
extends HTMLPurifier_Strategy
13 * List of strategies to run tokens through.
15 var $strategies = array();
17 function HTMLPurifier_Strategy_Composite() {
18 trigger_error('Attempt to instantiate abstract object', E_USER_ERROR
);
21 function execute($tokens, $config, &$context) {
22 foreach ($this->strategies
as $strategy) {
23 $tokens = $strategy->execute($tokens, $config, $context);