classifierOptions method
Allocates native classifier options backed by this scope.
Implementation
ffi.Pointer<bindings.MpClassifierOptions> classifierOptions(ClassifierOptions? options) {
final ClassifierOptions value = options ?? ClassifierOptions();
return bindings.MpClassifierOptions.$allocate(
_arena,
display_names_locale: string(value.displayNamesLocale),
max_results: value.maxResults ?? -1,
score_threshold: value.scoreThreshold ?? 0,
category_allowlist: strings(value.categoryAllowlist),
category_allowlist_count: value.categoryAllowlist.length,
category_denylist: strings(value.categoryDenylist),
category_denylist_count: value.categoryDenylist.length,
);
}