Issues (281)

src/Definition/MetaAwareInterface.php (1 issue)

1
<?php
2
/*******************************************************************************
3
 *  This file is part of the GraphQL Bundle package.
4
 *
5
 *  (c) YnloUltratech <[email protected]>
6
 *
7
 *  For the full copyright and license information, please view the LICENSE
8
 *  file that was distributed with this source code.
9
 ******************************************************************************/
10
11
namespace Ynlo\GraphQLBundle\Definition;
12
13
/**
14
 * Interface MetaAwareInterface
15
 */
16
interface MetaAwareInterface
17
{
18
    /**
19
     * @return ArgumentDefinition[]
20
     */
21
    public function getMetas(): array;
22
23
    /**
24
     * @param string $key
25
     * @param null   $default
0 ignored issues
show
Documentation Bug introduced by
Are you sure the doc-type for parameter $default is correct as it would always require null to be passed?
Loading history...
26
     *
27
     * @return mixed
28
     */
29
    public function getMeta(string $key, $default = null);
30
31
    /**
32
     * @param string $key
33
     *
34
     * @return boolean
35
     */
36
    public function hasMeta(string $key): bool;
37
38
    /**
39
     * @param string $key
40
     * @param mixed  $value
41
     *
42
     * @return MetaAwareInterface
43
     */
44
    public function setMeta(string $key, $value): MetaAwareInterface;
45
46
    /**
47
     * @param array $metas
48
     *
49
     * @return MetaAwareInterface
50
     */
51
    public function setMetas(array $metas): MetaAwareInterface;
52
53
    /**
54
     * @param string $key
55
     *
56
     * @return MetaAwareInterface
57
     */
58
    public function removeMeta(string $key): MetaAwareInterface;
59
}