Constructs a new Key instance.
Optional
ns: null | stringThe Namespace to which the key belongs.
Optional
set: null | stringThe Set to which the key belongs.
Optional
key: The unique key value. Keys can be strings, integers or an instance of the Buffer class.
Optional
digest: null | BufferThe digest value of the key.
The digest value of the key.
The unique key value. Keys can be strings, integers or an instance of the Buffer class.
The Namespace to which the key belongs.
he Set to which the key belongs.
Compare the equality of two keys.
{#Key} or KeyOptions Object for comparison.
Key
A key uniquely identifies a record in the Aerospike database within a given namespace.
Remarks
Key Digests
In your application, you must specify the namespace, set and the key itself to read and write records. When a key is sent to the database, the key value and its set are hashed into a 160-bit digest. When a database command returns a key (e.g. Query or Scan commands) it might contain either the set and key value, or just the digest.
Param: ns
The Namespace to which the key belongs.
Param: set
The Set to which the key belongs.
Param: key
The unique key value. Keys can be strings, integers or an instance of the Buffer class.
Param: digest
The digest value of the key.
Example: Creating a new {@link Key} instance