original_string: public static function Login($mId, $sUsername, $sName, $iTimeout = 3600, $bRoot = false){
              $oThis = self::CreateInstanceIfNotExists();
  
              if($oThis->bStarted){
                  $iTimeout = time()+$iTimeout;
                  $oThis->aAuth = array("id" => $mId, "name" => $sName, "username" => $sUsername, "timeout" => $iTimeout, "root" => $bRoot);											
                  $_SESSION[$oThis->sName]["authentication"] = $oThis->aAuth;
  
                  if(!empty($oThis->aAuth)){
                      Storage::Set("user.id", $oThis->aAuth["id"]);
                      Storage::Set("user.name", $oThis->aAuth["name"]);
                      Storage::Set("user.username", $oThis->aAuth["username"]);
                      Storage::Set("user.root", $oThis->aAuth["root"]);
                      Storage::Set("session.timeout.login",  $iTimeout); 
                  }
              }
          }
code: public static function Login($mId, $sUsername, $sName, $iTimeout = 3600, $bRoot = false){
              $oThis = self::CreateInstanceIfNotExists();
  
              if($oThis->bStarted){
                  $iTimeout = time()+$iTimeout;
                  $oThis->aAuth = array("id" => $mId, "name" => $sName, "username" => $sUsername, "timeout" => $iTimeout, "root" => $bRoot);											
                  $_SESSION[$oThis->sName]["authentication"] = $oThis->aAuth;
  
                  if(!empty($oThis->aAuth)){
                      Storage::Set("user.id", $oThis->aAuth["id"]);
                      Storage::Set("user.name", $oThis->aAuth["name"]);
                      Storage::Set("user.username", $oThis->aAuth["username"]);
                      Storage::Set("user.root", $oThis->aAuth["root"]);
                      Storage::Set("session.timeout.login",  $iTimeout); 
                  }
              }
          }
code_tokens: public static function Login ( $ mId , $ sUsername , $ sName , $ iTimeout = 3600 , $ bRoot = false ) { $ oThis = self :: CreateInstanceIfNotExists ( ) ; if ( $ oThis -> bStarted ) { $ iTimeout = time ( ) + $ iTimeout ; $ oThis -> aAuth = array ( "id" => $ mId , "name" => $ sName , "username" => $ sUsername , "timeout" => $ iTimeout , "root" => $ bRoot ) ; $ _SESSION [ $ oThis -> sName ] [ "authentication" ] = $ oThis -> aAuth ; if ( ! empty ( $ oThis -> aAuth ) ) { Storage :: Set ( "user.id" , $ oThis -> aAuth [ "id" ] ) ; Storage :: Set ( "user.name" , $ oThis -> aAuth [ "name" ] ) ; Storage :: Set ( "user.username" , $ oThis -> aAuth [ "username" ] ) ; Storage :: Set ( "user.root" , $ oThis -> aAuth [ "root" ] ) ; Storage :: Set ( "session.timeout.login" , $ iTimeout ) ; } } }
docstring: Function to perform the login session
  
  @static
  @access public
  @param mixed $mId User ID
  @param string $sUsername Username
  @param string $sName Name
  @param integer $iTimeout Maximum time of permanence in the session
  @param boolean $bRoot Defines the user as root
  @return void
docstring_tokens: Function to perform the login session