OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 #ifndef PPB_FILESYSTEM_PROVIDER_API_H |
| 5 #define PPB_FILESYSTEM_PROVIDER_API_H |
| 6 |
| 7 #include "base/memory/ref_counted.h" |
| 8 #include "ppapi/c/dev/ppb_filesystemprovider_dev.h" |
| 9 #include "ppapi/thunk/ppapi_thunk_export.h" |
| 10 |
| 11 namespace ppapi { |
| 12 class TrackedCallback; |
| 13 |
| 14 namespace thunk { |
| 15 |
| 16 class PPAPI_THUNK_EXPORT PPB_FilesystemProvider_API { |
| 17 public: |
| 18 virtual ~PPB_FilesystemProvider_API() {} |
| 19 |
| 20 virtual int32_t Mount( |
| 21 struct PP_Var filesystem_id, |
| 22 struct PP_Var display_name, |
| 23 PP_Bool writable, |
| 24 int32_t opened_files_limit, |
| 25 scoped_refptr<TrackedCallback> callback)=0; |
| 26 |
| 27 virtual int32_t Unmount( |
| 28 struct PP_Var filesystem_id, |
| 29 scoped_refptr<TrackedCallback> callback)=0; |
| 30 |
| 31 virtual int32_t Notify( |
| 32 struct PP_Var notify_options )=0; |
| 33 |
| 34 virtual int32_t SendSuccessResponse( |
| 35 PP_OperationType_Dev operation_type, |
| 36 int32_t request_id)=0; |
| 37 virtual int32_t SendErrorResponse( |
| 38 PP_OperationType_Dev operation_type, |
| 39 int32_t error, |
| 40 int32_t request_id)=0; |
| 41 |
| 42 virtual int32_t SendMetadataSuccessResponse( |
| 43 struct PP_Var metadata, |
| 44 int32_t request_id)=0; |
| 45 |
| 46 virtual int32_t SendReadDirectorySuccessResponse( |
| 47 struct PP_Var entries, |
| 48 PP_Bool has_more, |
| 49 int32_t request_id)=0; |
| 50 |
| 51 virtual int32_t SendReadFileSuccessResponse( |
| 52 uint32_t data_size, |
| 53 const void* data, |
| 54 PP_Bool has_more, |
| 55 int32_t request_id)=0; |
| 56 virtual int32_t GetNextRequest( PP_FilesystemRequest* request, |
| 57 scoped_refptr<TrackedCallback> callback)=0; |
| 58 virtual int32_t ReleaseRequestBuffer(int32_t request_id)=0; |
| 59 |
| 60 }; |
| 61 |
| 62 } // thunk namespace |
| 63 } // ppapi namespace |
| 64 |
| 65 #endif // PPB_FILESYSTEM_PROVIDER_API_H |
| 66 |
OLD | NEW |