TrackManiaControl/application/core/FML/Elements/Including.php
Steffen Schröder 5447588749 Huge FML Update
2013-12-31 02:55:41 +01:00

39 lines
597 B
PHP

<?php
namespace FML\Elements;
/**
* Class representing include
*
* @author steeffeen
*/
class Including implements Renderable {
/**
* Protected Properties
*/
protected $url = '';
protected $tagName = 'include';
/**
* Set Url
*
* @param string $url
* Include Url
*/
public function setUrl($url) {
$this->url = $url;
}
/**
*
* @see \FML\Renderable::render()
*/
public function render(\DOMDocument $domDocument) {
$xml = $domDocument->createElement($this->tagName);
if ($this->url) {
$xml->setAttribute('url', $this->url);
}
return $xml;
}
}