Completed
Push — master ( e04e71...98392d )
by Jean-Christophe
03:50
created

SemanticHtmlViewsTrait   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 2
Bugs 0 Features 0
Metric Value
wmc 2
c 2
b 0
f 0
lcom 0
cbo 2
dl 0
loc 16
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
addHtmlComponent() 0 1 ?
A htmlCard() 0 3 1
A htmlCardGroups() 0 3 1
1
<?php
2
3
namespace Ajax\semantic\traits;
4
5
use Ajax\semantic\html\views\HtmlCard;
6
use Ajax\semantic\html\views\HtmlCardGroups;
7
8
trait SemanticHtmlViewsTrait {
9
10
	public abstract function addHtmlComponent($htmlComponent);
11
12
	/**
13
	 *
14
	 * @param string $identifier
15
	 */
16
	public function htmlCard($identifier) {
17
		return $this->addHtmlComponent(new HtmlCard($identifier));
18
	}
19
20
	public function htmlCardGroups($identifier, $cards=array()) {
21
		return $this->addHtmlComponent(new HtmlCardGroups($identifier, $cards));
22
	}
23
}