... 方法 public XSSearch addRange(string $field, mixed $from, mixed $to) $field string $from mixed 起始值(不包含), 若设为 null 则相当于匹配 <= to (字典顺序) $to mixed 结束值(包含), 若设为 null 则相当于匹配 >= from (字典顺序) {re...
convert() 方法 public static mixed convert(mixed $data, string $to, string $from) $data mixed 需要转换的数据, 支持 string 和 array, 数组会自动递归转换 $to string 转换后的字符集 $from string 转换前的字符集 {return} mixed 转换...
...le = realpath($file); if (is_dir($file)) { $pos = false; $to = $file; } else { $pos = strrpos($file, '/'); $to = substr($file, 0, $pos); } for ($rel = '';; $rel .= '../') { if ($from === $to) { break; } if ($from === dirname($fr...
... 名称描述定义于 __construct() Exception __toString() 将类对象转换成字符串 XSException getCode() Exception getFile() Exception getLine() Exception getMessage() Exception getPrevious() Exception getRelPath(...
... ($len = $size = strlen($buf)) == 0) { return true; } // loop to send data $this->check(); while (true) { $bytes = fwrite($this->_sock, $buf, $len); if ($bytes === false || $bytes === 0 || $bytes === $len) { break; } $len -= $bytes; $b...
...erver.class.php#L452 (显示) protected function connect(){ // connect to server $conn = $this->_conn; if (is_int($conn) || is_numeric($conn)) { $host = 'localhost'; $port = intval($conn); } elseif (!strncmp($conn, 'file://', 7)) { // write-only for saving index exc...
getIterator() 方法 public void getIterator() 源码: sdk/php/lib/XSDocument.class.php#L272 (显示) public function getIterator(){ if ($this->_charset !== null && $this->_charset !== 'UTF-8') { $from = $this->_meta === null ? $this->_charset : 'UTF-8'; $to = $this->_me...
...return for zero size if ($len == 0) { return ''; } // loop to send data $this->check(); for ($buf = '', $size = $len;;) { $bytes = fread($this->_sock, $len); if ($bytes === false || strlen($bytes) == 0) { break; } $len -= strlen($bytes); ...
... $user, $pass)) === false) { throw new XSException("Can not connect to mysql server: '$user@$host'"); } if (!mysql_select_db($param['dbname'], $this->link)) { $this->close(); throw new XSException("Can not switch to database name: '{$param['dbname']}'"); } $this->set...
...$this->obj->connect_error) { throw new XSException("Can not connect to mysql server: '$user@$host'"); } if (!$this->obj->select_db($param['dbname'])) { $this->close(); throw new XSException("Can not switch to database name: '{$param['dbname']}'"); } $this->setUtf8();...