Passed
Branch master (c7ca4c)
by Tim
16:17 queued 14:33
created

IDValue   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 3
c 1
b 0
f 0
dl 0
loc 14
rs 10
wmc 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace SimpleSAML\XML\Type;
6
7
use SimpleSAML\XML\Attribute;
8
use SimpleSAML\XML\Constants as C;
9
use SimpleSAML\XMLSchema\Type\IDValue as BaseIDValue;
10
use SimpleSAML\XMLSchema\Type\Interface\AttributeTypeInterface;
11
12
/**
13
 * @package simplesaml/xml-common
14
 */
15
class IDValue extends BaseIDValue implements AttributeTypeInterface
16
{
17
    public const string SCHEMA_TYPE = 'xs:ID';
0 ignored issues
show
Bug introduced by
A parse error occurred: Syntax error, unexpected T_STRING, expecting '=' on line 17 at column 24
Loading history...
18
19
20
    /**
21
     * Convert this value to an attribute
22
     *
23
     * @return \SimpleSAML\XML\Attribute
24
     */
25
    public function toAttribute(): Attribute
26
    {
27
        return new Attribute(C::NS_XML, 'xml', 'id', $this);
28
    }
29
}
30