9 #ifndef __ewf_lib__h__included__
10 #define __ewf_lib__h__included__
51 const char * ewfl_escape_str_to_str_buffer(
const char * str, uint32_t len);
121 bool ewfl_buffer_starts_with(
const uint8_t* buffer_ptr, uint32_t buffer_length,
const uint8_t* prefix_ptr, uint32_t prefix_length);
127 bool ewfl_buffer_ends_with(
const uint8_t* buffer_ptr, uint32_t buffer_length,
const uint8_t* suffix_ptr, uint32_t suffix_length);
190 char *
ewfl_str_n_cpy(
char* dest,
const char* src_str, uint32_t n);
234 char*
ewfl_str_tok(
char* str,
const char* delim,
char** saveptr);
The Embedded Wireless Framework.
char * ewfl_str_tok(char *str, const char *delim, char **saveptr)
Wrapper function with functionality equivalent to strtok_s / strtok_r.
Definition: ewf_lib.c:305
bool ewfl_buffer_starts_with(const uint8_t *buffer_ptr, uint32_t buffer_length, const uint8_t *prefix_ptr, uint32_t prefix_length)
Checks if a buffer starts with a string.
Definition: ewf_lib.c:133
bool ewfl_buffer_ends_with_wildcard_string(const uint8_t *buffer_ptr, uint32_t buffer_length, const uint8_t *suffix_ptr, uint32_t suffix_length)
Checks if a buffer ends with a string containing wildcards The current version supports question mark...
Definition: ewf_lib.c:164
bool ewfl_buffer_equals_buffer(const uint8_t *buffer1, const uint8_t *buffer2, uint32_t length)
Checks if two buffers are equal.
Definition: ewf_lib.c:194
uint32_t ewfl_str_to_unsigned(const char *str)
Parse an uint32_t from a string.
Definition: ewf_lib.c:97
bool ewfl_buffer_ends_with(const uint8_t *buffer_ptr, uint32_t buffer_length, const uint8_t *suffix_ptr, uint32_t suffix_length)
Checks if a buffer ends with a string.
Definition: ewf_lib.c:148
char * ewfl_str_remove_white_spaces(char *str)
Remove leading and trailing white space characters.
Definition: ewf_lib.c:232
bool ewfl_str_equals_str(const char *str1, const char *str2)
Checks if two strings are equal.
Definition: ewf_lib.c:186
char * ewfl_str_n_cpy(char *dest, const char *src_str, uint32_t n)
Copies source string to destination buffer and terminates it by NULL.
Definition: ewf_lib.c:226
char * ewfl_adapter_response_str_extract(char *str)
Parse adapter response by trimming white space and "OK".
Definition: ewf_lib.c:264
bool ewfl_str_contains_str(const char *str, const char *substr)
Searches for a string in a substring.
Definition: ewf_lib.c:204
char * ewfl_str_remove_suffix_str(char *str, const char *suffix_str)
Remove suffix from string.
Definition: ewf_lib.c:249
char * ewfl_find_chars_with_terms(char *str, char *chars_str, char *term_str)
Find the next matching character from several of many in a string, break and fail on matching custom ...
Definition: ewf_lib.c:273
char * ewfl_unsigned_to_str(uint32_t u, char *str, uint32_t len)
Converts an uint32_t to a string.
Definition: ewf_lib.c:82
bool ewfl_str_ends_with(const char *str, const char *suffix_str)
Tests for a string end match.
Definition: ewf_lib.c:121
uint32_t ewfl_str_length(const char *str)
Returns the length of the passed NULL terminated string.
Definition: ewf_lib.c:106
bool ewfl_str_starts_with(const char *str, const char *prefix_str)
Tests for a string start match.
Definition: ewf_lib.c:114