mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-06 15:06:31 +02:00
PHP7 NullObject
This commit is contained in:
@@ -2,15 +2,9 @@
|
||||
|
||||
namespace DesignPatterns\Behavioral\NullObject;
|
||||
|
||||
/**
|
||||
* PrintLogger is a logger that prints the log entry to standard output.
|
||||
*/
|
||||
class PrintLogger implements LoggerInterface
|
||||
{
|
||||
/**
|
||||
* @param string $str
|
||||
*/
|
||||
public function log($str)
|
||||
public function log(string $str)
|
||||
{
|
||||
echo $str;
|
||||
}
|
||||
|
Reference in New Issue
Block a user