3DRadSpace 0.1.0Alpha
3DRadSpace is a free, simple to use, rapid application development game engine.
Loading...
Searching...
No Matches
scriptstdstring.h
Go to the documentation of this file.
1//
2// Script std::string
3//
4// This function registers the std::string type with AngelScript to be used as the default string type.
5//
6// The string type is registered as a value type, thus may have performance issues if a lot of
7// string operations are performed in the script. However, for relatively few operations, this should
8// not cause any problem for most applications.
9//
10
11#ifndef SCRIPTSTDSTRING_H
12#define SCRIPTSTDSTRING_H
13
14#ifndef ANGELSCRIPT_H
15// Avoid having to inform include path if header is already include before
16#include <angelscript.h>
17#endif
18
19#include <string>
20
21//---------------------------
22// Compilation settings
23//
24
25// Sometimes it may be desired to use the same method names as used by C++ STL.
26// This may for example reduce time when converting code from script to C++ or
27// back.
28//
29// 0 = off
30// 1 = on
31#ifndef AS_USE_STLNAMES
32#define AS_USE_STLNAMES 0
33#endif
34
35// Some prefer to use property accessors to get/set the length of the string
36// This option registers the accessors instead of the method length()
37#ifndef AS_USE_ACCESSORS
38#define AS_USE_ACCESSORS 0
39#endif
40
41// This option disables the implicit operators with primitives
42#ifndef AS_NO_IMPL_OPS_WITH_STRING_AND_PRIMITIVE
43#define AS_NO_IMPL_OPS_WITH_STRING_AND_PRIMITIVE 0
44#endif
45
46BEGIN_AS_NAMESPACE
47
48void RegisterStdString(asIScriptEngine *engine);
49void RegisterStdStringUtils(asIScriptEngine *engine);
50
51END_AS_NAMESPACE
52
53#endif
BEGIN_AS_NAMESPACE void RegisterStdString(asIScriptEngine *engine)
Definition scriptstdstring.cpp:1361
void RegisterStdStringUtils(asIScriptEngine *engine)
Definition scriptstdstring_utils.cpp:114