Пример #1
0
 public function __construct($vals = null)
 {
     if (!isset(self::$_TSPEC)) {
         self::$_TSPEC = array(1 => array('var' => 'key', 'type' => TType::STRING), 2 => array('var' => 'count', 'type' => TType::I32));
     }
     if (is_array($vals)) {
         if (isset($vals['key'])) {
             $this->key = $vals['key'];
         }
         if (isset($vals['count'])) {
             $this->count = $vals['count'];
         }
     }
 }
Пример #2
0
 public function __construct($vals = null)
 {
     if (!isset(self::$_TSPEC)) {
         self::$_TSPEC = array(1 => array('var' => 'key', 'type' => TType::STRING), 2 => array('var' => 'count', 'type' => TType::I32));
     }
     if (is_array($vals)) {
         parent::__construct(self::$_TSPEC, $vals);
     }
 }