Completed
Push — master ( e9bdcb...b0560a )
by Jean-Christophe
04:52
created

TableElementTrait::setPositive()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace Ajax\semantic\html\base\traits;
4
5
use Ajax\semantic\html\base\constants\State;
6
7
trait TableElementTrait {
8
9
	public abstract function addState($state);
10
11
	public function setPositive() {
12
		return $this->addState(State::POSITIVE);
13
	}
14
15
	public function setNegative() {
16
		return $this->addState(State::NEGATIVE);
17
	}
18
19
	public function setWarning() {
20
		return $this->addState(State::WARNING);
21
	}
22
23
	public function setError() {
24
		return $this->addState(State::ERROR);
25
	}
26
27
	public function setDisabled() {
28
		return $this->addState(State::DISABLED);
29
	}
30
}