Php/docs/class.splsubject

来自菜鸟教程
跳转至:导航、​搜索

(PHP 5 >= 5.1.0, PHP 7)

简介

The SplSubject interface is used alongside SplObserver to implement the Observer Design Pattern.


接口摘要


SplSubject {

/* 方法 */

abstract public attach ( SplObserver $observer ) : void

abstract public detach ( SplObserver $observer ) : void

abstract public notify ( ) : void

}

Table of Contents