@firebase/storage 0.13.3 → 0.13.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/dist/index.browser.cjs.js +3571 -3571
  2. package/dist/index.browser.cjs.js.map +1 -1
  3. package/dist/index.cjs.js +3571 -3571
  4. package/dist/index.cjs.js.map +1 -1
  5. package/dist/index.esm2017.js +3571 -3571
  6. package/dist/index.esm2017.js.map +1 -1
  7. package/dist/index.node.cjs.js +3596 -3596
  8. package/dist/index.node.cjs.js.map +1 -1
  9. package/dist/node-esm/index.node.esm.js +3596 -3596
  10. package/dist/node-esm/index.node.esm.js.map +1 -1
  11. package/dist/node-esm/src/api.browser.d.ts +47 -47
  12. package/dist/node-esm/src/api.d.ts +200 -200
  13. package/dist/node-esm/src/api.node.d.ts +47 -47
  14. package/dist/node-esm/src/constants.d.ts +20 -20
  15. package/dist/node-esm/src/implementation/async.d.ts +22 -22
  16. package/dist/node-esm/src/implementation/backoff.d.ts +43 -43
  17. package/dist/node-esm/src/implementation/blob.d.ts +34 -34
  18. package/dist/node-esm/src/implementation/connection.d.ts +56 -56
  19. package/dist/node-esm/src/implementation/constants.d.ts +48 -48
  20. package/dist/node-esm/src/implementation/error.d.ts +126 -126
  21. package/dist/node-esm/src/implementation/failrequest.d.ts +29 -29
  22. package/dist/node-esm/src/implementation/fs.d.ts +17 -17
  23. package/dist/node-esm/src/implementation/json.d.ts +7 -7
  24. package/dist/node-esm/src/implementation/list.d.ts +19 -19
  25. package/dist/node-esm/src/implementation/location.d.ts +32 -32
  26. package/dist/node-esm/src/implementation/metadata.d.ts +40 -40
  27. package/dist/node-esm/src/implementation/observer.d.ts +47 -47
  28. package/dist/node-esm/src/implementation/path.d.ts +31 -31
  29. package/dist/node-esm/src/implementation/request.d.ts +47 -47
  30. package/dist/node-esm/src/implementation/requestinfo.d.ts +73 -73
  31. package/dist/node-esm/src/implementation/requests.d.ts +84 -84
  32. package/dist/node-esm/src/implementation/string.d.ts +73 -73
  33. package/dist/node-esm/src/implementation/taskenums.d.ts +77 -77
  34. package/dist/node-esm/src/implementation/type.d.ts +23 -23
  35. package/dist/node-esm/src/implementation/url.d.ts +22 -22
  36. package/dist/node-esm/src/implementation/utils.d.ts +23 -23
  37. package/dist/node-esm/src/index.d.ts +7 -7
  38. package/dist/node-esm/src/index.node.d.ts +7 -7
  39. package/dist/node-esm/src/list.d.ts +41 -41
  40. package/dist/node-esm/src/metadata.d.ts +27 -27
  41. package/dist/node-esm/src/platform/base64.d.ts +20 -20
  42. package/dist/node-esm/src/platform/browser/base64.d.ts +19 -19
  43. package/dist/node-esm/src/platform/browser/connection.d.ts +55 -55
  44. package/dist/node-esm/src/platform/connection.d.ts +22 -22
  45. package/dist/node-esm/src/platform/node/base64.d.ts +19 -19
  46. package/dist/node-esm/src/platform/node/connection.d.ts +58 -59
  47. package/dist/node-esm/src/public-types.d.ts +424 -424
  48. package/dist/node-esm/src/reference.d.ts +208 -208
  49. package/dist/node-esm/src/service.d.ts +130 -130
  50. package/dist/node-esm/src/task.d.ts +148 -148
  51. package/dist/node-esm/test/browser/blob.test.d.ts +17 -17
  52. package/dist/node-esm/test/browser/connection.test.d.ts +17 -17
  53. package/dist/node-esm/test/browser/string.browser.test.d.ts +17 -17
  54. package/dist/node-esm/test/integration/integration.test.d.ts +24 -24
  55. package/dist/node-esm/test/node/connection.test.d.ts +17 -17
  56. package/dist/node-esm/test/node/stream.test.d.ts +17 -17
  57. package/dist/node-esm/test/unit/connection.d.ts +47 -47
  58. package/dist/node-esm/test/unit/index.test.d.ts +4 -4
  59. package/dist/node-esm/test/unit/location.test.d.ts +1 -1
  60. package/dist/node-esm/test/unit/reference.test.d.ts +1 -1
  61. package/dist/node-esm/test/unit/request.test.d.ts +1 -1
  62. package/dist/node-esm/test/unit/requests.test.d.ts +1 -1
  63. package/dist/node-esm/test/unit/service.test.d.ts +1 -1
  64. package/dist/node-esm/test/unit/string.test.d.ts +1 -1
  65. package/dist/node-esm/test/unit/task.test.d.ts +1 -1
  66. package/dist/node-esm/test/unit/testshared.d.ts +60 -60
  67. package/dist/node-esm/test/unit/utils.test.d.ts +17 -17
  68. package/dist/src/api.browser.d.ts +47 -47
  69. package/dist/src/api.d.ts +200 -200
  70. package/dist/src/api.node.d.ts +47 -47
  71. package/dist/src/constants.d.ts +20 -20
  72. package/dist/src/implementation/async.d.ts +22 -22
  73. package/dist/src/implementation/backoff.d.ts +43 -43
  74. package/dist/src/implementation/blob.d.ts +34 -34
  75. package/dist/src/implementation/connection.d.ts +56 -56
  76. package/dist/src/implementation/constants.d.ts +48 -48
  77. package/dist/src/implementation/error.d.ts +126 -126
  78. package/dist/src/implementation/failrequest.d.ts +29 -29
  79. package/dist/src/implementation/fs.d.ts +17 -17
  80. package/dist/src/implementation/json.d.ts +7 -7
  81. package/dist/src/implementation/list.d.ts +19 -19
  82. package/dist/src/implementation/location.d.ts +32 -32
  83. package/dist/src/implementation/metadata.d.ts +40 -40
  84. package/dist/src/implementation/observer.d.ts +47 -47
  85. package/dist/src/implementation/path.d.ts +31 -31
  86. package/dist/src/implementation/request.d.ts +47 -47
  87. package/dist/src/implementation/requestinfo.d.ts +73 -73
  88. package/dist/src/implementation/requests.d.ts +84 -84
  89. package/dist/src/implementation/string.d.ts +73 -73
  90. package/dist/src/implementation/taskenums.d.ts +77 -77
  91. package/dist/src/implementation/type.d.ts +23 -23
  92. package/dist/src/implementation/url.d.ts +22 -22
  93. package/dist/src/implementation/utils.d.ts +23 -23
  94. package/dist/src/index.d.ts +7 -7
  95. package/dist/src/index.node.d.ts +7 -7
  96. package/dist/src/list.d.ts +41 -41
  97. package/dist/src/metadata.d.ts +27 -27
  98. package/dist/src/platform/base64.d.ts +20 -20
  99. package/dist/src/platform/browser/base64.d.ts +19 -19
  100. package/dist/src/platform/browser/connection.d.ts +55 -55
  101. package/dist/src/platform/connection.d.ts +22 -22
  102. package/dist/src/platform/node/base64.d.ts +19 -19
  103. package/dist/src/platform/node/connection.d.ts +58 -59
  104. package/dist/src/public-types.d.ts +424 -424
  105. package/dist/src/reference.d.ts +208 -208
  106. package/dist/src/service.d.ts +130 -130
  107. package/dist/src/task.d.ts +148 -148
  108. package/dist/test/browser/blob.test.d.ts +17 -17
  109. package/dist/test/browser/connection.test.d.ts +17 -17
  110. package/dist/test/browser/string.browser.test.d.ts +17 -17
  111. package/dist/test/integration/integration.test.d.ts +24 -24
  112. package/dist/test/node/connection.test.d.ts +17 -17
  113. package/dist/test/node/stream.test.d.ts +17 -17
  114. package/dist/test/unit/connection.d.ts +47 -47
  115. package/dist/test/unit/index.test.d.ts +4 -4
  116. package/dist/test/unit/location.test.d.ts +1 -1
  117. package/dist/test/unit/reference.test.d.ts +1 -1
  118. package/dist/test/unit/request.test.d.ts +1 -1
  119. package/dist/test/unit/requests.test.d.ts +1 -1
  120. package/dist/test/unit/service.test.d.ts +1 -1
  121. package/dist/test/unit/string.test.d.ts +1 -1
  122. package/dist/test/unit/task.test.d.ts +1 -1
  123. package/dist/test/unit/testshared.d.ts +60 -60
  124. package/dist/test/unit/utils.test.d.ts +17 -17
  125. package/package.json +6 -6
