summaryrefslogtreecommitdiffstats
path: root/base/platform_file.h
diff options
context:
space:
mode:
authordumi@chromium.org <dumi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-09 22:48:44 +0000
committerdumi@chromium.org <dumi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-09 22:48:44 +0000
commit5438ddec244232cb54ba95455d8745ea577c0578 (patch)
tree8fd26d537d06afc80da95d3c990ae8ec20e59154 /base/platform_file.h
parentc6e7f04cdec7b8a4348e6ff9310c67236deca6d0 (diff)
downloadchromium_src-5438ddec244232cb54ba95455d8745ea577c0578.zip
chromium_src-5438ddec244232cb54ba95455d8745ea577c0578.tar.gz
chromium_src-5438ddec244232cb54ba95455d8745ea577c0578.tar.bz2
Revert 59007 - Adding some utility functions that work on file handles, and adding
the corresponding relays to file_util_proxy. BUG=none TEST=none Review URL: http://codereview.chromium.org/3303007 TBR=dumi@chromium.org Review URL: http://codereview.chromium.org/3371011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@59013 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/platform_file.h')
-rw-r--r--base/platform_file.h28
1 files changed, 1 insertions, 27 deletions
diff --git a/base/platform_file.h b/base/platform_file.h
index abe5cdd..802102c 100644
--- a/base/platform_file.h
+++ b/base/platform_file.h
@@ -40,8 +40,7 @@ enum PlatformFileFlags {
PLATFORM_FILE_TEMPORARY = 512, // Used on Windows only
PLATFORM_FILE_HIDDEN = 1024, // Used on Windows only
PLATFORM_FILE_DELETE_ON_CLOSE = 2048,
- PLATFORM_FILE_TRUNCATE = 4096,
- PLATFORM_FILE_WRITE_ATTRIBUTES = 8192 // Used on Windows only
+ PLATFORM_FILE_TRUNCATE = 4096
};
enum PlatformFileError {
@@ -95,31 +94,6 @@ PlatformFile CreatePlatformFile(const std::wstring& name,
// Closes a file handle
bool ClosePlatformFile(PlatformFile file);
-// Reads the given number of bytes (or until EOF is reached) starting with the
-// given offset. Returns the number of bytes read, or -1 on error.
-int ReadPlatformFile(PlatformFile file, int64 offset, char* data, int size);
-
-// Writes the given buffer into the file at the given offset, overwritting any
-// data that was previously there. Returns the number of bytes written, or -1
-// on error.
-int WritePlatformFile(PlatformFile file, int64 offset,
- const char* data, int size);
-
-// Truncates the given file to the given length. If |length| is greater than
-// the current size of the file, the file is extended with zeros. If the file
-// doesn't exist, |false| is returned.
-bool TruncatePlatformFile(PlatformFile file, int64 length);
-
-// Flushes the buffers of the given file.
-bool FlushPlatformFile(PlatformFile file);
-
-// Touches the given file.
-bool TouchPlatformFile(PlatformFile file, const Time& last_access_time,
- const Time& last_modified_time);
-
-// Returns some information for the given file.
-bool GetPlatformFileInfo(PlatformFile file, PlatformFileInfo* info);
-
// Use this class to pass ownership of a PlatformFile to a receiver that may or
// may not want to accept it. This class does not own the storage for the
// PlatformFile.