for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the bootstrap-bundle package.
*
* (c) 2019 WEBEWEB
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace WBW\Bundle\BootstrapBundle\Alert;
/**
* Abstract alert.
* @author webeweb <https://github.com/webeweb/>
* @package WBW\Bundle\BootstrapBundle\Alert
* @abstract
abstract class AbstractAlert implements AlertInterface {
* Content.
* @var string|null
private $content;
* Dismissible.
* @var bool|null
private $dismissible;
* Type.
private $type;
* Constructor.
* @param string|null type.
protected function __construct(?string $type) {
$this->setType($type);
}
* {@inheritDoc}
public function getContent(): ?string {
return $this->content;
public function getDismissible(): ?bool {
return $this->dismissible;
public function getPrefix(): ?string {
return "alert-";
public function getType(): ?string {
return $this->type;
public function setContent(?string $content): AlertInterface {
$this->content = $content;
return $this;
public function setDismissible(?bool $dismissible): AlertInterface {
$this->dismissible = $dismissible;
public function setType(?string $type): AlertInterface {
$this->type = $type;