MapExpGetByKey Method

Create expression that selects map item identified by key and returns selected data specified by returnType.

Definition

Namespace: Aerospike.Client
Assembly: AerospikeClient (in AerospikeClient.dll) Version: 7.0.1
C#
public static Exp GetByKey(
	MapReturnType returnType,
	ExpType valueType,
	Exp key,
	Exp bin,
	params CTX[] ctx
)

Parameters

returnType  MapReturnType
metadata attributes to return. See MapReturnType
valueType  ExpType
expected type of return value
key  Exp
map key expression
bin  Exp
bin or map value expression
ctx  CTX
optional context path for nested CDT

Return Value

Exp

Example

C#
// Map bin "a" contains key "B"
Exp.GT(
  MapExp.GetByKey(MapReturnType.COUNT, Type.INT, Exp.Val("B"), Exp.MapBin("a")),
  Exp.Val(0));

See Also