mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-06 06:57:25 +02:00
added abstract factory and factory pattern
This commit is contained in:
24
AbstractFactory/Text.php
Normal file
24
AbstractFactory/Text.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
/**
|
||||
* Created by JetBrains PhpStorm.
|
||||
* User: dominik
|
||||
* Date: 21.08.11
|
||||
* Time: 15:42
|
||||
* To change this template use File | Settings | File Templates.
|
||||
*/
|
||||
|
||||
namespace DesignPatterns\AbstractFactory;
|
||||
|
||||
class Text implements Media
|
||||
{
|
||||
/**
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $_text;
|
||||
|
||||
public function __construct($text)
|
||||
{
|
||||
$this->_text = $text;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user