PHP Class Cml\Session

Show file Open project: linhecheng/cmlphp Class Usage Examples

Public Methods

Method Description
close ( ) : boolean session close
destroy ( string $sessionId ) : boolean session 销毁
gc ( integer $lifeTime ) : boolean session gc回收
init ( ) 初始化
open ( string $savePath, string $sessionName ) : boolean session open
read ( string $sessionId ) : array | null session读取
write ( string $sessionId, string $value ) : boolean session 写入

Method Details

close() public method

session close
public close ( ) : boolean
return boolean

destroy() public method

session 销毁
public destroy ( string $sessionId ) : boolean
$sessionId string
return boolean

gc() public method

session gc回收
public gc ( integer $lifeTime ) : boolean
$lifeTime integer
return boolean

init() public static method

初始化
public static init ( )

open() public method

session open
public open ( string $savePath, string $sessionName ) : boolean
$savePath string
$sessionName string
return boolean

read() public method

session读取
public read ( string $sessionId ) : array | null
$sessionId string
return array | null

write() public method

session 写入
public write ( string $sessionId, string $value ) : boolean
$sessionId string
$value string
return boolean