summaryrefslogtreecommitdiffstats
path: root/lldb/include/lldb/Host/File.h
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/include/lldb/Host/File.h')
-rw-r--r--lldb/include/lldb/Host/File.h42
1 files changed, 21 insertions, 21 deletions
diff --git a/lldb/include/lldb/Host/File.h b/lldb/include/lldb/Host/File.h
index 35317780f1c..560a655237f 100644
--- a/lldb/include/lldb/Host/File.h
+++ b/lldb/include/lldb/Host/File.h
@@ -12,7 +12,7 @@
#include "lldb/Host/IOObject.h"
#include "lldb/Host/PosixApi.h"
-#include "lldb/Utility/Error.h"
+#include "lldb/Utility/Status.h"
#include "lldb/lldb-private.h"
#include <stdarg.h>
@@ -164,7 +164,7 @@ public:
/// @return
/// A reference to the file specification object.
//------------------------------------------------------------------
- Error GetFileSpec(FileSpec &file_spec) const;
+ Status GetFileSpec(FileSpec &file_spec) const;
//------------------------------------------------------------------
/// Open a file for read/writing with the specified options.
@@ -181,10 +181,10 @@ public:
/// @param[in] permissions
/// Options to use when opening (see File::Permissions)
//------------------------------------------------------------------
- Error Open(const char *path, uint32_t options,
- uint32_t permissions = lldb::eFilePermissionsFileDefault);
+ Status Open(const char *path, uint32_t options,
+ uint32_t permissions = lldb::eFilePermissionsFileDefault);
- Error Close() override;
+ Status Close() override;
void Clear();
@@ -216,7 +216,7 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Read(void *buf, size_t &num_bytes) override;
+ Status Read(void *buf, size_t &num_bytes) override;
//------------------------------------------------------------------
/// Write bytes to a file at the current file position.
@@ -237,7 +237,7 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Write(const void *buf, size_t &num_bytes) override;
+ Status Write(const void *buf, size_t &num_bytes) override;
//------------------------------------------------------------------
/// Seek to an offset relative to the beginning of the file.
@@ -253,13 +253,13 @@ public:
/// beginning of the file.
///
/// @param[in] error_ptr
- /// A pointer to a lldb_private::Error object that will be
+ /// A pointer to a lldb_private::Status object that will be
/// filled in if non-nullptr.
///
/// @return
/// The resulting seek offset, or -1 on error.
//------------------------------------------------------------------
- off_t SeekFromStart(off_t offset, Error *error_ptr = nullptr);
+ off_t SeekFromStart(off_t offset, Status *error_ptr = nullptr);
//------------------------------------------------------------------
/// Seek to an offset relative to the current file position.
@@ -275,13 +275,13 @@ public:
/// current file position.
///
/// @param[in] error_ptr
- /// A pointer to a lldb_private::Error object that will be
+ /// A pointer to a lldb_private::Status object that will be
/// filled in if non-nullptr.
///
/// @return
/// The resulting seek offset, or -1 on error.
//------------------------------------------------------------------
- off_t SeekFromCurrent(off_t offset, Error *error_ptr = nullptr);
+ off_t SeekFromCurrent(off_t offset, Status *error_ptr = nullptr);
//------------------------------------------------------------------
/// Seek to an offset relative to the end of the file.
@@ -298,13 +298,13 @@ public:
/// absolute file offset.
///
/// @param[in] error_ptr
- /// A pointer to a lldb_private::Error object that will be
+ /// A pointer to a lldb_private::Status object that will be
/// filled in if non-nullptr.
///
/// @return
/// The resulting seek offset, or -1 on error.
//------------------------------------------------------------------
- off_t SeekFromEnd(off_t offset, Error *error_ptr = nullptr);
+ off_t SeekFromEnd(off_t offset, Status *error_ptr = nullptr);
//------------------------------------------------------------------
/// Read bytes from a file from the specified file offset.
@@ -329,7 +329,7 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Read(void *dst, size_t &num_bytes, off_t &offset);
+ Status Read(void *dst, size_t &num_bytes, off_t &offset);
//------------------------------------------------------------------
/// Read bytes from a file from the specified file offset.
@@ -360,8 +360,8 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Read(size_t &num_bytes, off_t &offset, bool null_terminate,
- lldb::DataBufferSP &data_buffer_sp);
+ Status Read(size_t &num_bytes, off_t &offset, bool null_terminate,
+ lldb::DataBufferSP &data_buffer_sp);
//------------------------------------------------------------------
/// Write bytes to a file at the specified file offset.
@@ -388,7 +388,7 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Write(const void *src, size_t &num_bytes, off_t &offset);
+ Status Write(const void *src, size_t &num_bytes, off_t &offset);
//------------------------------------------------------------------
/// Flush the current stream
@@ -397,7 +397,7 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Flush();
+ Status Flush();
//------------------------------------------------------------------
/// Sync to disk.
@@ -406,7 +406,7 @@ public:
/// An error object that indicates success or the reason for
/// failure.
//------------------------------------------------------------------
- Error Sync();
+ Status Sync();
//------------------------------------------------------------------
/// Get the permissions for a this file.
@@ -415,9 +415,9 @@ public:
/// Bits logical OR'ed together from the permission bits defined
/// in lldb_private::File::Permissions.
//------------------------------------------------------------------
- uint32_t GetPermissions(Error &error) const;
+ uint32_t GetPermissions(Status &error) const;
- static uint32_t GetPermissions(const FileSpec &file_spec, Error &error);
+ static uint32_t GetPermissions(const FileSpec &file_spec, Status &error);
//------------------------------------------------------------------
/// Return true if this file is interactive.
OpenPOWER on IntegriCloud