XmlAttribute   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 5
dl 0
loc 13
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace JMS\Serializer\Annotation;
6
7
/**
8
 * @Annotation
9
 * @Target({"PROPERTY", "METHOD","ANNOTATION"})
10
 */
11
#[\Attribute(\Attribute::TARGET_METHOD | \Attribute::TARGET_PROPERTY)]
12
final class XmlAttribute implements SerializerAttribute
13
{
14
    use AnnotationUtilsTrait;
15
16
    /**
17
     * @var string|null
18
     */
19
    public $namespace = null;
20
21
    public function __construct($values = [], ?string $namespace = null)
22
    {
23
        $this->loadAnnotationParameters(get_defined_vars());
24
    }
25
}
26