Class Ethna_Session

Description

セッションクラス

Located in /class/Session.php (line 20)


	
			
Variable Summary
Method Summary
 Ethna_Session __construct ( $ctl, string $appid, string $save_dir)
 bool destroy ()
 mixed get (string $name)
 string getId ()
 bool isAnonymous ()
 bool isStart ([string $anonymous = false])
 bool isValid ()
 bool regenerateId ([ $lifetime = 0], [ $anonymous = false])
 bool remove (string $name)
 void restore ()
 bool set (string $name, string $value)
 bool start ([int $lifetime = 0], [ $anonymous = false])
Variables
mixed $anonymous = false (line 39)
  • access: protected
mixed $config = array(
'handler' => 'files',
'path' => 'tmp',
'check_remote_addr' => true,
'cache_limiter' => 'nocache',
'cache_expire' => '180',
'suffix' => 'SESSID',
)
(line 42)
  • access: protected
mixed $logger (line 27)
  • access: protected
mixed $session_name (line 30)
  • access: protected
mixed $session_save_dir (line 33)
  • access: protected
mixed $session_start = false (line 36)
  • access: protected
Methods
Constructor __construct (line 60)

Ethna_Sessionクラスのコンストラクタ

  • access: public
Ethna_Session __construct ( $ctl, string $appid, string $save_dir)
  • string $appid: アプリケーションID(セッション名として使用)
  • string $save_dir: セッションデータを保存するディレクトリ
  • $ctl
destroy (line 211)

セッションを破棄する

  • return: true:正常終了 false:エラー
  • access: public
bool destroy ()
get (line 257)

セッション値へのアクセサ(R)

  • return: 取得した値(null:セッションが開始されていない)
  • access: public
mixed get (string $name)
  • string $name: キー
getId (line 135)

セッションIDを取得する

  • return: session id
  • access: public
string getId ()
isAnonymous (line 333)

匿名セッションかどうかを返す

  • return: true:匿名セッション false:非匿名セッション/セッション開始されていない
  • access: public
bool isAnonymous ()
isStart (line 314)

セッションが開始されているかどうかを返す

  • return: true:開始済み false:開始されていない
  • access: public
bool isStart ([string $anonymous = false])
  • string $anonymous: 匿名セッションを「開始」とみなすかどうか(default: false)
isValid (line 146)

セッションの正当性チェック

  • return: true:正当なセッション false:不当なセッション
  • access: public
bool isValid ()
regenerateId (line 230)

セッションIDを再生成する

  • return: true:正常終了 false:エラー
  • access: public
bool regenerateId ([ $lifetime = 0], [ $anonymous = false])
  • $lifetime
  • $anonymous
remove (line 296)

セッションの値を破棄する

  • return: true:正常終了 false:エラー(セッションが開始されていない)
  • access: public
bool remove (string $name)
  • string $name: キー
restore (line 105)

セッションを復帰する

  • access: public
void restore ()
set (line 277)

セッション値へのアクセサ(W)

  • return: true:正常終了 false:エラー(セッションが開始されていない)
  • access: public
bool set (string $name, string $value)
  • string $name: キー
  • string $value: 値
start (line 176)

セッションを開始する

  • return: true:正常終了 false:エラー
  • access: public
bool start ([int $lifetime = 0], [ $anonymous = false])
  • int $lifetime: セッション有効期間(秒単位, 0ならセッションクッキー)
  • $anonymous

Documentation generated on Fri, 11 Nov 2011 03:59:03 +0900 by phpDocumentor 1.4.3