protected function generateRootRules(array $tagInspectors)
	{
		// Create a proxy for the parent markup so that we can determine which tags are allowed at
		// the root of the text (IOW, with no parent) or even disabled altogether
		$rootInspector = new TemplateInspector('<div><xsl:apply-templates/></div>');
		$rules         = $this->generateRuleset($rootInspector, $tagInspectors);

		// Remove root rules that wouldn't be applied anyway
		unset($rules['autoClose']);
		unset($rules['autoReopen']);
		unset($rules['breakParagraph']);
		unset($rules['closeAncestor']);
		unset($rules['closeParent']);
		unset($rules['fosterParent']);
		unset($rules['ignoreSurroundingWhitespace']);
		unset($rules['isTransparent']);
		unset($rules['requireAncestor']);
		unset($rules['requireParent']);

		return $rules;
	}
protected function generateRootRules(array $tagInspectors)
	{
		// Create a proxy for the parent markup so that we can determine which tags are allowed at
		// the root of the text (IOW, with no parent) or even disabled altogether
		$rootInspector = new TemplateInspector('<div><xsl:apply-templates/></div>');
		$rules         = $this->generateRuleset($rootInspector, $tagInspectors);

		// Remove root rules that wouldn't be applied anyway
		unset($rules['autoClose']);
		unset($rules['autoReopen']);
		unset($rules['breakParagraph']);
		unset($rules['closeAncestor']);
		unset($rules['closeParent']);
		unset($rules['fosterParent']);
		unset($rules['ignoreSurroundingWhitespace']);
		unset($rules['isTransparent']);
		unset($rules['requireAncestor']);
		unset($rules['requireParent']);

		return $rules;
	}
protected function generateRootRules ( array $ tagInspectors ) { // Create a proxy for the parent markup so that we can determine which tags are allowed at // the root of the text (IOW, with no parent) or even disabled altogether $ rootInspector = new TemplateInspector ( '<div><xsl:apply-templates/></div>' ) ; $ rules = $ this -> generateRuleset ( $ rootInspector , $ tagInspectors ) ; // Remove root rules that wouldn't be applied anyway unset ( $ rules [ 'autoClose' ] ) ; unset ( $ rules [ 'autoReopen' ] ) ; unset ( $ rules [ 'breakParagraph' ] ) ; unset ( $ rules [ 'closeAncestor' ] ) ; unset ( $ rules [ 'closeParent' ] ) ; unset ( $ rules [ 'fosterParent' ] ) ; unset ( $ rules [ 'ignoreSurroundingWhitespace' ] ) ; unset ( $ rules [ 'isTransparent' ] ) ; unset ( $ rules [ 'requireAncestor' ] ) ; unset ( $ rules [ 'requireParent' ] ) ; return $ rules ; }
Generate a set of rules to be applied at the root of a document

@param  array $tagInspectors Array of [tagName => TemplateInspector]
@return array
Generate a set of rules to be applied at the root of a document