Completed
Push — master ( 9e50c3...8e09c0 )
by Michael
12s
created

SmileyNode   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 6
dl 0
loc 20
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A toSyntax() 0 3 1
A __construct() 0 4 1
1
<?php
2
3
namespace dokuwiki\plugin\prosemirror\parser;
4
5
6
class SmileyNode extends Node
7
{
8
9
    protected $parent;
10
    protected $data;
11
12
    public function __construct($data, $parent)
13
    {
14
        $this->parent = &$parent;
15
        $this->data = $data;
16
    }
17
18
    /**
19
     * Get the node's representation as DokuWiki Syntax
20
     *
21
     * @return string
22
     */
23
    public function toSyntax()
24
    {
25
        return $this->data['attrs']['syntax'];
26
    }
27
}
28