Crossfire Server, Trunk
Utils.h
Go to the documentation of this file.
1 /*
2  * Crossfire -- cooperative multi-player graphical RPG and adventure game
3  *
4  * Copyright (c) 2020-2021 the Crossfire Development Team
5  *
6  * Crossfire is free software and comes with ABSOLUTELY NO WARRANTY. You are
7  * welcome to redistribute it under certain conditions. For details, please
8  * see COPYING and LICENSE.
9  *
10  * The authors can be reached via e-mail at <crossfire@metalforge.org>.
11  */
12 
13 #ifndef UTILS_H
14 #define UTILS_H
15 
16 #include <string>
17 
18 extern "C" {
19 #include "global.h"
20 }
21 
22 class Utils {
23 public:
30  static bool endsWith(const std::string& str, const std::string& with);
31 
38  static void writeLinkedChar(const linked_char *list, StringBuffer *buf);
39 
46  static void writeStringArray(char **items, size_t count, StringBuffer *buf);
47 };
48 
49 #endif /* UTILS_H */
50 
global.h
guildoracle.list
list
Definition: guildoracle.py:87
linked_char
Definition: global.h:86
Utils
Definition: Utils.h:22
make_face_from_files.str
str
Definition: make_face_from_files.py:24
disinfect.count
int count
Definition: disinfect.py:7
StringBuffer
Definition: stringbuffer.c:25
Utils::endsWith
static bool endsWith(const std::string &str, const std::string &with)
Definition: Utils.cpp:16
buf
StringBuffer * buf
Definition: readable.c:1606
Utils::writeStringArray
static void writeStringArray(char **items, size_t count, StringBuffer *buf)
Definition: Utils.cpp:36
Utils::writeLinkedChar
static void writeLinkedChar(const linked_char *list, StringBuffer *buf)
Definition: Utils.cpp:22