代潇瑞博客

getBit 命令/方法/函数

Description

Return a single bit out of a larger string

将一个位返回一个较大的字符串


Parameters

key

offset


Return value

LONG: the bit value (0 or 1)


Example

$redis->set('key', "\x7f"); // this is 0111 1111

$redis->getBit('key', 0); /* 0 */

$redis->getBit('key', 1); /* 1 */

【相关命令】

触屏版 | 电脑版

Copyright © 2013 代潇瑞博客手机版

QQ: 446673330

粤ICP备13071969号-1