clang API Documentation
The virtual file system interface. More...
#include <VirtualFileSystem.h>
Public Member Functions | |
virtual | ~FileSystem () |
virtual llvm::ErrorOr< Status > | status (const Twine &Path)=0 |
Get the status of the entry at Path , if one exists. | |
virtual llvm::ErrorOr < std::unique_ptr< File > > | openFileForRead (const Twine &Path)=0 |
Get a File object for the file at Path , if one exists. | |
llvm::ErrorOr< std::unique_ptr < llvm::MemoryBuffer > > | getBufferForFile (const Twine &Name, int64_t FileSize=-1, bool RequiresNullTerminator=true, bool IsVolatile=false) |
virtual directory_iterator | dir_begin (const Twine &Dir, std::error_code &EC)=0 |
Get a directory_iterator for Dir . |
The virtual file system interface.
Definition at line 182 of file VirtualFileSystem.h.
FileSystem::~FileSystem | ( | ) | [virtual] |
Definition at line 68 of file VirtualFileSystem.cpp.
virtual directory_iterator clang::vfs::FileSystem::dir_begin | ( | const Twine & | Dir, |
std::error_code & | EC | ||
) | [pure virtual] |
Get a directory_iterator for Dir
.
Implemented in clang::vfs::OverlayFileSystem.
ErrorOr< std::unique_ptr< MemoryBuffer > > FileSystem::getBufferForFile | ( | const Twine & | Name, |
int64_t | FileSize = -1 , |
||
bool | RequiresNullTerminator = true , |
||
bool | IsVolatile = false |
||
) |
This is a convenience method that opens a file, gets its content and then closes the file.
Definition at line 71 of file VirtualFileSystem.cpp.
virtual llvm::ErrorOr<std::unique_ptr<File> > clang::vfs::FileSystem::openFileForRead | ( | const Twine & | Path | ) | [pure virtual] |
Get a File
object for the file at Path
, if one exists.
Implemented in clang::vfs::OverlayFileSystem.
Referenced by clang::FileSystemStatCache::get().
virtual llvm::ErrorOr<Status> clang::vfs::FileSystem::status | ( | const Twine & | Path | ) | [pure virtual] |
Get the status of the entry at Path
, if one exists.
Implemented in clang::vfs::OverlayFileSystem.
Referenced by clang::FileSystemStatCache::get().