sismember

// Using callbacks (NodeJS or Web Browser)
kuzzle.memoryStorage.sismember('key', 'member', function (err, status) {
  // callback called once the action has completed
});

// Using promises (NodeJS only)
kuzzle.memoryStorage.sismemberPromise('key', 'member')
  .then(status => {
    // resolved once the action has completed
  });
kuzzle.memoryStorage.sismember("key", "member", new ResponseListener<Integer>() {
  @Override
  public void onSuccess(int status) {
    // callback called once the action has completed
  }

  @Override
  public void onError(JSONObject error) {
  }
});
<?php

use \Kuzzle\Kuzzle;


$kuzzle = new Kuzzle('localhost');

try {
  $status = $kuzzle->memoryStorage()->sismember('key', 'member');
}
catch (ErrorException $e) {

}

Callback response:

1

Checks if member is a member of the set of unique values stored at key.

[Redis documentation]


sismember(key, member, [options], callback)

ArgumentsTypeDescription
keystringKey identifier
memberstringValue tested against the set of unique values
optionsJSON ObjectOptional parameters
callbackfunctionCallback

Options

OptionTypeDescriptionDefault
queuablebooleanMark this request as (not) queuabletrue

Callback response

Resolves to an integer indicating if the provided value is a member of the set (1) or not (0).