Skip to content

Home / node / Commands / classes / BitFieldIncrBy @valkey/valkey-glide


@valkey/valkey-glide / Commands / BitFieldIncrBy

Class: BitFieldIncrBy

Represents the "INCRBY" subcommand for increasing or decreasing bits in the binary representation of the string stored in key.

Implements

Constructors

Constructor

new BitFieldIncrBy(encoding, offset, increment): BitFieldIncrBy

Creates an instance of BitFieldIncrBy

Parameters

encoding

BitEncoding

The bit encoding for the subcommand.

offset

BitFieldOffset

The offset in the array of bits where the value will be incremented.

increment

number

The value to increment the bits in the binary value by.

Returns

BitFieldIncrBy

Methods

toArgs()

toArgs(): string[]

Returns the subcommand as a list of string arguments to be used in the bitfield or bitfieldReadOnly commands.

Returns

string[]

The subcommand as a list of string arguments.

Implementation of

BitFieldSubCommands.toArgs