Completed
Pull Request — master (#759)
by Mantas
02:31
created

Nested::dump()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 7
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 4
nc 1
nop 1
1
<?php
2
3
/*
4
 * This file is part of the ONGR package.
5
 *
6
 * (c) NFQ Technologies UAB <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace ONGR\ElasticsearchBundle\Annotation;
13
14
/**
15
 * Annotation to mark a class as a nested type during the parsing process.
16
 *
17
 * @Annotation
18
 * @Target("CLASS")
19
 */
20
final class Nested
21
{
22
    const NAME = 'nested';
23
24
    /**
25
     * In this field you can define options.
26
     *
27
     * @var array
28
     */
29
    public $options = [];
30
31
    /**
32
     * {@inheritdoc}
33
     */
34
    public function dump(array $exclude = [])
35
    {
36
        return array_diff_key(
37
            $this->options,
38
            $exclude
39
        );
40
    }
41
}
42