Changes between Initial Version and Version 1 of StringUtils
- Timestamp:
- 2010-02-27 03:46:36 (15 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
StringUtils
v1 v1 1 == stringutils.lua == 2 3 This module adds some extra functions to the standard Lua `string` library. These can also be used as 'string methods', both valid syntaxes are shown here. 4 5 '''`string.split (s, delimiter)`'''[[BR]] 6 '''`s:split (delimiter)`''' 7 Returns an array of substrings, separated by the pattern `delimiter`. 8 9 '''`string.template (s, variables)`'''[[BR]] 10 '''`s:template (variables)`''' 11 Returns a formatted string, replacing any `%{key}%` by the value of `variables.key`.