@@ -1,208 +1,208 @@
1
- /**
2
- * @license
3
- * Copyright 2019 Google LLC
4
- *
5
- * Licensed under the Apache License, Version 2.0 (the "License");
6
- * you may not use this file except in compliance with the License.
7
- * You may obtain a copy of the License at
8
- *
9
- * http://www.apache.org/licenses/LICENSE-2.0
10
- *
11
- * Unless required by applicable law or agreed to in writing, software
12
- * distributed under the License is distributed on an "AS IS" BASIS,
13
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
- * See the License for the specific language governing permissions and
15
- * limitations under the License.
16
- */
17
- import { Location } from './implementation/location';
18
- import { ListOptions, UploadResult } from './public-types';
19
- import { StringFormat } from './implementation/string';
20
- import { Metadata } from './metadata';
21
- import { FirebaseStorageImpl } from './service';
22
- import { ListResult } from './list';
23
- import { UploadTask } from './task';
24
- /**
25
- * Provides methods to interact with a bucket in the Firebase Storage service.
26
- * @internal
27
- * @param _location - An fbs.location, or the URL at
28
- * which to base this object, in one of the following forms:
29
- * gs://<bucket>/<object-path>
30
- * http[s]://firebasestorage.googleapis.com/
31
- * <api-version>/b/<bucket>/o/<object-path>
32
- * Any query or fragment strings will be ignored in the http[s]
33
- * format. If no value is passed, the storage object will use a URL based on
34
- * the project ID of the base firebase.App instance.
35
- */
36
- export declare class Reference {
37
- private _service;
38
- _location: Location;
39
- constructor(_service: FirebaseStorageImpl, location: string | Location);
40
- /**
41
- * Returns the URL for the bucket and path this object references,
42
- * in the form gs://<bucket>/<object-path>
43
- * @override
44
- */
45
- toString(): string;
46
- protected _newRef(service: FirebaseStorageImpl, location: Location): Reference;
47
- /**
48
- * A reference to the root of this object's bucket.
49
- */
50
- get root(): Reference;
51
- /**
52
- * The name of the bucket containing this reference's object.
53
- */
54
- get bucket(): string;
55
- /**
56
- * The full path of this object.
57
- */
58
- get fullPath(): string;
59
- /**
60
- * The short name of this object, which is the last component of the full path.
61
- * For example, if fullPath is 'full/path/image.png', name is 'image.png'.
62
- */
63
- get name(): string;
64
- /**
65
- * The `StorageService` instance this `StorageReference` is associated with.
66
- */
67
- get storage(): FirebaseStorageImpl;
68
- /**
69
- * A `StorageReference` pointing to the parent location of this `StorageReference`, or null if
70
- * this reference is the root.
71
- */
72
- get parent(): Reference | null;
73
- /**
74
- * Utility function to throw an error in methods that do not accept a root reference.
75
- */
76
- _throwIfRoot(name: string): void;
77
- }
78
- /**
79
- * Download the bytes at the object's location.
80
- * @returns A Promise containing the downloaded bytes.
81
- */
82
- export declare function getBytesInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<ArrayBuffer>;
83
- /**
84
- * Download the bytes at the object's location.
85
- * @returns A Promise containing the downloaded blob.
86
- */
87
- export declare function getBlobInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<Blob>;
88
- /** Stream the bytes at the object's location. */
89
- export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): ReadableStream;
90
- /**
91
- * Uploads data to this object's location.
92
- * The upload is not resumable.
93
- *
94
- * @param ref - StorageReference where data should be uploaded.
95
- * @param data - The data to upload.
96
- * @param metadata - Metadata for the newly uploaded data.
97
- * @returns A Promise containing an UploadResult
98
- */
99
- export declare function uploadBytes(ref: Reference, data: Blob | Uint8Array | ArrayBuffer, metadata?: Metadata): Promise<UploadResult>;
100
- /**
101
- * Uploads data to this object's location.
102
- * The upload can be paused and resumed, and exposes progress updates.
103
- * @public
104
- * @param ref - StorageReference where data should be uploaded.
105
- * @param data - The data to upload.
106
- * @param metadata - Metadata for the newly uploaded data.
107
- * @returns An UploadTask
108
- */
109
- export declare function uploadBytesResumable(ref: Reference, data: Blob | Uint8Array | ArrayBuffer, metadata?: Metadata): UploadTask;
110
- /**
111
- * Uploads a string to this object's location.
112
- * The upload is not resumable.
113
- * @public
114
- * @param ref - StorageReference where string should be uploaded.
115
- * @param value - The string to upload.
116
- * @param format - The format of the string to upload.
117
- * @param metadata - Metadata for the newly uploaded string.
118
- * @returns A Promise containing an UploadResult
119
- */
120
- export declare function uploadString(ref: Reference, value: string, format?: StringFormat, metadata?: Metadata): Promise<UploadResult>;
121
- /**
122
- * List all items (files) and prefixes (folders) under this storage reference.
123
- *
124
- * This is a helper method for calling list() repeatedly until there are
125
- * no more results. The default pagination size is 1000.
126
- *
127
- * Note: The results may not be consistent if objects are changed while this
128
- * operation is running.
129
- *
130
- * Warning: listAll may potentially consume too many resources if there are
131
- * too many results.
132
- * @public
133
- * @param ref - StorageReference to get list from.
134
- *
135
- * @returns A Promise that resolves with all the items and prefixes under
136
- * the current storage reference. `prefixes` contains references to
137
- * sub-directories and `items` contains references to objects in this
138
- * folder. `nextPageToken` is never returned.
139
- */
140
- export declare function listAll(ref: Reference): Promise<ListResult>;
141
- /**
142
- * List items (files) and prefixes (folders) under this storage reference.
143
- *
144
- * List API is only available for Firebase Rules Version 2.
145
- *
146
- * GCS is a key-blob store. Firebase Storage imposes the semantic of '/'
147
- * delimited folder structure.
148
- * Refer to GCS's List API if you want to learn more.
149
- *
150
- * To adhere to Firebase Rules's Semantics, Firebase Storage does not
151
- * support objects whose paths end with "/" or contain two consecutive
152
- * "/"s. Firebase Storage List API will filter these unsupported objects.
153
- * list() may fail if there are too many unsupported objects in the bucket.
154
- * @public
155
- *
156
- * @param ref - StorageReference to get list from.
157
- * @param options - See ListOptions for details.
158
- * @returns A Promise that resolves with the items and prefixes.
159
- * `prefixes` contains references to sub-folders and `items`
160
- * contains references to objects in this folder. `nextPageToken`
161
- * can be used to get the rest of the results.
162
- */
163
- export declare function list(ref: Reference, options?: ListOptions | null): Promise<ListResult>;
164
- /**
165
- * A `Promise` that resolves with the metadata for this object. If this
166
- * object doesn't exist or metadata cannot be retrieved, the promise is
167
- * rejected.
168
- * @public
169
- * @param ref - StorageReference to get metadata from.
170
- */
171
- export declare function getMetadata(ref: Reference): Promise<Metadata>;
172
- /**
173
- * Updates the metadata for this object.
174
- * @public
175
- * @param ref - StorageReference to update metadata for.
176
- * @param metadata - The new metadata for the object.
177
- * Only values that have been explicitly set will be changed. Explicitly
178
- * setting a value to null will remove the metadata.
179
- * @returns A `Promise` that resolves
180
- * with the new metadata for this object.
181
- * See `firebaseStorage.Reference.prototype.getMetadata`
182
- */
183
- export declare function updateMetadata(ref: Reference, metadata: Partial<Metadata>): Promise<Metadata>;
184
- /**
185
- * Returns the download URL for the given Reference.
186
- * @public
187
- * @returns A `Promise` that resolves with the download
188
- * URL for this object.
189
- */
190
- export declare function getDownloadURL(ref: Reference): Promise<string>;
191
- /**
192
- * Deletes the object at this location.
193
- * @public
194
- * @param ref - StorageReference for object to delete.
195
- * @returns A `Promise` that resolves if the deletion succeeds.
196
- */
197
- export declare function deleteObject(ref: Reference): Promise<void>;
198
- /**
199
- * Returns reference for object obtained by appending `childPath` to `ref`.
200
- *
201
- * @param ref - StorageReference to get child of.
202
- * @param childPath - Child path from provided ref.
203
- * @returns A reference to the object obtained by
204
- * appending childPath, removing any duplicate, beginning, or trailing
205
- * slashes.
206
- *
207
- */
208
- export declare function _getChild(ref: Reference, childPath: string): Reference;
1
+ /**
2
+ * @license
3
+ * Copyright 2019 Google LLC
4
+ *
5
+ * Licensed under the Apache License, Version 2.0 (the "License");
6
+ * you may not use this file except in compliance with the License.
7
+ * You may obtain a copy of the License at
8
+ *
9
+ * http://www.apache.org/licenses/LICENSE-2.0
10
+ *
11
+ * Unless required by applicable law or agreed to in writing, software
12
+ * distributed under the License is distributed on an "AS IS" BASIS,
13
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ * See the License for the specific language governing permissions and
15
+ * limitations under the License.
16
+ */
17
+ import { Location } from './implementation/location';
18
+ import { ListOptions, UploadResult } from './public-types';
19
+ import { StringFormat } from './implementation/string';
20
+ import { Metadata } from './metadata';
21
+ import { FirebaseStorageImpl } from './service';
22
+ import { ListResult } from './list';
23
+ import { UploadTask } from './task';
24
+ /**
25
+ * Provides methods to interact with a bucket in the Firebase Storage service.
26
+ * @internal
27
+ * @param _location - An fbs.location, or the URL at
28
+ * which to base this object, in one of the following forms:
29
+ * gs://<bucket>/<object-path>
30
+ * http[s]://firebasestorage.googleapis.com/
31
+ * <api-version>/b/<bucket>/o/<object-path>
32
+ * Any query or fragment strings will be ignored in the http[s]
33
+ * format. If no value is passed, the storage object will use a URL based on
34
+ * the project ID of the base firebase.App instance.
35
+ */
36
+ export declare class Reference {
37
+ private _service;
38
+ _location: Location;
39
+ constructor(_service: FirebaseStorageImpl, location: string | Location);
40
+ /**
41
+ * Returns the URL for the bucket and path this object references,
42
+ * in the form gs://<bucket>/<object-path>
43
+ * @override
44
+ */
45
+ toString(): string;
46
+ protected _newRef(service: FirebaseStorageImpl, location: Location): Reference;
47
+ /**
48
+ * A reference to the root of this object's bucket.
49
+ */
50
+ get root(): Reference;
51
+ /**
52
+ * The name of the bucket containing this reference's object.
53
+ */
54
+ get bucket(): string;
55
+ /**
56
+ * The full path of this object.
57
+ */
58
+ get fullPath(): string;
59
+ /**
60
+ * The short name of this object, which is the last component of the full path.
61
+ * For example, if fullPath is 'full/path/image.png', name is 'image.png'.
62
+ */
63
+ get name(): string;
64
+ /**
65
+ * The `StorageService` instance this `StorageReference` is associated with.
66
+ */
67
+ get storage(): FirebaseStorageImpl;
68
+ /**
69
+ * A `StorageReference` pointing to the parent location of this `StorageReference`, or null if
70
+ * this reference is the root.
71
+ */
72
+ get parent(): Reference | null;
73
+ /**
74
+ * Utility function to throw an error in methods that do not accept a root reference.
75
+ */
76
+ _throwIfRoot(name: string): void;
77
+ }
78
+ /**
79
+ * Download the bytes at the object's location.
80
+ * @returns A Promise containing the downloaded bytes.
81
+ */
82
+ export declare function getBytesInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<ArrayBuffer>;
83
+ /**
84
+ * Download the bytes at the object's location.
85
+ * @returns A Promise containing the downloaded blob.
86
+ */
87
+ export declare function getBlobInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<Blob>;
88
+ /** Stream the bytes at the object's location. */
89
+ export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): ReadableStream;
90
+ /**
91
+ * Uploads data to this object's location.
92
+ * The upload is not resumable.
93
+ *
94
+ * @param ref - StorageReference where data should be uploaded.
95
+ * @param data - The data to upload.
96
+ * @param metadata - Metadata for the newly uploaded data.
97
+ * @returns A Promise containing an UploadResult
98
+ */
99
+ export declare function uploadBytes(ref: Reference, data: Blob | Uint8Array | ArrayBuffer, metadata?: Metadata): Promise<UploadResult>;
100
+ /**
101
+ * Uploads data to this object's location.
102
+ * The upload can be paused and resumed, and exposes progress updates.
103
+ * @public
104
+ * @param ref - StorageReference where data should be uploaded.
105
+ * @param data - The data to upload.
106
+ * @param metadata - Metadata for the newly uploaded data.
107
+ * @returns An UploadTask
108
+ */
109
+ export declare function uploadBytesResumable(ref: Reference, data: Blob | Uint8Array | ArrayBuffer, metadata?: Metadata): UploadTask;
110
+ /**
111
+ * Uploads a string to this object's location.
112
+ * The upload is not resumable.
113
+ * @public
114
+ * @param ref - StorageReference where string should be uploaded.
115
+ * @param value - The string to upload.
116
+ * @param format - The format of the string to upload.
117
+ * @param metadata - Metadata for the newly uploaded string.
118
+ * @returns A Promise containing an UploadResult
119
+ */
120
+ export declare function uploadString(ref: Reference, value: string, format?: StringFormat, metadata?: Metadata): Promise<UploadResult>;
121
+ /**
122
+ * List all items (files) and prefixes (folders) under this storage reference.
123
+ *
124
+ * This is a helper method for calling list() repeatedly until there are
125
+ * no more results. The default pagination size is 1000.
126
+ *
127
+ * Note: The results may not be consistent if objects are changed while this
128
+ * operation is running.
129
+ *
130
+ * Warning: listAll may potentially consume too many resources if there are
131
+ * too many results.
132
+ * @public
133
+ * @param ref - StorageReference to get list from.
134
+ *
135
+ * @returns A Promise that resolves with all the items and prefixes under
136
+ * the current storage reference. `prefixes` contains references to
137
+ * sub-directories and `items` contains references to objects in this
138
+ * folder. `nextPageToken` is never returned.
139
+ */
140
+ export declare function listAll(ref: Reference): Promise<ListResult>;
141
+ /**
142
+ * List items (files) and prefixes (folders) under this storage reference.
143
+ *
144
+ * List API is only available for Firebase Rules Version 2.
145
+ *
146
+ * GCS is a key-blob store. Firebase Storage imposes the semantic of '/'
147
+ * delimited folder structure.
148
+ * Refer to GCS's List API if you want to learn more.
149
+ *
150
+ * To adhere to Firebase Rules's Semantics, Firebase Storage does not
151
+ * support objects whose paths end with "/" or contain two consecutive
152
+ * "/"s. Firebase Storage List API will filter these unsupported objects.
153
+ * list() may fail if there are too many unsupported objects in the bucket.
154
+ * @public
155
+ *
156
+ * @param ref - StorageReference to get list from.
157
+ * @param options - See ListOptions for details.
158
+ * @returns A Promise that resolves with the items and prefixes.
159
+ * `prefixes` contains references to sub-folders and `items`
160
+ * contains references to objects in this folder. `nextPageToken`
161
+ * can be used to get the rest of the results.
162
+ */
163
+ export declare function list(ref: Reference, options?: ListOptions | null): Promise<ListResult>;
164
+ /**
165
+ * A `Promise` that resolves with the metadata for this object. If this
166
+ * object doesn't exist or metadata cannot be retrieved, the promise is
167
+ * rejected.
168
+ * @public
169
+ * @param ref - StorageReference to get metadata from.
170
+ */
171
+ export declare function getMetadata(ref: Reference): Promise<Metadata>;
172
+ /**
173
+ * Updates the metadata for this object.
174
+ * @public
175
+ * @param ref - StorageReference to update metadata for.
176
+ * @param metadata - The new metadata for the object.
177
+ * Only values that have been explicitly set will be changed. Explicitly
178
+ * setting a value to null will remove the metadata.
179
+ * @returns A `Promise` that resolves
180
+ * with the new metadata for this object.
181
+ * See `firebaseStorage.Reference.prototype.getMetadata`
182
+ */
183
+ export declare function updateMetadata(ref: Reference, metadata: Partial<Metadata>): Promise<Metadata>;
184
+ /**
185
+ * Returns the download URL for the given Reference.
186
+ * @public
187
+ * @returns A `Promise` that resolves with the download
188
+ * URL for this object.
189
+ */
190
+ export declare function getDownloadURL(ref: Reference): Promise<string>;
191
+ /**
192
+ * Deletes the object at this location.
193
+ * @public
194
+ * @param ref - StorageReference for object to delete.
195
+ * @returns A `Promise` that resolves if the deletion succeeds.
196
+ */
197
+ export declare function deleteObject(ref: Reference): Promise<void>;
198
+ /**
199
+ * Returns reference for object obtained by appending `childPath` to `ref`.
200
+ *
201
+ * @param ref - StorageReference to get child of.
202
+ * @param childPath - Child path from provided ref.
203
+ * @returns A reference to the object obtained by
204
+ * appending childPath, removing any duplicate, beginning, or trailing
205
+ * slashes.
206
+ *
207
+ */
208
+ export declare function _getChild(ref: Reference, childPath: string): Reference;