protected function cloneCloseTagElementsOutOfSwitch(DOMDocument $ir)
	{
		$query = '//switch[case/closeTag][not(case[name(*[1]) != "closeTag"])]';
		foreach ($this->query($query) as $switch)
		{
			$case = $this->query('case/closeTag', $switch)->item(0);
			$switch->parentNode->insertBefore($case->cloneNode(), $switch);
		}
	}
protected function cloneCloseTagElementsOutOfSwitch(DOMDocument $ir)
	{
		$query = '//switch[case/closeTag][not(case[name(*[1]) != "closeTag"])]';
		foreach ($this->query($query) as $switch)
		{
			$case = $this->query('case/closeTag', $switch)->item(0);
			$switch->parentNode->insertBefore($case->cloneNode(), $switch);
		}
	}
protected function cloneCloseTagElementsOutOfSwitch ( DOMDocument $ ir ) { $ query = '//switch[case/closeTag][not(case[name(*[1]) != "closeTag"])]' ; foreach ( $ this -> query ( $ query ) as $ switch ) { $ case = $ this -> query ( 'case/closeTag' , $ switch ) -> item ( 0 ) ; $ switch -> parentNode -> insertBefore ( $ case -> cloneNode ( ) , $ switch ) ; } }
Clone closeTag elements from the head of a switch's cases before said switch

If there's a <closeTag/> at the beginning of every <case/>, clone it and insert it
right before the <switch/> unless there's already one

@param  DOMDocument $ir
@return void
Clone closeTag elements from the head of a switch s cases before said switch