ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
SAML2\XML\md\AdditionalMetadataLocation Class Reference
+ Collaboration diagram for SAML2\XML\md\AdditionalMetadataLocation:

Public Member Functions

 __construct (\DOMElement $xml=null)
 Initialize an AdditionalMetadataLocation element. More...
 
 toXML (\DOMElement $parent)
 Convert this AdditionalMetadataLocation to XML. More...
 

Data Fields

 $namespace
 
 $location
 

Detailed Description

Definition at line 13 of file AdditionalMetadataLocation.php.

Constructor & Destructor Documentation

◆ __construct()

SAML2\XML\md\AdditionalMetadataLocation::__construct ( \DOMElement  $xml = null)

Initialize an AdditionalMetadataLocation element.

Parameters
\DOMElement | null$xmlThe XML element we should load.
Exceptions

Exception

Definition at line 35 of file AdditionalMetadataLocation.php.

36 {
37 if ($xml === null) {
38 return;
39 }
40
41 if (!$xml->hasAttribute('namespace')) {
42 throw new \Exception('Missing namespace attribute on AdditionalMetadataLocation element.');
43 }
44 $this->namespace = $xml->getAttribute('namespace');
45
46 $this->location = $xml->textContent;
47 }
$xml
Definition: metadata.php:240
Interface TriggeredSignal.

References $xml.

Member Function Documentation

◆ toXML()

SAML2\XML\md\AdditionalMetadataLocation::toXML ( \DOMElement  $parent)

Convert this AdditionalMetadataLocation to XML.

Parameters
\DOMElement$parentThe element we should append to.
Returns
\DOMElement This AdditionalMetadataLocation-element.

Definition at line 55 of file AdditionalMetadataLocation.php.

56 {
57 assert(is_string($this->namespace));
58 assert(is_string($this->location));
59
60 $e = Utils::addString($parent, Constants::NS_MD, 'md:AdditionalMetadataLocation', $this->location);
61 $e->setAttribute('namespace', $this->namespace);
62
63 return $e;
64 }
const NS_MD
The namespace for the SAML 2 metadata.
Definition: Constants.php:225
static addString(\DOMElement $parent, $namespace, $name, $value)
Append string element.
Definition: Utils.php:635

References SAML2\Utils\addString(), and SAML2\Constants\NS_MD.

+ Here is the call graph for this function:

Field Documentation

◆ $location

SAML2\XML\md\AdditionalMetadataLocation::$location

Definition at line 27 of file AdditionalMetadataLocation.php.

◆ $namespace

SAML2\XML\md\AdditionalMetadataLocation::$namespace

Definition at line 20 of file AdditionalMetadataLocation.php.


The documentation for this class was generated from the following file: