for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace SimpleSAML\SAML2\XML\md;
use DOMElement;
use SimpleSAML\Assert\Assert;
use SimpleSAML\XML\Exception\InvalidDOMElementException;
use SimpleSAML\XML\Exception\SchemaViolationException;
use SimpleSAML\XML\StringElementTrait;
/**
* Class representing a md:NameIDFormat element.
*
* @package simplesaml/saml2
*/
final class NameIDFormat extends AbstractMdElement
{
use StringElementTrait;
* @param string $content
public function __construct(string $content)
$this->setContent($content);
}
* Validate the content of the element.
* @param string $content The value to go in the XML textContent
* @throws \Exception on failure
* @return void
protected function validateContent(string $content): void
Assert::validURI($content, SchemaViolationException::class); // Covers the empty string