๐Ÿ“ฆ fghpdf / readBitmap

read bitmap from redis

โ˜… 2 stars โ‘‚ 0 forks ๐Ÿ‘ 2 watching โš–๏ธ MIT License
๐Ÿ“ฅ Clone https://github.com/fghpdf/readBitmap.git
HTTPS git clone https://github.com/fghpdf/readBitmap.git
SSH git clone git@github.com:fghpdf/readBitmap.git
CLI gh repo clone fghpdf/readBitmap
fghpdf fghpdf fix: export error and add read from buffer b8ca032 7 years ago ๐Ÿ“ History
๐Ÿ“‚ master View all commits โ†’
๐Ÿ“ example
๐Ÿ“„ .gitignore
๐Ÿ“„ .npmignore
๐Ÿ“„ .npmrc
๐Ÿ“„ index.js
๐Ÿ“„ LICENSE
๐Ÿ“„ package.json
๐Ÿ“„ README.md
๐Ÿ“„ README.md

readBitmap

read bitmap from redis


Quick Start

Install

npm i --save readbitmap

Basic Usage

const readBitmap = require('readbitmap')
readBitmap('testBit').then((res) => {
  console.log(res)
})

// [0, 12, 13, 100]

// or connect remote redis server

const readBitmap = require('readbitmap')
readBitmap('testBit', { host: 'redis_host', port: 3306 }).then((res) => {
  console.log(res)
})

// or read buffer
const readBitmap = require('readbitmap')
readBitmap(Buffer.from('0123')).then((res) => {
  console.log(res)
})

Params

The first param is redis bitmap key or buffer, redis config can`t work if you use buffer.

The second param is redis config, you can see ioredis to get more infomation to connect redis.

License

MIT