This section contains collection support for single byte strings such as char*. More...
Functions | |
RUAPI ru_uint | ruStrHash (trans_ptr key) |
Returns a hash for given string. More... | |
RUAPI bool | ruStrMatch (trans_ptr s1, trans_ptr s2) |
Convenience match function for Maps. More... | |
RUAPI int32_t | ruStrComp (trans_ptr testVal, trans_ptr existingVal) |
String comparator function for the ruType system. More... | |
RUAPI ruType | ruTypeStrRef (void) |
Returns an ruType used for permanent strings. More... | |
RUAPI ruType | ruTypeStrDup (void) |
Returns an ruType used for transient strings. More... | |
RUAPI ruType | ruTypeStrFree (void) |
Returns an ruType used for externally allocated string. More... | |
This section contains collection support for single byte strings such as char*.
String comparator function for the ruType system.
testVal | Value to compare against existing value. |
existingVal | The existing value to compare testVal to. |
Returns a hash for given string.
This function is useful for Maps.
key | String to hash. |
Convenience match function for Maps.
s1 | First comparison string. |
s2 | Second comparison string. |
RUAPI ruType ruTypeStrDup | ( | void | ) |
Returns an ruType used for transient strings.
Example:
Given keys will be copied when added and freed on removal or ruMapFree.
RUAPI ruType ruTypeStrFree | ( | void | ) |
Returns an ruType used for externally allocated string.
Example:
Given keys will not be copied when added but freed on removal or ruMapFree.
RUAPI ruType ruTypeStrRef | ( | void | ) |
Returns an ruType used for permanent strings.
Example:
Given keys will neither be copied nor freed and must exist for the duration of the map using them.