mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-06 15:06:31 +02:00
PHP7 Prototype
This commit is contained in:
@@ -2,9 +2,6 @@
|
||||
|
||||
namespace DesignPatterns\Creational\Prototype;
|
||||
|
||||
/**
|
||||
* class BookPrototype.
|
||||
*/
|
||||
abstract class BookPrototype
|
||||
{
|
||||
/**
|
||||
@@ -17,24 +14,13 @@ abstract class BookPrototype
|
||||
*/
|
||||
protected $category;
|
||||
|
||||
/**
|
||||
* @abstract
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
abstract public function __clone();
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function getTitle()
|
||||
public function getTitle(): string
|
||||
{
|
||||
return $this->title;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $title
|
||||
*/
|
||||
public function setTitle($title)
|
||||
{
|
||||
$this->title = $title;
|
||||
|
Reference in New Issue
Block a user