16 #ifndef LLVM_SUPPORT_PATH_H
17 #define LLVM_SUPPORT_PATH_H
21 #include "llvm/Support/DataTypes.h"
148 const Twine &d =
"");
162 const_iterator
begin, const_iterator
end);
const_iterator end(StringRef path)
Get end iterator over path.
bool is_relative(const Twine &path)
Is path relative?
const StringRef parent_path(StringRef path)
Get parent path.
void replace_extension(SmallVectorImpl< char > &path, const Twine &extension)
Replace the file extension of path with extension.
bool has_stem(const Twine &path)
Has stem?
const StringRef extension(StringRef path)
Get extension.
const_iterator begin(StringRef path)
Get begin iterator over path.
std::bidirectional_iterator_tag iterator_category
bool has_root_directory(const Twine &path)
Has root directory?
bool operator==(const const_iterator &RHS) const
void append(SmallVectorImpl< char > &path, const Twine &a, const Twine &b="", const Twine &c="", const Twine &d="")
Append to path.
void native(const Twine &path, SmallVectorImpl< char > &result)
void remove_filename(SmallVectorImpl< char > &path)
Remove the last component from path unless it is the root dir.
pointer operator->() const
bool is_absolute(const Twine &path)
Is path absolute?
bool operator!=(const const_iterator &RHS) const
bool is_separator(char value)
Check whether the given char is a path separator on the host OS.
const StringRef stem(StringRef path)
Get stem.
bool has_relative_path(const Twine &path)
Has relative path?
friend const_iterator end(StringRef path)
Get end iterator over path.
bool has_filename(const Twine &path)
Has filename?
reference operator*() const
const StringRef root_directory(StringRef path)
Get root directory.
const_iterator & operator++()
ptrdiff_t operator-(const const_iterator &RHS) const
Difference in bytes between this and RHS.
const StringRef root_path(StringRef path)
Get root path.
const_iterator & operator--()
friend const_iterator begin(StringRef path)
Get begin iterator over path.
const StringRef value_type
reverse_iterator rbegin(StringRef path)
Get reverse begin iterator over path.
std::reverse_iterator< const_iterator > reverse_iterator
bool has_root_path(const Twine &path)
Has root path?
bool has_root_name(const Twine &path)
Has root name?
const StringRef relative_path(StringRef path)
Get relative path.
reverse_iterator rend(StringRef path)
Get reverse end iterator over path.
void system_temp_directory(bool erasedOnReboot, SmallVectorImpl< char > &result)
Get the typical temporary directory for the system, e.g., "/var/tmp" or "C:/TEMP".
bool has_extension(const Twine &path)
Has extension?
ptrdiff_t difference_type
const StringRef filename(StringRef path)
Get filename.
const StringRef root_name(StringRef path)
Get root name.
bool has_parent_path(const Twine &path)
Has parent path?