public function Table::setStyle in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony/console/Helper/Table.php \Symfony\Component\Console\Helper\Table::setStyle()
Sets table style.
Parameters
TableStyle|string $name The style name or a TableStyle instance:
Return value
1 call to Table::setStyle()
- Table::__construct in vendor/
symfony/ console/ Helper/ Table.php
File
- vendor/
symfony/ console/ Helper/ Table.php, line 118
Class
- Table
- Provides helpers to display a table.
Namespace
Symfony\Component\Console\HelperCode
public function setStyle($name) {
if ($name instanceof TableStyle) {
$this->style = $name;
}
elseif (isset(self::$styles[$name])) {
$this->style = self::$styles[$name];
}
else {
throw new \InvalidArgumentException(sprintf('Style "%s" is not defined.', $name));
}
return $this;
}