Completed
Push — master ( ec87e5...4069b9 )
by Siro Díaz
02:09
created

TrieTree::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 1 Features 0
Metric Value
dl 0
loc 5
rs 9.4285
c 1
b 1
f 0
cc 1
eloc 4
nc 1
nop 0
1
<?php
2
/**
3
 * DataStructures for PHP
4
 *
5
 * @link      https://github.com/SiroDiaz/DataStructures
6
 * @copyright Copyright (c) 2017 Siro Díaz Palazón
7
 * @license   https://github.com/SiroDiaz/DataStructures/blob/master/README.md (MIT License)
8
 */
9
namespace DataStructures\Trees;
10
11
/**
12
 * TrieTree
13
 *
14
 * The TrieTree class is a trie (also called digital tree and sometimes radix tree or prefix tree)
15
 * that is used to get in O(m) being m the word length.
16
 * It is used in software like word corrector and word suggest.
17
 *
18
 * @author Siro Diaz Palazon <[email protected]>
19
 */
20
class TrieTree {
21
    private $root;
22
    private $numWords;
23
    private $size;
24
25
    public function __construct() {
26
        $this->root = null;
27
        $this->numWords = 0;
28
        $this->size = 0;
29
    }
30
}