API v1.x

You are currently looking at the documentation of a previous version of Kuzzle. We strongly recommend that you use the latest version. You can also use the version selector in the top menu.

bitcount #

Counts the number of set bits (population counting) in a string.

[Redis documentation]

Query Syntax #


Copied to clipboard!
URL: http://kuzzle:7512/ms/_bitcount/<_id>[?start=<integer>&end=<integer>]
Method: GET

Other protocols #

Copied to clipboard!
  "controller": "ms",
  "action": "bitcount",
  "_id": "<key>"
  "start": <integer>,
  "end": <integer>

Arguments #

  • _id: key to evaluate

Optional: #

  • start: count starts at the provided offset
  • end: count ends at the provided offset

Response #

Returns the number of set bits.

Copied to clipboard!
  "requestId": "<unique request identifier>",
  "status": 200,
  "error": null,
  "controller": "ms",
  "action": "bitcount",
  "collection": null,
  "index": null,
  "result": 42