Source for file User.class.php

Documentation is available at User.class.php

  1. <?php
  2. /**
  3.  * Gumbo Library Framework
  4.  *
  5.  * LICENSE
  6.  * This library is being released under the terms of the New BSD License.  A
  7.  * copy of the license is packaged with the software (LICENSE.txt).  If no
  8.  * copy is found, a copy of the license template can be found at:
  9.  * http://www.opensource.org/licenses/bsd-license.php
  10.  * 
  11.  * @category Gumbo
  12.  * @package Session
  13.  * @copyright Copyright (c) 2007, iBayou, Michael Luster
  14.  * @license http://www.opensource.org/licenses/bsd-license.php New BSD License
  15.  * @author Michael Luster <mluster79@yahoo.com>
  16.  * @link http://sourceforge.net/projects/phpgumbo
  17.  * @version 0.0.1
  18.  */
  19.  
  20. /**
  21.  * User Session Interface
  22.  *
  23.  * @category Gumbo
  24.  * @package Session
  25.  * @copyright Copyright (c) 2007, iBayou, Michael Luster
  26.  * @license http://www.opensource.org/licenses/bsd-license.php New BSD License
  27.  * @author Michael Luster <mluster79@yahoo.com>
  28.  * @link http://sourceforge.net/projects/phpgumbo
  29.  * @desc User Session Interface
  30.  * @version 0.0.1
  31.  */
  32.  
  33. gumbo_load ("Interface_Session");
  34.  
  35.     
  36.     /** ACTION METHODS **/
  37.     /**
  38.      * Loads the User SESSION data
  39.      * The User Session Encrypted String is saved in the following format:
  40.      * session_id||user_id||agent||ip_address||date
  41.      * @postcondition setUser ()
  42.      * @postcondition _setUserLoaded ([true|false])
  43.      */
  44.     public function loadUser ();
  45.     
  46.     
  47.     
  48.     /** MUTATOR METHODS **/
  49.     /**
  50.      * Sets the User Key
  51.      * @param string $key 
  52.      */
  53.     public function setUserKey ($key);
  54.     
  55.     /**
  56.      * Sets the User ID
  57.      * @param int|string$userID 
  58.      */
  59.     public function setUser ($userID);
  60.     
  61.     
  62.     
  63.     /** ACCESSOR METHODS **/
  64.     /**
  65.      * Returns the User Key
  66.      * @return string 
  67.      */
  68.     public function getUserKey ();
  69.     
  70.     /**
  71.      * Returns the User ID
  72.      * @return string|int
  73.      */
  74.     public function getUser ();
  75.     
  76.     /**
  77.      * Returns if the User has been loaded
  78.      * @return bool 
  79.      */
  80.     public function isUserLoaded ();
  81.     
  82. }
  83.  
  84. ?>