summaryrefslogtreecommitdiffstats
path: root/source/StringUtils.h
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2013-09-28 19:28:19 +0200
committermadmaxoft <github@xoft.cz>2013-09-28 19:28:19 +0200
commit3b473f7a67a8feb694856dd705454fdb9945b319 (patch)
treef151cbf2e8d5a6108d5ac62882d7724f0d8c2b12 /source/StringUtils.h
parentAdded UserData to cHTTPRequest. (diff)
downloadcuberite-3b473f7a67a8feb694856dd705454fdb9945b319.tar
cuberite-3b473f7a67a8feb694856dd705454fdb9945b319.tar.gz
cuberite-3b473f7a67a8feb694856dd705454fdb9945b319.tar.bz2
cuberite-3b473f7a67a8feb694856dd705454fdb9945b319.tar.lz
cuberite-3b473f7a67a8feb694856dd705454fdb9945b319.tar.xz
cuberite-3b473f7a67a8feb694856dd705454fdb9945b319.tar.zst
cuberite-3b473f7a67a8feb694856dd705454fdb9945b319.zip
Diffstat (limited to 'source/StringUtils.h')
-rw-r--r--source/StringUtils.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/StringUtils.h b/source/StringUtils.h
index 211799e91..929e6fd5b 100644
--- a/source/StringUtils.h
+++ b/source/StringUtils.h
@@ -72,6 +72,12 @@ extern AString EscapeString(const AString & a_Message); // tolua_export
/// Removes all control codes used by MC for colors and styles
extern AString StripColorCodes(const AString & a_Message); // tolua_export
+/// URL-Decodes the given string, replacing all "%HH" into the correct characters. Invalid % sequences are left intact
+extern AString URLDecode(const AString & a_String); // Cannot export to Lua automatically - would generated an extra return value
+
+/// Replaces all occurrences of char a_From inside a_String with char a_To.
+extern AString ReplaceAllCharOccurrences(const AString & a_String, char a_From, char a_To); // Needn't export to Lua, since Lua doesn't have chars anyway
+
// If you have any other string helper functions, declare them here