Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(200)

Side by Side Diff: net/base/file_stream.h

Issue 6314010: Even more reordering the methods in headers and implementation in net/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/base/dnssec_keyset.cc ('k') | net/base/file_stream_posix.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file defines FileStream, a basic interface for reading and writing files 5 // This file defines FileStream, a basic interface for reading and writing files
6 // synchronously or asynchronously with support for seeking to an offset. 6 // synchronously or asynchronously with support for seeking to an offset.
7 // Note that even when used asynchronously, only one operation is supported at 7 // Note that even when used asynchronously, only one operation is supported at
8 // a time. 8 // a time.
9 9
10 #ifndef NET_BASE_FILE_STREAM_H_ 10 #ifndef NET_BASE_FILE_STREAM_H_
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 123
124 // Forces out a filesystem sync on this file to make sure that the file was 124 // Forces out a filesystem sync on this file to make sure that the file was
125 // written out to disk and is not currently sitting in the buffer. This does 125 // written out to disk and is not currently sitting in the buffer. This does
126 // not have to be called, it just forces one to happen at the time of 126 // not have to be called, it just forces one to happen at the time of
127 // calling. 127 // calling.
128 // 128 //
129 /// Returns an error code if the operation could not be performed. 129 /// Returns an error code if the operation could not be performed.
130 // 130 //
131 // This method should not be called if the stream was opened READ_ONLY. 131 // This method should not be called if the stream was opened READ_ONLY.
132 int Flush(); 132 int Flush();
133
133 private: 134 private:
134 class AsyncContext; 135 class AsyncContext;
135 friend class AsyncContext; 136 friend class AsyncContext;
136 137
137 // This member is used to support asynchronous reads. It is non-null when 138 // This member is used to support asynchronous reads. It is non-null when
138 // the FileStream was opened with PLATFORM_FILE_ASYNC. 139 // the FileStream was opened with PLATFORM_FILE_ASYNC.
139 scoped_ptr<AsyncContext> async_context_; 140 scoped_ptr<AsyncContext> async_context_;
140 141
141 base::PlatformFile file_; 142 base::PlatformFile file_;
142 int open_flags_; 143 int open_flags_;
143 bool auto_closed_; 144 bool auto_closed_;
144 145
145 DISALLOW_COPY_AND_ASSIGN(FileStream); 146 DISALLOW_COPY_AND_ASSIGN(FileStream);
146 }; 147 };
147 148
148 } // namespace net 149 } // namespace net
149 150
150 #endif // NET_BASE_FILE_STREAM_H_ 151 #endif // NET_BASE_FILE_STREAM_H_
OLDNEW
« no previous file with comments | « net/base/dnssec_keyset.cc ('k') | net/base/file_stream_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698