for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace SimpleSAML\CAS\XML;
use DOMElement;
use SimpleSAML\CAS\Assert\Assert;
use SimpleSAML\XMLSchema\Exception\InvalidDOMElementException;
/**
* Class for CAS proxies
*
* @package simplesamlphp/xml-cas
*/
final class Proxies extends AbstractProxies
{
* Convert XML into a Proxies-element
* @param \DOMElement $xml The XML element we should load
* @return static
* @throws \SimpleSAML\XMLSchema\Exception\InvalidDOMElementException
* if the qualified name of the supplied element is wrong
public static function fromXML(DOMElement $xml): static
Assert::same($xml->localName, static::getLocalName(), InvalidDOMElementException::class);
Assert::same($xml->namespaceURI, static::getNamespaceURI(), InvalidDOMElementException::class);
return new static(
Proxy::getChildrenOfClass($xml),
);
}