Completed
Push — master ( 7f9222...2c377d )
by Jan-Petter
03:31
created

NoSnippet::getMeaning()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %
Metric Value
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
namespace vipnytt\XRobotsTagParser\Directives;
3
4
/**
5
 * Class NoSnippet
6
 *
7
 * @package vipnytt\XRobotsTagParser\Directives
8
 */
9
final class NoSnippet implements DirectiveInterface
10
{
11
    const DIRECTIVE = 'nosnippet';
12
    const MEANING = 'Do not show a snippet in the search results for this page.';
13
14
    /**
15
     * Constructor
16
     *
17
     * @param string $rule
18
     */
19
    public function __construct($rule)
20
    {
21
22
    }
23
24
    /**
25
     * Get directive name
26
     *
27
     * @return string
28
     */
29
    public function getDirective()
30
    {
31
        return self::DIRECTIVE;
32
    }
33
34
    /**
35
     * Get value
36
     *
37
     * @return bool|string|null
38
     */
39
    public function getValue()
40
    {
41
        return true;
42
    }
43
44
    /**
45
     * Get directive meaning
46
     *
47
     * @return string
48
     */
49
    public function getMeaning()
50
    {
51
        return self::MEANING;
52
    }
53
}
54