Total Complexity | 5 |
Total Lines | 51 |
Duplicated Lines | 0 % |
Coverage | 0% |
Changes | 0 |
1 | <?php |
||
23 | class TwitterImageTag extends MetaTag |
||
24 | { |
||
25 | // Constants |
||
26 | // ========================================================================= |
||
27 | |||
28 | const ITEM_TYPE = 'TwitterImageTag'; |
||
29 | |||
30 | // Static Methods |
||
31 | // ========================================================================= |
||
32 | |||
33 | // Public Properties |
||
34 | // ========================================================================= |
||
35 | |||
36 | // Public Methods |
||
37 | // ========================================================================= |
||
38 | |||
39 | /** |
||
40 | * @inheritdoc |
||
41 | */ |
||
42 | public function init() |
||
45 | } |
||
46 | |||
47 | /** |
||
48 | * @inheritdoc |
||
49 | */ |
||
50 | public function rules() |
||
51 | { |
||
52 | $rules = parent::rules(); |
||
53 | $rules = array_merge($rules, [ |
||
54 | // content in this case should be a fully qualified URL |
||
55 | [['content'], UrlValidator::class], |
||
56 | ]); |
||
57 | |||
58 | return $rules; |
||
59 | } |
||
60 | |||
61 | /** |
||
62 | * @inheritdoc |
||
63 | */ |
||
64 | public function prepForRender(&$data): bool |
||
74 | } |
||
75 | } |
||
76 |