ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ArtifactResolve.php
Go to the documentation of this file.
1<?php
2
3namespace SAML2;
4
14{
15 private $artifact;
16
17 public function __construct(\DOMElement $xml = null)
18 {
19 parent::__construct('ArtifactResolve', $xml);
20
21 if (!is_null($xml)) {
22 $results = Utils::xpQuery($xml, './saml_protocol:Artifact');
23 $this->artifact = $results[0]->textContent;
24 }
25 }
26
32 public function getArtifact()
33 {
34 return $this->artifact;
35 }
36
42 public function setArtifact($artifact)
43 {
44 assert(is_string($artifact));
45 $this->artifact = $artifact;
46 }
47
53 public function toUnsignedXML()
54 {
55 $root = parent::toUnsignedXML();
56 $artifactelement = $this->document->createElementNS(Constants::NS_SAMLP, 'Artifact', $this->artifact);
57 $root->appendChild($artifactelement);
58
59 return $root;
60 }
61}
An exception for terminatinating execution or to throw for unit testing.
__construct(\DOMElement $xml=null)
toUnsignedXML()
Convert the response message to an XML element.
setArtifact($artifact)
Set the artifact that should be included in this response.
getArtifact()
Retrieve the Artifact in this response.
$root
Definition: sabredav.php:45
$results
Definition: svg-scanner.php:47