mirror of
https://github.com/nodejs/node.git
synced 2026-12-05 04:28:47 -05:00
Co-Authored-By: Daniel Lemire <daniel@lemire.me> PR-URL: https://github.com/nodejs/node/pull/52135 Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com> Reviewed-By: Vinícius Lourenço Claro Cardoso <contact@viniciusl.com.br> Reviewed-By: Daniel Lemire <daniel@lemire.me> Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
33 lines
795 B
C++
33 lines
795 B
C++
#ifndef SRC_PATH_H_
|
|
#define SRC_PATH_H_
|
|
|
|
#if defined(NODE_WANT_INTERNALS) && NODE_WANT_INTERNALS
|
|
|
|
#include <string>
|
|
#include <vector>
|
|
#include "node_options-inl.h"
|
|
#include "util-inl.h"
|
|
|
|
namespace node {
|
|
|
|
bool IsPathSeparator(const char c) noexcept;
|
|
|
|
std::string NormalizeString(const std::string_view path,
|
|
bool allowAboveRoot,
|
|
const std::string_view separator);
|
|
|
|
std::string PathResolve(Environment* env,
|
|
const std::vector<std::string_view>& paths);
|
|
|
|
#ifdef _WIN32
|
|
constexpr bool IsWindowsDeviceRoot(const char c) noexcept;
|
|
#endif // _WIN32
|
|
|
|
void ToNamespacedPath(Environment* env, BufferValue* path);
|
|
|
|
} // namespace node
|
|
|
|
#endif // defined(NODE_WANT_INTERNALS) && NODE_WANT_INTERNALS
|
|
|
|
#endif // SRC_PATH_H_
|