LLVM API Documentation
#include <Path.h>


Public Member Functions | |
Constructors | |
| PathWithStatus () | |
| Default constructor. | |
| PathWithStatus (const PathWithStatus &that) | |
| Copy constructor. | |
| PathWithStatus (const Path &other) | |
| Path constructor. | |
| PathWithStatus (const std::string &p) | |
| Construct a Path from a string. | |
| PathWithStatus (const char *StrStart, unsigned StrLen) | |
| Construct a Path from a string. | |
| PathWithStatus & | operator= (const PathWithStatus &that) |
| Assignment Operator. | |
| PathWithStatus & | operator= (const Path &that) |
| Assignment Operator. | |
Methods | |
| const FileStatus * | getFileStatus (bool forceUpdate=false, std::string *Error=0) const |
| Get file status. | |
This class is identical to Path class except it allows you to obtain the file status of the Path as well. The reason for the distinction is one of efficiency. First, the file status requires additional space and the space is incorporated directly into PathWithStatus without an additional malloc. Second, obtaining status information is an expensive operation on most operating systems so we want to be careful and explicity about where we allow this operation in LLVM.
Definition at line 594 of file Path.h.
| llvm::sys::PathWithStatus::PathWithStatus | ( | ) | [inline] |
| llvm::sys::PathWithStatus::PathWithStatus | ( | const PathWithStatus & | that | ) | [inline] |
| llvm::sys::PathWithStatus::PathWithStatus | ( | const Path & | other | ) | [inline] |
| llvm::sys::PathWithStatus::PathWithStatus | ( | const std::string & | p | ) | [inline, explicit] |
| llvm::sys::PathWithStatus::PathWithStatus | ( | const char * | StrStart, | |
| unsigned | StrLen | |||
| ) | [inline, explicit] |
Construct a Path from a string.
This constructor will accept a character range as a path. No checking is done on this path to determine if it is valid. To determine validity of the path, use the isValid method.
| StrStart | Pointer to the first character of the path |
| StrLen | Length of the path. |
| PathWithStatus& llvm::sys::PathWithStatus::operator= | ( | const PathWithStatus & | that | ) | [inline] |
| PathWithStatus& llvm::sys::PathWithStatus::operator= | ( | const Path & | that | ) | [inline] |
| const FileStatus* llvm::sys::PathWithStatus::getFileStatus | ( | bool | forceUpdate = false, |
|
| std::string * | Error = 0 | |||
| ) | const |
Get file status.
This function returns status information about the file. The type of path (file or directory) is updated to reflect the actual contents of the file system.
a pointer to a FileStatus structure on success.
| forceUpdate | Force an update from the file system |
| Error | Optional place to return an error msg. |
Referenced by llvm::Archive::addFileBefore(), llvm::DiffFilesWithTolerance(), ExpandResponseFiles(), and llvm::ArchiveMember::replaceWith().
This web site is hosted by the Computer Science Department at the University of Illinois at Urbana-Champaign.