Ejemplo n.º 1
0
 public function __construct($name, IServer $server)
 {
     parent::__construct($name);
     $this->server = $server;
     $this->setHost($server->getHost());
     $this->setUser($server->getUser());
     $this->setPassword($server->getPassword());
 }
Ejemplo n.º 2
0
 /**
  * @brief 获取客户端当前访问的时间戳
  * @return int 时间戳
  */
 public static function getTime()
 {
     if (IServer::isGeVersion('5.1.0')) {
         return $_SERVER['REQUEST_TIME'];
     } else {
         return time();
     }
 }