find method
Returns values of this property matching the query.
Results are in no particular order. Excludes null values unless you
specify replaceNullWith
.
Implementation
List<double> find({double? replaceNullWith}) {
switch (_type) {
case OBXPropertyType.Float:
final cDefault = replaceNullWith == null
? null
: (malloc<Float>()..value = replaceNullWith);
return _find(
C.query_prop_find_floats,
cDefault,
(Pointer<OBX_float_array> cItems) =>
cItems.ref.items.asTypedList(cItems.ref.count).toList(),
C.float_array_free);
case OBXPropertyType.Double:
final cDefault = replaceNullWith == null
? null
: (malloc<Double>()..value = replaceNullWith);
return _find(
C.query_prop_find_doubles,
cDefault,
(Pointer<OBX_double_array> cItems) =>
cItems.ref.items.asTypedList(cItems.ref.count).toList(),
C.double_array_free);
default:
throw UnsupportedError(
'Property query: unsupported type (OBXPropertyType: $_type)');
}
}