phpDocumentor base
[ class tree: base ] [ index: base ] [ all elements ]

Class: WindModule

Source Location: /base/WindModule.php

Class WindModule

Class Overview

所有module的基础抽象类

在module类中基本实现了对组件特性的支持,包括:配置解析,延迟加载,类代理以及提供获取基础对象的方法. 如果需要用组件配置管理方式创建类对象,需要继承该类.支持config路径解析.

Located in /base/WindModule.php [line 14]



		
				Author(s):
		
		
		
Information Tags:
Version:  $Id: WindModule.php 2973 2011-10-15 19:22:48Z yishuo $
Copyright:  ©2003-2103 phpwind.com
License:  http://www.windframework.com

Properties

Methods

[ Top ]
Descendants
Child Class Description
WindErrorMessage 错误消息类
WindDao 提供的DAO的父类
WindDaoFactory Dao工厂
WindSendMail 使用sendmail发送邮件
WindSmtpMail 邮件发送
WindLangResource 语言资源基础实现
WindWebApplication 应用控制器,协调处理用户请求,处理,跳转分发等工作
WindSimpleController 操作控制器,管理用户的请求处理操作.
WindDispatcher 请求分发重定向处理类
WindForward 操作转发类,该类携带了操作转发信息以及后续处理信息给主应用控制器
WindSecurityToken token令牌安全类
AbstractWindCache 缓存策略实现的基类
WindView 视图处理器
AbstractWindViewTemplate 模板编译抽象类定义
WindNormalViewerResolver 通用视图解析渲染
WindLayout 视图布局对象
WindNormalCookie 将cookie作为对象操作
WindSession 会话机制,依赖Cache机制实现,应用可以根据自己的需求配置需要的存储方式实现会话存储
WindConnection 数据库链接,提供了数据库连接服务,以及基本的数据操作方法.
WindGeneralConverter 通用编码转化类
WindHandlerInterceptorChain 拦截链基类
WindHandlerInterceptor 拦截器基类
WindLogger 日志记录

[ Top ]
Property Summary
array   $_config   配置数据
WindClassProxy   $_proxy   代理类对象
boolean   $_typeValidation   是否进行类型验证

[ Top ]
Method Summary
mixed   getConfig()   根据配置名取得相应的配置
WindHttpRequest   getRequest()   返回当前应用的WindHttpRequest对象
WindHttpResponse   getResponse()   返回当前应用的WindHttpResponse对象
WindFactory   getSystemFactory()   返回当前应用的WindFactory对象
void   setConfig()   设置类配置
void   setDelayAttributes()   设置延迟加载类属性相关组件配置信息
array   toArray()   返回该对象的数组类型
array   writeTableCloneProperty()   类对象clone白名单
mixed   __call()   重载了魔术方法__call
void   __clone()   重载魔术方法__clone
mixed   __get()   重载了魔术方法__get
void   __set()   重载了魔术方法__set

[ Top ]
Properties
array   $_config = array() [line 26]

配置数据

API Tags:
Access:  protected


[ Top ]
WindClassProxy   $_proxy = null [line 20]

代理类对象

API Tags:
Access:  public


[ Top ]
boolean   $_typeValidation = false [line 33]

是否进行类型验证

API Tags:
Deprecated:  
Access:  protected


[ Top ]
Methods
getConfig  [line 144]

  mixed getConfig( [string $configName = ''], [string $subConfigName = ''], [string $default = ''], [array $config = array()]  )

根据配置名取得相应的配置

configName为空时则返回整个配置.当配置值不存在时返回默认值.默认值默认为空

Parameters:
string   $configName:  键名
string   $subConfigName:  二级键名
string   $default:  默认值
array   $config:  外部配置

API Tags:
Access:  public


[ Top ]
getRequest  [line 198]

  WindHttpRequest getRequest( )

返回当前应用的WindHttpRequest对象


API Tags:
Access:  protected


Redefined in descendants as:

[ Top ]
getResponse  [line 207]

  WindHttpResponse getResponse( )

返回当前应用的WindHttpResponse对象


API Tags:
Access:  protected


Redefined in descendants as:

[ Top ]
getSystemFactory  [line 189]

  WindFactory getSystemFactory( )

返回当前应用的WindFactory对象


API Tags:
Access:  protected


[ Top ]
setConfig  [line 161]

  void setConfig( string|array $config  )

设置类配置

设置类配置信息,如果配置已经存在,则将以存在配置和输入配置进行合并. 重复配置后者将覆盖前者. 支持配置路径解析,当输入值为配置路径时则会调用配置解析器进行解析并自动缓存当前配置值.(缓存是由wind_config中的isCache配置值决定是否开启)

Parameters:
string|array   $config: 

API Tags:
Access:  public


Redefined in descendants as:

[ Top ]
setDelayAttributes  [line 217]

  void setDelayAttributes( array $delayAttributes  )

设置延迟加载类属性相关组件配置信息

Parameters:
array   $delayAttributes: 

API Tags:
Access:  public


[ Top ]
toArray  [line 123]

  array toArray( )

返回该对象的数组类型


API Tags:
Access:  public


[ Top ]
writeTableCloneProperty  [line 180]

  array writeTableCloneProperty( )

类对象clone白名单

当类对象被clone时,会访问该方法,该方法返回该类中需要被同时clone的类属性名称,默认返回空数组


API Tags:
Access:  protected


[ Top ]
__call  [line 78]

  mixed __call( string $methodName, array $args  )

重载了魔术方法__call

当类的方法访问不到时调用该方法,在这里的实现是配置类属性对象的延迟加载策略

  1.  //延迟访问某个属性,当使用这种方式调用时该方法被调用,并访问该类中的$_delayAttributes属性,并创建该属性对象并返回
  2.  $this->_getMethodName();

Parameters:
string   $methodName: 
array   $args: 

API Tags:
Access:  public


[ Top ]
__clone  [line 111]

  void __clone( )

重载魔术方法__clone

当clone类对象时该方法被调用,通过配置白名单选择是否clone类中的属性对象.


API Tags:
Deprecated:  
Access:  public


[ Top ]
__get  [line 61]

  mixed __get( string $propertyName  )

重载了魔术方法__get

当属性访问不到时该方法被调用,该方法会尝试去访问对应属性的getter并返回对应的值,如果不存在则什么也不做

Parameters:
string   $propertyName: 

API Tags:
Access:  public


[ Top ]
__set  [line 49]

  void __set( string $propertyName, mixed $value  )

重载了魔术方法__set

当属性访问不到时该方法被调用,该方法会尝试去访问对应属性的setter设置器,如果不存在则什么也不做

Parameters:
string   $propertyName: 
mixed   $value: 

API Tags:
Access:  public


[ Top ]

Documentation generated on Fri, 30 Mar 2012 11:43:37 +0800 by phpDocumentor 1.4.4