1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
|
// Copyright 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Internal, used by fileSystemProvider's custom bindings. These functions are
// called when events' callbacks are invoked.
[platforms=("chromeos"),
implemented_in="chrome/browser/chromeos/extensions/file_system_provider/file_system_provider_api.h", nodoc]
namespace fileSystemProviderInternal {
interface Functions {
// Internal. Success callback of the <code>onUnmountRequested</code>
// event. Must be called when unmounting is completed.
static void unmountRequestedSuccess(long fileSystemId,
long requestId);
// Internal. Error callback of the <code>onUnmountRequested</code>
// event. Must be called if unmounting fails.
static void unmountRequestedError(
long fileSystemId,
long requestId,
fileSystemProvider.ProviderError error);
// Internal. Success callback of the <code>onGetMetadataRequested</code>
// event. Must be called if metadata is available.
static void getMetadataRequestedSuccess(
long fileSystemId,
long requestId,
fileSystemProvider.EntryMetadata metadata);
// Internal. Error callback of the <code>onGetMetadataRequested</code>
// event. Must be called when obtaining metadata fails.
static void getMetadataRequestedError(
long fileSystemId,
long requestId,
fileSystemProvider.ProviderError error);
// Internal. Success callback of the <code>onReadDirectoryRequested</code>
// event. Can be called multiple times per request.
static void readDirectoryRequestedSuccess(
long fileSystemId,
long requestId,
fileSystemProvider.EntryMetadata[] entries,
boolean hasNext);
// Internal. Error callback of the <code>onReadDirectoryRequested</code>
// event. Must be called when reading a directory fails.
static void readDirectoryRequestedError(
long fileSystemId,
long requestId,
fileSystemProvider.ProviderError error);
// Internal. Success callback of the <code>onOpenFileRequested</code> event.
// Must be called, when opening succeeds.
static void openFileRequestedSuccess(
long fileSystemId,
long requestId);
// Internal. Error callback of the <code>onOpenFileRequested</code> event.
// Must be called when opening fails.
static void openFileRequestedError(
long fileSystemId,
long requestId,
fileSystemProvider.ProviderError error);
// Internal. Success callback of the <code>onCloseFileRequested</code>
// event. Must be called, when closing succeeds.
static void closeFileRequestedSuccess(
long fileSystemId,
long requestId);
// Internal. Error callback of the <code>onCloseFileRequested</code> event.
// Must be called when closing fails.
static void closeFileRequestedError(
long fileSystemId,
long requestId,
fileSystemProvider.ProviderError error);
// Internal. Success callback of the <code>onReadFileRequested</code>
// event. Can be called multiple times per request.
static void readFileRequestedSuccess(
long fileSystemId,
long requestId,
DOMString data,
boolean hasNext);
// Internal. Error callback of the <code>onReadFileRequested</code>
// event. Must be called when reading a file fails.
static void readFileRequestedError(
long fileSystemId,
long requestId,
fileSystemProvider.ProviderError error);
};
};
|