summaryrefslogtreecommitdiff
path: root/framework/Security
diff options
context:
space:
mode:
authorxue <>2007-03-25 02:38:40 +0000
committerxue <>2007-03-25 02:38:40 +0000
commitcbee2945d1858f7f256b44a3fbfe816dc0202f4d (patch)
tree2c26aed127666909925812085e801857004846fe /framework/Security
parent0ecff0ea662177835b4e641d70af77ec3270a2e5 (diff)
added StateChanged property to TUser.
Diffstat (limited to 'framework/Security')
-rw-r--r--framework/Security/TUser.php21
1 files changed, 21 insertions, 0 deletions
diff --git a/framework/Security/TUser.php b/framework/Security/TUser.php
index 7ed76c04..5077114b 100644
--- a/framework/Security/TUser.php
+++ b/framework/Security/TUser.php
@@ -38,6 +38,10 @@ class TUser extends TComponent implements IUser
*/
private $_state;
/**
+ * @var boolean whether user state is changed
+ */
+ private $_stateChanged=false;
+ /**
* @var IUserManager user manager
*/
private $_manager;
@@ -196,6 +200,23 @@ class TUser extends TComponent implements IUser
unset($this->_state[$key]);
else
$this->_state[$key]=$value;
+ $this->_stateChanged=true;
+ }
+
+ /**
+ * @return boolean whether user session state is changed (i.e., setState() is called)
+ */
+ public function getStateChanged()
+ {
+ return $this->_stateChanged;
+ }
+
+ /**
+ * @param boolean whether user session state is changed
+ */
+ public function setStateChanged($value)
+ {
+ $this->_stateChanged=TPropertyValue::ensureBoolean($value);
}
}