Updated: October 28, 2024 |
Check if a given value is in the given list of strings
#include <aoi.h> int AoSearchString(const char *list, const char *val, size_t val_len, unsigned flags);
This buffer can contain an addon string setting that was retrieved by AoFindString().
This function searches for a representation of the given value (val) in the given list of strings (list). This offers a convenient way of looking through many strings in a list and determining if any match the search value based on either its exact character sequence or its hexadecimal representation (e.g., a list string of "\x4E4C" will match a search value of "NL"). The function also supports case-insensitive search for character string values.
1 if a match for the value is found, 0 if it's not.
An example of using AoSearchString() to check if a given value is in a string setting read from an addon's Strings interface is given in the AoIterate() entry.