ALib C++ Library
Library Version: 2510 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
astring.cpp
1// #################################################################################################
2// ALib C++ Library
3//
4// Copyright 2013-2025 A-Worx GmbH, Germany
5// Published under 'Boost Software License' (a free software license, see LICENSE.txt)
6// #################################################################################################
7#include "alib_precompile.hpp"
8#if !defined(ALIB_C20_MODULES) || ((ALIB_C20_MODULES != 0) && (ALIB_C20_MODULES != 1))
9# error "Symbol ALIB_C20_MODULES has to be given to the compiler as either 0 or 1"
10#endif
11#if ALIB_C20_MODULES
12 module;
13#endif
14// ====================================== Global Fragment ======================================
16#include <cstring>
17// =========================================== Module ==========================================
18#if ALIB_C20_MODULES
19 module ALib.Strings;
20 import ALib.Lang;
21 #if ALIB_CAMP
22 import ALib.Camp.Base;
23 #endif
24#else
25# include "ALib.Lang.H"
26# include "ALib.Camp.Base.H"
27# include "ALib.Strings.H"
28#endif
29// ====================================== Implementation =======================================
30
31#define ALIB_STRINGS_TASTRING_INSTANTIATION
32# include "alib/strings/detail/tastringimpl.inl"
33
34#define ALIB_STRINGS_TASTRING_INSTANTIATION
35# define ASTR_TALLOC_SPEC lang::HeapAllocator
36# define ASTR_TCHAR_SPEC ALIB_CHAR_TYPE_ID_X
37# include "alib/strings/detail/tastring_ca_impl.inl.inl"
38
39# define ASTR_TALLOC_SPEC lang::HeapAllocator
40# define ASTR_TCHAR_SPEC ALIB_CHAR_TYPE_ID_W
41# include "alib/strings/detail/tastring_ca_impl.inl.inl"
42
43# define ASTR_TALLOC_SPEC lang::HeapAllocator
44# define ASTR_TCHAR_SPEC ALIB_CHAR_TYPE_ID_N
45# include "alib/strings/detail/tastring_ca_impl.inl.inl"
46
47
48#undef ALIB_STRINGS_TASTRING_INSTANTIATION
49
50#if !DOXYGEN
51namespace alib::strings {
52String DT_UNITS[size_t(DayTimeUnits::SIZE_OF_UNITS)]
53#if ALIB_CAMP
54 ;
55#else
56={
57DOX_MARKER( [DT_UNITS_DEFAULTS])
58 A_CHAR("zero time"),
59 A_CHAR(" days" ) , A_CHAR(" day" ) ,
60 A_CHAR(" hours" ) , A_CHAR(" hour" ) ,
61 A_CHAR(" minutes" ) , A_CHAR(" minute" ) ,
62 A_CHAR(" seconds" ) , A_CHAR(" second" ) ,
63 A_CHAR(" ms" ) , A_CHAR(" ms" ) ,
64 A_CHAR(" \u00B5s" ) , A_CHAR(" \u00B5s" ) ,
65 A_CHAR(" ns" ) , A_CHAR(" ns" ) };
66DOX_MARKER( [DT_UNITS_DEFAULTS])
67#endif
68
69}
70#endif
71
72#if !ALIB_SINGLE_THREADED
74 { target << src.GetName() << '(' << src.GetID() << ')';} )
75
77 { target << src.GetName() << '(' << src.GetID() << ')';} )
78#endif
79
#define ALIB_STRINGS_APPENDABLE_TYPE_DEF_W(TYPE, IMPL)
#define A_CHAR(STR)
#define ALIB_STRINGS_APPENDABLE_TYPE_DEF_N(TYPE, IMPL)
String DT_UNITS[size_t(DayTimeUnits::SIZE_OF_UNITS)]
strings::TString< character > String
Type alias in namespace alib.
Definition string.inl:2381