摘要:
阅读全文
摘要:
<?php //观察者模式 class User implements SplSubject{ public $lognum; public $hobby; protected $observers = null; public function __construct($hobby){ $this 阅读全文
摘要:
//单例模式 class sigle{ private static $ins = null; public static function getIns(){ if(self::$ins === null){ self::$ins = new self(); } return s... 阅读全文