| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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_DIRECTORY_H_ | 5 #ifndef BIN_DIRECTORY_H_ |
| 6 #define BIN_DIRECTORY_H_ | 6 #define BIN_DIRECTORY_H_ |
| 7 | 7 |
| 8 #include "bin/builtin.h" | 8 #include "bin/builtin.h" |
| 9 #include "bin/dartutils.h" | 9 #include "bin/dartutils.h" |
| 10 #include "bin/native_service.h" | 10 #include "bin/native_service.h" |
| (...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 256 // This enum must be kept in sync with the request values in | 256 // This enum must be kept in sync with the request values in |
| 257 // directory_impl.dart. | 257 // directory_impl.dart. |
| 258 enum DirectoryRequest { | 258 enum DirectoryRequest { |
| 259 kCreateRequest = 0, | 259 kCreateRequest = 0, |
| 260 kDeleteRequest = 1, | 260 kDeleteRequest = 1, |
| 261 kExistsRequest = 2, | 261 kExistsRequest = 2, |
| 262 kCreateTempRequest = 3, | 262 kCreateTempRequest = 3, |
| 263 kListStartRequest = 4, | 263 kListStartRequest = 4, |
| 264 kListNextRequest = 5, | 264 kListNextRequest = 5, |
| 265 kListStopRequest = 6, | 265 kListStopRequest = 6, |
| 266 kRenameRequest = 7 | 266 kRenameRequest = 7, |
| 267 kResolveSymbolicLinksRequest = 8 |
| 267 }; | 268 }; |
| 268 | 269 |
| 269 static void List(DirectoryListing* listing); | 270 static void List(DirectoryListing* listing); |
| 270 static ExistsResult Exists(const char* path); | 271 static ExistsResult Exists(const char* path); |
| 271 static char* Current(); | 272 static char* Current(); |
| 272 static bool SetCurrent(const char* path); | 273 static bool SetCurrent(const char* path); |
| 273 static bool Create(const char* path); | 274 static bool Create(const char* path); |
| 274 static char* CreateTemp(const char* const_template); | 275 static char* CreateTemp(const char* const_template); |
| 275 static bool Delete(const char* path, bool recursive); | 276 static bool Delete(const char* path, bool recursive); |
| 276 static bool Rename(const char* path, const char* new_path); | 277 static bool Rename(const char* path, const char* new_path); |
| 277 static Dart_Port GetServicePort(); | 278 static Dart_Port GetServicePort(); |
| 278 | 279 |
| 279 private: | 280 private: |
| 280 static NativeService directory_service_; | 281 static NativeService directory_service_; |
| 281 | 282 |
| 282 DISALLOW_ALLOCATION(); | 283 DISALLOW_ALLOCATION(); |
| 283 DISALLOW_IMPLICIT_CONSTRUCTORS(Directory); | 284 DISALLOW_IMPLICIT_CONSTRUCTORS(Directory); |
| 284 }; | 285 }; |
| 285 | 286 |
| 286 } // namespace bin | 287 } // namespace bin |
| 287 } // namespace dart | 288 } // namespace dart |
| 288 | 289 |
| 289 #endif // BIN_DIRECTORY_H_ | 290 #endif // BIN_DIRECTORY_H_ |
| OLD | NEW |