14#if !defined(ALIB_PATH_CHARACTERS_WIDE)
16 static_assert(std::same_as<PathCharType, characters::wchar>,
17 "Compiler symbol ALIB_PATH_CHARACTERS_WIDE wrongly detected: 1 but std::filesystem::path::value_type does not equal characters::wchar.");
19 static_assert(std::same_as<PathCharType, characters::nchar>,
20 "Compiler symbol ALIB_PATH_CHARACTERS_WIDE wrongly detected: 0 but std::filesystem::path::value_type does not equal characters::nchar.");
23# if ALIB_PATH_CHARACTERS_WIDE
24 static_assert(std::same_as<PathCharType, characters::wchar>,
25 "Given compiler-symbol ALIB_PATH_CHARACTERS_WIDE mismatch: Given 1 but std::filesystem::path::value_type does not equal characters::wchar.");
27 static_assert(std::same_as<PathCharType, characters::nchar>,
28 "Given compiler-symbol ALIB_PATH_CHARACTERS_WIDE mismatch: Given 0 but std::filesystem::path::value_type does not equal characters::nchar.");
61#if !defined( _WIN32 ) || DOXYGEN
75 void ALIB_APPLE_OC_NSTemporaryDirectory(
Path& target );
76 void ALIB_APPLE_OC_NSHomeDirectory (
Path& target );
361 if( slashSlashPos > 0 )
362 return int(slashSlashPos + 2);
378inline bool operator== (
const Path& lhs,
const Path& rhs)
379{
return lhs.
template Equals <CHK, lang::Case::Sensitive>(rhs); }
382inline auto operator<=> (
const Path& lhs,
const Path& rhs)
383{
return lhs.
template CompareTo<CHK, lang::Case::Sensitive>(rhs); }
404struct ZTArrayTraits<system::Path, system::PathCharType>
406 static constexpr Policy Access = Policy::Implicit;
407 static constexpr Policy Construction = Policy::NONE;
constexpr const TChar * Terminate() const
constexpr TLocalString(lang::HeapAllocator &pAllocator)
constexpr integer Length() const
TChar CharAtStart() const
integer IndexOf(TChar needle, integer startIdx=0) const
TChar CharAt(integer idx) const
integer LastIndexOf(PathCharType needle, integer startIndex=MAX_LEN) const
PathCharType CharAtEnd() const
Path(SystemFolders special, const PathString &fileName)
ALIB_DLL SystemErrors MakeReal()
static PathString varTempDirEvaluatedOnce
Path & Add(const PathString &dirOrFilename)
ALIB_DLL SystemErrors Create()
Path(SystemFolders special)
ALIB_DLL void AddModuleName(const PathString &extension)
ALIB_DLL bool IsDirectory()
Path(const PathString &path)
void Change(SystemFolders special, const PathString &fileName)
ALIB_DLL bool Change(const PathString &path)
static int IsAbsolute(const PathString &path)
static PathString tempDirEvaluatedOnce
#define ALIB_ENUMS_ASSIGN_RECORD(TEnum, TRecord)
#define ALIB_BOXING_VTABLE_DECLARE(TMapped, Identifier)
@ Current
The current directory of the process.
@ Home
The user's home directory.
@ Module
The directory of the executable of the process.
@ Root
The root directory .
strings::TAString< PathCharType, PoolAllocator > PathStringMA
A mono-allocated string representing a path.
strings::TCString< PathCharType > CPathString
The string-type used with this ALib Module.
strings::TString< PathCharType > PathString
The string-type used with this ALib Module.
strings::TSubstring< PathCharType > PathSubstring
The string-type used with this ALib Module.
constexpr PathString NULL_PATH
A nulled path string.
strings::TAString< PathCharType, PoolAllocator > PathStringPA
A pool-allocated string representing a path.
constexpr PathString EMPTY_PATH
An empty path string.
std::filesystem::path::value_type PathCharType
constexpr PathCharType DIRECTORY_SEPARATOR
The standard path separator character. Defaults to '\' on Windows OS, '/' else.
lang::integer integer
Type alias in namespace alib.
system::SystemFolders SystemFolders
Type alias in namespace alib.
system::Path Path
Type alias in namespace alib.
strings::TSubstring< character > Substring
Type alias in namespace alib.