Esempio n. 1
0
 public function index()
 {
     //$this->jump('/login',true);
     echo "<br>";
     echo "in index";
     echo "<br>";
     $xz = new Xcrypt();
     $num = rand(10000, 20000) . rand(10000, 20000) . rand(10000, 20000);
     $res = $xz->encode($num);
     echo $res;
     $login = picom('login');
     $res = $login->dologin(array('111' => 1241, 'hihu' => 1241));
     echo $res;
 }
Esempio n. 2
0
 static function Server()
 {
     $mod = Comm::req('mod');
     $add = Comm::req('add');
     $method = Comm::req('method');
     $args = Comm::req('param', array());
     try {
         $class = picom($mod, $add, true);
         if (is_callable(array($class, $method))) {
             $reflection = new ReflectionMethod($class, $method);
             $argnum = $reflection->getNumberOfParameters();
             if ($argnum > count($args)) {
                 self::output("inner api call the {$method} from {$mod} {$add} with err args", 5010);
             }
             //公共方法才允许被调用
             $res = $reflection->invokeArgs($class, $args);
             self::output($res);
         }
         self::output("inner api not callable the {$mod} {$add} from {$method} fail", 5009);
     } catch (Exception $e) {
         self::output("inner api execute the {$mod} {$add} from {$method} fail", 5008);
     }
 }
Esempio n. 3
0
 public function index()
 {
     //$this->jump('/login',true);
     echo "<br>";
     echo "in index";
     echo "<br>";
     $xz = new Xcrypt();
     $num = rand(10000, 20000) . rand(10000, 20000) . rand(10000, 20000);
     $res = $xz->encode($num);
     echo $res;
     $login = picom('login');
     $res = $login->dologin(array('111' => 1241, 'hihu' => 1241));
     echo $res;
     // $q = new Queue("hihu",'users',600);
     // $q->push(array("queue"=>'真的'));
     // $q->push(array("queue"=>'真的'));
     // $q->push(array("queue"=>'真的'));
     // var_dump($q->getSize());
     // var_dump($q->pop());
     // var_dump($q->pop());
     // var_dump($q->getSize());
     // var_dump($q->clear());
     // var_dump($q->pop());
 }