@@ -109,17 +109,28 @@ var getPhotosReturnChecker = createStrictShapeTypeChecker({
109
109
} ) . isRequired ,
110
110
} ) ;
111
111
112
+ /**
113
+ * `CameraRoll` provides access to the local camera roll / gallery.
114
+ */
112
115
class CameraRoll {
113
116
114
117
static GroupTypesOptions : Array < string > ;
115
118
static AssetTypeOptions: Array< string > ;
116
119
/**
117
- * Saves the image with tag `tag` to the camera roll.
120
+ * Saves the image to the camera roll / gallery.
121
+ *
122
+ * @param { string } tag On Android, this is a local URI, such
123
+ * as `"file:///sdcard/img.png"`.
124
+ *
125
+ * On iOS, the tag can be one of the following:
126
+ *
127
+ * - local URI
128
+ * - assets-library tag
129
+ * - a tag not maching any of the above, which means the image data will
130
+ * be stored in memory (and consume memory as long as the process is alive)
118
131
*
119
- * @param { string } tag - Can be any of the three kinds of tags we accept:
120
- * 1. URL
121
- * 2. assets-library tag
122
- * 3. tag returned from storing an image in memory
132
+ * @param successCallback Invoked with the value of `tag` on success.
133
+ * @param errorCallback Invoked with error message on error.
123
134
*/
124
135
static saveImageWithTag(tag, successCallback, errorCallback) {
125
136
invariant (
@@ -140,10 +151,10 @@ class CameraRoll {
140
151
* Invokes `callback` with photo identifier objects from the local camera
141
152
* roll of the device matching shape defined by `getPhotosReturnChecker`.
142
153
*
143
- * @param { object } params - See `getPhotosParamChecker`.
144
- * @param { function } callback - Invoked with arg of shape defined by
145
- * `getPhotosReturnChecker` on success.
146
- * @param { function } errorCallback - Invoked with error message on error.
154
+ * @param { object } params See `getPhotosParamChecker`.
155
+ * @param { function } callback Invoked with arg of shape defined by
156
+ * `getPhotosReturnChecker` on success.
157
+ * @param { function } errorCallback Invoked with error message on error.
147
158
*/
148
159
static getPhotos(params, callback, errorCallback) {
149
160
var metaCallback = callback ;
0 commit comments