add docs
authordeepak1556 <hop2deep@gmail.com>
Mon, 10 Oct 2016 12:59:34 +0000 (18:29 +0530)
committerKevin Sawicki <kevinsawicki@gmail.com>
Fri, 11 Nov 2016 18:53:36 +0000 (10:53 -0800)
docs/api/browser-window.md
docs/api/web-contents.md
docs/api/web-view-tag.md

index 4a2c541..a8d43cd 100644 (file)
@@ -969,6 +969,29 @@ Same as `webContents.capturePage([rect, ]callback)`.
   * `httpReferrer` String (optional) - A HTTP Referrer url.
   * `userAgent` String (optional) - A user agent originating the request.
   * `extraHeaders` String (optional) - Extra headers separated by "\n"
+  * `postData` Array (optional) - An array of `upload` objects which
+    provides the request body for `POST` navigation.
+
+* `upload` Object
+  * `type` String - `data`, `file`, `filsSystem`, `blob`.
+
+If `type` is `data` then `upload` object must contain:
+  * `bytes` Buffer - Raw data to be uploaded.
+
+If `type` is `file` then `upload` object must contain:
+  * `filePath` String - Path of file to be uploaded.
+  * `offset` Integer
+  * `length` Integer
+  * `modificationTime` Double
+
+If `type` is `fileSystem` then `upload` object must contain:
+  * `filsSystemURL` String - FileSystem url to read data for upload.
+  * `offset` Integer
+  * `length` Integer
+  * `modificationTime` Double
+
+If `type` is `blob` then `upload` object must contain:
+  * `blobUUID` String - UUID of blob data to upload.
 
 Same as `webContents.loadURL(url[, options])`.
 
index 249188e..d122587 100644 (file)
@@ -490,6 +490,29 @@ win.loadURL('http://github.com')
   * `httpReferrer` String - A HTTP Referrer url.
   * `userAgent` String - A user agent originating the request.
   * `extraHeaders` String - Extra headers separated by "\n"
+  * `postData` Array - An array of `upload` objects which
+    provides the request body for `POST` navigation.
+
+* `upload` Object
+  * `type` String - `data`, `file`, `filsSystem`, `blob`.
+
+If `type` is `data` then `upload` object must contain:
+  * `bytes` Buffer - Raw data to be uploaded.
+
+If `type` is `file` then `upload` object must contain:
+  * `filePath` String - Path of file to be uploaded.
+  * `offset` Integer
+  * `length` Integer
+  * `modificationTime` Double
+
+If `type` is `fileSystem` then `upload` object must contain:
+  * `filsSystemURL` String - FileSystem url to read data for upload.
+  * `offset` Integer
+  * `length` Integer
+  * `modificationTime` Double
+
+If `type` is `blob` then `upload` object must contain:
+  * `blobUUID` String - UUID of blob data to upload.
 
 Loads the `url` in the window. The `url` must contain the protocol prefix,
 e.g. the `http://` or `file://`. If the load should bypass http cache then
index 0c8c1bb..f9e47f0 100644 (file)
@@ -265,6 +265,29 @@ webview.addEventListener('dom-ready', () => {
   * `httpReferrer` String - A HTTP Referrer url.
   * `userAgent` String - A user agent originating the request.
   * `extraHeaders` String - Extra headers separated by "\n"
+  * `postData` Array - An array of `upload` objects which
+    provides the request body for `POST` navigation.
+
+* `upload` Object
+  * `type` String - `data`, `file`, `filsSystem`, `blob`.
+
+If `type` is `data` then `upload` object must contain:
+  * `bytes` Buffer - Raw data to be uploaded.
+
+If `type` is `file` then `upload` object must contain:
+  * `filePath` String - Path of file to be uploaded.
+  * `offset` Integer
+  * `length` Integer
+  * `modificationTime` Double
+
+If `type` is `fileSystem` then `upload` object must contain:
+  * `filsSystemURL` String - FileSystem url to read data for upload.
+  * `offset` Integer
+  * `length` Integer
+  * `modificationTime` Double
+
+If `type` is `blob` then `upload` object must contain:
+  * `blobUUID` String - UUID of blob data to upload.
 
 Loads the `url` in the webview, the `url` must contain the protocol prefix,
 e.g. the `http://` or `file://`.