OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #ifndef BIN_FILE_H_ | 5 #ifndef BIN_FILE_H_ |
6 #define BIN_FILE_H_ | 6 #define BIN_FILE_H_ |
7 | 7 |
8 #include <stdlib.h> | 8 #include <stdlib.h> |
9 #include <string.h> | 9 #include <string.h> |
10 #include <stdio.h> | 10 #include <stdio.h> |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
76 kLengthFromPathRequest = 11, | 76 kLengthFromPathRequest = 11, |
77 kLastModifiedRequest = 12, | 77 kLastModifiedRequest = 12, |
78 kFlushRequest = 13, | 78 kFlushRequest = 13, |
79 kReadByteRequest = 14, | 79 kReadByteRequest = 14, |
80 kWriteByteRequest = 15, | 80 kWriteByteRequest = 15, |
81 kReadRequest = 16, | 81 kReadRequest = 16, |
82 kReadIntoRequest = 17, | 82 kReadIntoRequest = 17, |
83 kWriteFromRequest = 18, | 83 kWriteFromRequest = 18, |
84 kCreateLinkRequest = 19, | 84 kCreateLinkRequest = 19, |
85 kDeleteLinkRequest = 20, | 85 kDeleteLinkRequest = 20, |
86 kLinkTargetRequest = 21 | 86 kLinkTargetRequest = 21, |
| 87 kTypeRequest = 22, |
| 88 kIdenticalRequest = 23 |
87 }; | 89 }; |
88 | 90 |
89 ~File(); | 91 ~File(); |
90 | 92 |
91 // Read/Write attempt to transfer num_bytes to/from buffer. It returns | 93 // Read/Write attempt to transfer num_bytes to/from buffer. It returns |
92 // the number of bytes read/written. | 94 // the number of bytes read/written. |
93 int64_t Read(void* buffer, int64_t num_bytes); | 95 int64_t Read(void* buffer, int64_t num_bytes); |
94 int64_t Write(const void* buffer, int64_t num_bytes); | 96 int64_t Write(const void* buffer, int64_t num_bytes); |
95 | 97 |
96 // ReadFully and WriteFully do attempt to transfer num_bytes to/from | 98 // ReadFully and WriteFully do attempt to transfer num_bytes to/from |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
166 | 168 |
167 static NativeService file_service_; | 169 static NativeService file_service_; |
168 | 170 |
169 DISALLOW_COPY_AND_ASSIGN(File); | 171 DISALLOW_COPY_AND_ASSIGN(File); |
170 }; | 172 }; |
171 | 173 |
172 } // namespace bin | 174 } // namespace bin |
173 } // namespace dart | 175 } // namespace dart |
174 | 176 |
175 #endif // BIN_FILE_H_ | 177 #endif // BIN_FILE_H_ |
OLD | NEW |