Skip to content

Commit

Permalink
Define datagram backpressure control attributes (#267)
Browse files Browse the repository at this point in the history
- incomingMaxAge
- outgoingMaxAge
- incomingHighWaterMark
- outgoingHighWaterMark

Fixes #251, #221, #152
  • Loading branch information
yutakahirano authored Jun 16, 2021
1 parent dec79ad commit 809721b
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,11 @@ A <dfn interface>DatagramDuplexStream</dfn> is a generic duplex stream.
interface DatagramDuplexStream {
readonly attribute ReadableStream readable;
readonly attribute WritableStream writable;

attribute double? incomingMaxAge;
attribute double? outgoingMaxAge;
attribute long incomingHighWaterMark;
attribute long outgoingHighWaterMark;
};
</pre>

Expand Down Expand Up @@ -358,6 +363,38 @@ A {{DatagramDuplexStream}} object has the following internal slots.
:: The getter steps are:
1. Return [=this=].`[[Writable]]`.

: <dfn for="DatagramDuplexStream" attribute>incomingMaxAge</dfn>
:: The getter steps are:
1. Return [=this=]'s [=[[IncomingDatagramsExpirationDuration]]=].
:: The setter steps are:
1. Let |value| be the given value.
1. If |value| is null or |value| > 0:
1. Set [=this=]'s [=[[IncomingDatagramsExpirationDuration]]=] to |value|.

: <dfn for="DatagramDuplexStream" attribute>outgoingMaxAge</dfn>
:: The getter steps are:
1. Return [=this=]'s [=[[OutgoingDatagramsExpirationDuration]]=].
:: The setter steps are:
1. Let |value| be the given value.
1. If |value| is null or |value| > 0:
1. Set [=this=]'s [=[[OutgoingDatagramsExpirationDuration]]=] to |value|.

: <dfn for="DatagramDuplexStream" attribute>incomingHighWaterMark</dfn>
:: The getter steps are:
1. Return [=this=]'s [=[[IncomingDatagramsHighWaterMark]]=].
:: The setter steps are:
1. Let |value| be the given value.
1. If |value| ≥ 0:
1. Set [=this=]'s [=[[IncomingDatagramsHighWaterMark]]=] to |value|.

: <dfn for="DatagramDuplexStream" attribute>outgoingHighWaterMark</dfn>
:: The getter steps are:
1. Return [=this=]'s [=[[OutgoingDatagramsHighWaterMark]]=].
:: The setter steps are:
1. Let |value| be the given value.
1. If |value| ≥ 0:
1. Set [=this=]'s [=[[OutgoingDatagramsHighWaterMark]]=] to |value|.

## Procedures ## {#datagram-duplex-stream-procedures}

To <dfn>pullDatagrams</dfn>, given a {{WebTransport}} object |transport|, run these steps:
Expand Down

0 comments on commit 809721b

Please sign in to comment.