Method | Description | |
---|---|---|
addTrait ( |
Adds a trait. | |
getTraits ( ) : string[] | Returns a collection of traits | |
hasTrait ( |
Checks whether a trait exists | |
removeTrait ( |
Removes a trait. | |
setTraits ( array $traits ) | Sets a collection of traits |
public getTraits ( ) : string[] | ||
return | string[] |
public removeTrait ( |
||
$trait | trait or qualified name |