@@ -785,6 +785,10 @@ exist.</p>
785
785
<li ><a name =" method_fields.delete.self " ><code >self</code ></a >: borrow< ; <a href =" #fields " ><a href =" #fields " ><code >fields</code ></a ></a >> ; </li >
786
786
<li ><a name =" method_fields.delete.name " ><code >name</code ></a >: <a href =" #field_key " ><a href =" #field_key " ><code >field-key</code ></a ></a ></li >
787
787
</ul >
788
+ <h5 >Return values</h5 >
789
+ <ul >
790
+ <li ><a name =" method_fields.delete.0 " ></a > result< ; _, <a href =" #header_error " ><a href =" #header_error " ><code >header-error</code ></a ></a >> ; </li >
791
+ </ul >
788
792
<h4 ><a name =" method_fields.append " ><code >[method]fields.append: func</code ></a ></h4 >
789
793
<p >Append a value for a key. Does not change or delete any existing
790
794
values for that key.</p >
@@ -888,17 +892,9 @@ return success at most once, and subsequent calls will return error.</p>
888
892
<li ><a name =" method_incoming_request.consume.0 " ></a > result< ; own< ; <a href =" #incoming_body " ><a href =" #incoming_body " ><code >incoming-body</code ></a ></a >> ;> ; </li >
889
893
</ul >
890
894
<h4 ><a name =" constructor_outgoing_request " ><code >[constructor]outgoing-request: func</code ></a ></h4 >
891
- <p >Construct a new <a href =" #outgoing_request " ><code >outgoing-request</code ></a >.</p >
892
- <ul >
893
- <li ><a href =" #method " ><code >method</code ></a > represents the HTTP Method for the Request.</li >
894
- <li ><code >path-with-query</code > is the combination of the HTTP Path and Query for
895
- the Request. When <code >none</code >, this represents an empty Path and empty
896
- Query.</li >
897
- <li ><a href =" #scheme " ><code >scheme</code ></a > is the HTTP Related Scheme for the Request. When <code >none</code >,
898
- the implementation may choose an appropriate default scheme.</li >
899
- <li ><code >authority</code > is the HTTP Authority for the Request. A value of <code >none</code >
900
- may be used with Related Schemes which do not require an Authority.
901
- The HTTP and HTTPS schemes always require an authority.</li >
895
+ <p >Construct a new <a href =" #outgoing_request " ><code >outgoing-request</code ></a > with a default <a href =" #method " ><code >method</code ></a > of <code >GET</code >, and
896
+ <code >none</code > values for <code >path-with-query</code >, <a href =" #scheme " ><code >scheme</code ></a >, and <code >authority</code >.</p >
897
+ <ul >
902
898
<li ><a href =" #headers " ><code >headers</code ></a > is the HTTP Headers for the Request.</li >
903
899
</ul >
904
900
<p >It is possible to construct, or manipulate with the accessor functions
@@ -908,10 +904,6 @@ It is the obligation of the <code>outgoing-handler.handle</code> implementation
908
904
to reject invalid constructions of <a href =" #outgoing_request " ><code >outgoing-request</code ></a >.</p >
909
905
<h5 >Params</h5 >
910
906
<ul >
911
- <li ><a name =" constructor_outgoing_request.method " ><a href =" #method " ><code >method</code ></a ></a >: <a href =" #method " ><a href =" #method " ><code >method</code ></a ></a ></li >
912
- <li ><a name =" constructor_outgoing_request.path_with_query " ><code >path-with-query</code ></a >: option< ; <code >string</code >> ; </li >
913
- <li ><a name =" constructor_outgoing_request.scheme " ><a href =" #scheme " ><code >scheme</code ></a ></a >: option< ; <a href =" #scheme " ><a href =" #scheme " ><code >scheme</code ></a ></a >> ; </li >
914
- <li ><a name =" constructor_outgoing_request.authority " ><code >authority</code ></a >: option< ; <code >string</code >> ; </li >
915
907
<li ><a name =" constructor_outgoing_request.headers " ><a href =" #headers " ><code >headers</code ></a ></a >: own< ; <a href =" #headers " ><a href =" #headers " ><code >headers</code ></a ></a >> ; </li >
916
908
</ul >
917
909
<h5 >Return values</h5 >
@@ -943,12 +935,17 @@ calls will return error.</p>
943
935
<li ><a name =" method_outgoing_request.method.0 " ></a > <a href =" #method " ><a href =" #method " ><code >method</code ></a ></a ></li >
944
936
</ul >
945
937
<h4 ><a name =" method_outgoing_request.set_method " ><code >[method]outgoing-request.set-method: func</code ></a ></h4 >
946
- <p >Set the Method for the Request.</p >
938
+ <p >Set the Method for the Request. Fails if the string present in a
939
+ <code >method.other</code > argument is not a syntactically valid method.</p >
947
940
<h5 >Params</h5 >
948
941
<ul >
949
942
<li ><a name =" method_outgoing_request.set_method.self " ><code >self</code ></a >: borrow< ; <a href =" #outgoing_request " ><a href =" #outgoing_request " ><code >outgoing-request</code ></a ></a >> ; </li >
950
943
<li ><a name =" method_outgoing_request.set_method.method " ><a href =" #method " ><code >method</code ></a ></a >: <a href =" #method " ><a href =" #method " ><code >method</code ></a ></a ></li >
951
944
</ul >
945
+ <h5 >Return values</h5 >
946
+ <ul >
947
+ <li ><a name =" method_outgoing_request.set_method.0 " ></a > result</li >
948
+ </ul >
952
949
<h4 ><a name =" method_outgoing_request.path_with_query " ><code >[method]outgoing-request.path-with-query: func</code ></a ></h4 >
953
950
<p >Get the combination of the HTTP Path and Query for the Request.
954
951
When <code >none</code >, this represents an empty Path and empty Query.</p >
@@ -962,12 +959,17 @@ When <code>none</code>, this represents an empty Path and empty Query.</p>
962
959
</ul >
963
960
<h4 ><a name =" method_outgoing_request.set_path_with_query " ><code >[method]outgoing-request.set-path-with-query: func</code ></a ></h4 >
964
961
<p >Set the combination of the HTTP Path and Query for the Request.
965
- When <code >none</code >, this represents an empty Path and empty Query.</p >
962
+ When <code >none</code >, this represents an empty Path and empty Query. Fails is the
963
+ string given is not a syntactically valid path and query uri component.</p >
966
964
<h5 >Params</h5 >
967
965
<ul >
968
966
<li ><a name =" method_outgoing_request.set_path_with_query.self " ><code >self</code ></a >: borrow< ; <a href =" #outgoing_request " ><a href =" #outgoing_request " ><code >outgoing-request</code ></a ></a >> ; </li >
969
967
<li ><a name =" method_outgoing_request.set_path_with_query.path_with_query " ><code >path-with-query</code ></a >: option< ; <code >string</code >> ; </li >
970
968
</ul >
969
+ <h5 >Return values</h5 >
970
+ <ul >
971
+ <li ><a name =" method_outgoing_request.set_path_with_query.0 " ></a > result</li >
972
+ </ul >
971
973
<h4 ><a name =" method_outgoing_request.scheme " ><code >[method]outgoing-request.scheme: func</code ></a ></h4 >
972
974
<p >Get the HTTP Related Scheme for the Request. When <code >none</code >, the
973
975
implementation may choose an appropriate default scheme.</p >
@@ -981,12 +983,17 @@ implementation may choose an appropriate default scheme.</p>
981
983
</ul >
982
984
<h4 ><a name =" method_outgoing_request.set_scheme " ><code >[method]outgoing-request.set-scheme: func</code ></a ></h4 >
983
985
<p >Set the HTTP Related Scheme for the Request. When <code >none</code >, the
984
- implementation may choose an appropriate default scheme.</p >
986
+ implementation may choose an appropriate default scheme. Fails if the
987
+ string given is not a syntactically valid uri scheme.</p >
985
988
<h5 >Params</h5 >
986
989
<ul >
987
990
<li ><a name =" method_outgoing_request.set_scheme.self " ><code >self</code ></a >: borrow< ; <a href =" #outgoing_request " ><a href =" #outgoing_request " ><code >outgoing-request</code ></a ></a >> ; </li >
988
991
<li ><a name =" method_outgoing_request.set_scheme.scheme " ><a href =" #scheme " ><code >scheme</code ></a ></a >: option< ; <a href =" #scheme " ><a href =" #scheme " ><code >scheme</code ></a ></a >> ; </li >
989
992
</ul >
993
+ <h5 >Return values</h5 >
994
+ <ul >
995
+ <li ><a name =" method_outgoing_request.set_scheme.0 " ></a > result</li >
996
+ </ul >
990
997
<h4 ><a name =" method_outgoing_request.authority " ><code >[method]outgoing-request.authority: func</code ></a ></h4 >
991
998
<p >Get the HTTP Authority for the Request. A value of <code >none</code > may be used
992
999
with Related Schemes which do not require an Authority. The HTTP and
@@ -1002,12 +1009,17 @@ HTTPS schemes always require an authority.</p>
1002
1009
<h4 ><a name =" method_outgoing_request.set_authority " ><code >[method]outgoing-request.set-authority: func</code ></a ></h4 >
1003
1010
<p >Set the HTTP Authority for the Request. A value of <code >none</code > may be used
1004
1011
with Related Schemes which do not require an Authority. The HTTP and
1005
- HTTPS schemes always require an authority.</p >
1012
+ HTTPS schemes always require an authority. Fails if the string given is
1013
+ not a syntactically valid uri authority.</p >
1006
1014
<h5 >Params</h5 >
1007
1015
<ul >
1008
1016
<li ><a name =" method_outgoing_request.set_authority.self " ><code >self</code ></a >: borrow< ; <a href =" #outgoing_request " ><a href =" #outgoing_request " ><code >outgoing-request</code ></a ></a >> ; </li >
1009
1017
<li ><a name =" method_outgoing_request.set_authority.authority " ><code >authority</code ></a >: option< ; <code >string</code >> ; </li >
1010
1018
</ul >
1019
+ <h5 >Return values</h5 >
1020
+ <ul >
1021
+ <li ><a name =" method_outgoing_request.set_authority.0 " ></a > result</li >
1022
+ </ul >
1011
1023
<h4 ><a name =" method_outgoing_request.headers " ><code >[method]outgoing-request.headers: func</code ></a ></h4 >
1012
1024
<p >Get the headers associated with the Request.</p >
1013
1025
<p >This headers resource is a child: it must be dropped before the parent
@@ -1201,14 +1213,14 @@ trailers were present in the body.</p>
1201
1213
<li ><a name =" method_future_trailers.get.0 " ></a > option< ; result< ; option< ; own< ; <a href =" #trailers " ><a href =" #trailers " ><code >trailers</code ></a ></a >> ;> ; , <a href =" #error " ><a href =" #error " ><code >error</code ></a ></a >> ;> ; </li >
1202
1214
</ul >
1203
1215
<h4 ><a name =" constructor_outgoing_response " ><code >[constructor]outgoing-response: func</code ></a ></h4 >
1204
- <p >Construct an <a href =" #outgoing_response " ><code >outgoing-response</code ></a >.</p >
1216
+ <p >Construct an <a href =" #outgoing_response " ><code >outgoing-response</code ></a >, with a default <a href =" #status_code " ><code >status-code</code ></a > of <code >200</code >.
1217
+ If a different <a href =" #status_code " ><code >status-code</code ></a > is needed, it must be set via the
1218
+ <code >set-status-code</code > method.</p >
1205
1219
<ul >
1206
- <li ><a href =" #status_code " ><code >status-code</code ></a > is the HTTP Status Code for the Response.</li >
1207
1220
<li ><a href =" #headers " ><code >headers</code ></a > is the HTTP Headers for the Response.</li >
1208
1221
</ul >
1209
1222
<h5 >Params</h5 >
1210
1223
<ul >
1211
- <li ><a name =" constructor_outgoing_response.status_code " ><a href =" #status_code " ><code >status-code</code ></a ></a >: <a href =" #status_code " ><a href =" #status_code " ><code >status-code</code ></a ></a ></li >
1212
1224
<li ><a name =" constructor_outgoing_response.headers " ><a href =" #headers " ><code >headers</code ></a ></a >: own< ; <a href =" #headers " ><a href =" #headers " ><code >headers</code ></a ></a >> ; </li >
1213
1225
</ul >
1214
1226
<h5 >Return values</h5 >
@@ -1226,12 +1238,17 @@ trailers were present in the body.</p>
1226
1238
<li ><a name =" method_outgoing_response.status_code.0 " ></a > <a href =" #status_code " ><a href =" #status_code " ><code >status-code</code ></a ></a ></li >
1227
1239
</ul >
1228
1240
<h4 ><a name =" method_outgoing_response.set_status_code " ><code >[method]outgoing-response.set-status-code: func</code ></a ></h4 >
1229
- <p >Set the HTTP Status Code for the Response.</p >
1241
+ <p >Set the HTTP Status Code for the Response. Fails if the status-code
1242
+ given is not a valid http status code.</p >
1230
1243
<h5 >Params</h5 >
1231
1244
<ul >
1232
1245
<li ><a name =" method_outgoing_response.set_status_code.self " ><code >self</code ></a >: borrow< ; <a href =" #outgoing_response " ><a href =" #outgoing_response " ><code >outgoing-response</code ></a ></a >> ; </li >
1233
1246
<li ><a name =" method_outgoing_response.set_status_code.status_code " ><a href =" #status_code " ><code >status-code</code ></a ></a >: <a href =" #status_code " ><a href =" #status_code " ><code >status-code</code ></a ></a ></li >
1234
1247
</ul >
1248
+ <h5 >Return values</h5 >
1249
+ <ul >
1250
+ <li ><a name =" method_outgoing_response.set_status_code.0 " ></a > result</li >
1251
+ </ul >
1235
1252
<h4 ><a name =" method_outgoing_response.headers " ><code >[method]outgoing-response.headers: func</code ></a ></h4 >
1236
1253
<p >Get the headers associated with the Request.</p >
1237
1254
<p >This headers resource is a child: it must be dropped before the parent
0 commit comments