2013-06-03 16:14:46 +02:00
|
|
|
<?php
|
2016-02-08 15:41:00 +01:00
|
|
|
/* Icinga Web 2 | (c) 2013 Icinga Development Team | GPLv2+ */
|
2013-06-03 16:14:46 +02:00
|
|
|
|
|
|
|
namespace Icinga\Exception;
|
|
|
|
|
2013-06-06 16:52:54 +02:00
|
|
|
/**
|
2015-04-07 10:48:37 +02:00
|
|
|
* Exception thrown if a mandatory parameter was not given
|
2013-06-06 16:52:54 +02:00
|
|
|
*/
|
2014-08-25 12:14:18 +02:00
|
|
|
class MissingParameterException extends IcingaException
|
2013-06-03 16:14:46 +02:00
|
|
|
{
|
2015-04-07 12:15:15 +02:00
|
|
|
/**
|
|
|
|
* Name of the missing parameter
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
protected $parameter;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get the name of the missing parameter
|
|
|
|
*
|
|
|
|
* @return string
|
|
|
|
*/
|
|
|
|
public function getParameter()
|
|
|
|
{
|
|
|
|
return $this->parameter;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Set the name of the missing parameter
|
|
|
|
*
|
|
|
|
* @param string $name
|
|
|
|
*
|
|
|
|
* @return $this
|
|
|
|
*/
|
|
|
|
public function setParameter($name)
|
|
|
|
{
|
|
|
|
$this->parameter = (string) $name;
|
|
|
|
return $this;
|
|
|
|
}
|
2013-06-03 16:14:46 +02:00
|
|
|
}
|