Jelajahi Sumber

Merge sblaurock-update-dataconnection-docs

Michelle Bu 11 tahun lalu
induk
melakukan
7175b8370e
3 mengubah file dengan 21 tambahan dan 6 penghapusan
  1. 20 5
      docs/api.json
  2. 0 0
      docs/index.html
  3. 1 1
      lib/negotiator.js

+ 20 - 5
docs/api.json

@@ -316,6 +316,11 @@
           }
         ]
       },
+      {
+        "name": ".bufferSize",
+        "type": "number",
+        "description": "The number of messages queued to be sent once the browser buffer is no longer full."
+      },
       {
         "name": ".dataChannel",
         "type": "object",
@@ -330,21 +335,31 @@
         "name": ".metadata",
         "description": "Any type of metadata associated with the connection, passed in by whoever initiated the connection."
       },
-      {
-        "name": ".serialization",
-        "type": "string",
-        "description": "The serialization format of the data sent over the connection. Can be <code>binary</code> (default), <code>binary-utf8</code>, <code>json</code>, or <code>none</code>."
-      },
       {
         "name": ".open",
         "type": "boolean",
         "description": "This is true if the connection is open and ready for read/write."
       },
+      {
+        "name": ".peerConnection",
+        "type": "object",
+        "description": "A reference to the RTCPeerConnection object associated with the connection."
+      },
       {
         "name": ".peer",
         "type": "string",
         "description": "The ID of the peer on the other end of this connection."
       },
+      {
+        "name": ".reliable",
+        "type": "boolean",
+        "description": "Whether the underlying data channels are reliable; defined when the connection was initiated."
+      },
+      {
+        "name": ".serialization",
+        "type": "string",
+        "description": "The serialization format of the data sent over the connection. Can be <code>binary</code> (default), <code>binary-utf8</code>, <code>json</code>, or <code>none</code>."
+      },
       {
         "name": ".type",
         "type": "string",

File diff ditekan karena terlalu besar
+ 0 - 0
docs/index.html


+ 1 - 1
lib/negotiator.js

@@ -22,7 +22,7 @@ Negotiator.startConnection = function(connection, options) {
   }
 
   // Set the connection's PC.
-  connection.pc = pc;
+  connection.pc = connection.peerConnection = pc;
   // What do we need to do now?
   if (options.originator) {
     if (connection.type === 'data') {

Beberapa file tidak ditampilkan karena terlalu banyak file yang berubah dalam diff ini