BitExpInsert Method

Create expression that inserts value bytes into byte[] bin at byteOffset and returns byte[].
  • bin = [0b00000001, 0b01000010, 0b00000011, 0b00000100, 0b00000101]
  • byteOffset = 1
  • value = [0b11111111, 0b11000111]
  • bin result = [0b00000001, 0b11111111, 0b11000111, 0b01000010, 0b00000011, 0b00000100, 0b00000101]

Definition

Namespace: Aerospike.Client
Assembly: AerospikeClient (in AerospikeClient.dll) Version: 7.0.1
C#
public static Exp Insert(
	BitPolicy policy,
	Exp byteOffset,
	Exp value,
	Exp bin
)

Parameters

policy  BitPolicy
 
byteOffset  Exp
 
value  Exp
 
bin  Exp
 

Return Value

Exp

Example

C#
// Insert bytes into bin "a" and compare bit count
Exp.EQ(
  BitExp.Count(Exp.Val(0), Exp.Val(3),
    BitExp.Insert(BitPolicy.Default, Exp.Val(1), Exp.Val(bytes), Exp.BlobBin("a"))),
  Exp.Val(2))

See Also