Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

Commit

Permalink
Documentation updated.
Browse files Browse the repository at this point in the history
  • Loading branch information
faithlifebuildbot committed Jan 26, 2021
1 parent 2a22e3a commit 5d04e85
Show file tree
Hide file tree
Showing 84 changed files with 76 additions and 306 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets or sets the JSON settings.

```csharp
public JsonSettings JsonSettings { get; set; }
public JsonSettings? JsonSettings { get; set; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Creates an exception for the response.

```csharp
public WebServiceException CreateException(string message = null, Exception innerException = null)
public WebServiceException CreateException(string? message = null, Exception? innerException = null)
```

## Return Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Exposes the response headers.

```csharp
public HttpResponseHeaders Headers { get; }
public HttpResponseHeaders? Headers { get; }
```

## See Also
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Parses the JSON into an object of the specified type.

```csharp
public static Task<object> GetJsonAsAsync(this HttpResponseMessage response, Type type)
public static Task<object?> GetJsonAsAsync(this HttpResponseMessage response, Type type)
```

| parameter | description |
Expand Down Expand Up @@ -37,8 +37,8 @@ Use JToken as the type to parse arbitrary JSON.
Parses the JSON into an object of the specified type.

```csharp
public static Task<object> GetJsonAsAsync(this HttpResponseMessage response, Type type,
JsonSettings jsonSettings)
public static Task<object?> GetJsonAsAsync(this HttpResponseMessage response, Type type,
JsonSettings? jsonSettings)
```

| parameter | description |
Expand Down Expand Up @@ -108,7 +108,7 @@ Parses the JSON into an object of the specified type.

```csharp
public static Task<T> GetJsonAsAsync<T>(this HttpResponseMessage response,
JsonSettings jsonSettings)
JsonSettings? jsonSettings)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public static bool HasJson(this HttpResponseMessage response)

## Return Value

True if the response content uses the JSON content type ("application/json") and the content is not empty.
True if the response content uses the JSON content type ("application/json" or "application/schema+json") and the content is not empty.

## See Also

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ Creates a new AutoWebServiceRequest using the specified relative URI pattern and

```csharp
protected AutoWebServiceRequest<TResponse> CreateRequest<TResponse>(string relativeUriPattern,
IEnumerable<KeyValuePair<string, object>> uriParameters)
IEnumerable<KeyValuePair<string, object?>> uriParameters)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Creates a web request URI using the specified relative URI pattern and parameter

```csharp
protected Uri GetRequestUri(string relativeUriPattern,
IEnumerable<KeyValuePair<string, object>> uriParameters)
IEnumerable<KeyValuePair<string, object?>> uriParameters)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets or sets the JSON settings.

```csharp
public JsonSettings JsonSettings { get; set; }
public JsonSettings? JsonSettings { get; set; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets or sets the request settings.

```csharp
public WebServiceRequestSettings RequestSettings { get; set; }
public WebServiceRequestSettings? RequestSettings { get; set; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets or sets the request settings creator.

```csharp
public Func<WebServiceRequestSettings> RequestSettingsCreator { get; set; }
public Func<WebServiceRequestSettings>? RequestSettingsCreator { get; set; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ JsonUtility.ToJson is called just in time when the JSON content is needed.
Initializes a new instance of the JsonWebServiceContent class.

```csharp
protected internal JsonWebServiceContent(TValue value, JsonSettings settings)
protected internal JsonWebServiceContent(TValue value, JsonSettings? settings)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ The new instance.
Creates a new instance of the JsonWebServiceContent class from a value to be serialized.

```csharp
public static JsonWebServiceContent<TValue> FromValue<TValue>(TValue value, JsonSettings settings)
public static JsonWebServiceContent<TValue> FromValue<TValue>(TValue value, JsonSettings? settings)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Generates the JSON.

```csharp
protected virtual string GenerateJson()
protected virtual string? GenerateJson()
```

## Return Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the JSON.

```csharp
public string Json { get; }
public string? Json { get; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# JsonWebServiceContent.SerializeToStreamAsync method

```csharp
protected override Task SerializeToStreamAsync(Stream stream, TransportContext context)
protected override Task SerializeToStreamAsync(Stream stream, TransportContext? context)
```

## See Also
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Gets the response asynchronously.

```csharp
public Task<JsonWebServiceResponse<TResponseValue>> GetResponseAsync(
CancellationToken cancellationToken = default(CancellationToken))
CancellationToken cancellationToken = default)
```

## See Also
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets or sets the JSON settings.

```csharp
public JsonSettings JsonSettings { get; set; }
public JsonSettings? JsonSettings { get; set; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@
Gets the response asynchronously.

```csharp
public Task<JsonWebServiceResponse> GetResponseAsync(
CancellationToken cancellationToken = default(CancellationToken))
public Task<JsonWebServiceResponse> GetResponseAsync(CancellationToken cancellationToken = default)
```

## See Also
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public static class JsonWebServiceRequestUtility
| name | description |
| --- | --- |
| static [WithJsonContent&lt;TWebServiceRequest,TContentValue&gt;](JsonWebServiceRequestUtility/WithJsonContent.md)(…) | Sets the Content of the WebServiceRequest. (2 methods) |
| static [WithJsonSettings&lt;TResponseContent&gt;](JsonWebServiceRequestUtility/WithJsonSettings.md)(…) | Sets the InputSettings of the WebServiceRequest. |
| static [WithJsonSettings&lt;TResponseContent&gt;](JsonWebServiceRequestUtility/WithJsonSettings.md)(…) | Sets the JsonSettings of the WebServiceRequest. |

## See Also

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,6 @@ public static TWebServiceRequest WithJsonContent<TWebServiceRequest, TContentVal
where TWebServiceRequest : WebServiceRequestBase
```

| parameter | description |
| --- | --- |
| TWebServiceRequest | The type of the web service request. |
| TContentValue | The type of the content value. |
| request | The request. |
| contentValue | The content value. |

## Return Value

The request.

## See Also

* class [WebServiceRequestBase](../../Faithlife.WebRequests/WebServiceRequestBase.md)
Expand All @@ -37,18 +26,6 @@ public static TWebServiceRequest WithJsonContent<TWebServiceRequest, TContentVal
where TWebServiceRequest : WebServiceRequestBase
```

| parameter | description |
| --- | --- |
| TWebServiceRequest | The type of the web service request. |
| TContentValue | The type of the content value. |
| request | The request. |
| contentValue | The content value. |
| settings | The settings. |

## Return Value

The request.

## See Also

* class [WebServiceRequestBase](../../Faithlife.WebRequests/WebServiceRequestBase.md)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,12 @@
# JsonWebServiceRequestUtility.WithJsonSettings&lt;TResponseContent&gt; method

Sets the InputSettings of the WebServiceRequest.
Sets the JsonSettings of the WebServiceRequest.

```csharp
public static JsonWebServiceRequest<TResponseContent> WithJsonSettings<TResponseContent>(
this JsonWebServiceRequest<TResponseContent> request, JsonSettings settings)
```

| parameter | description |
| --- | --- |
| TResponseContent | The type of the response content. |
| request | The request. |
| settings | The settings. |

## Return Value

The request.

## See Also

* class [JsonWebServiceRequest&lt;TResponseValue&gt;](../JsonWebServiceRequest-1.md)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Initializes a new instance of the [`JsonWebServiceResponse`](../JsonWebServiceRe

```csharp
public JsonWebServiceResponse(WebServiceRequest request, HttpStatusCode statusCode,
HttpHeaders headers, HttpContent content)
HttpHeaders headers, HttpContent? content)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the value, if any.

```csharp
public string Json { get; }
public string? Json { get; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Initializes a new instance of the [`JsonWebServiceResponse`](../JsonWebServiceRe

```csharp
public JsonWebServiceResponse(WebServiceRequest request, HttpStatusCode statusCode,
HttpHeaders headers, HttpContent content)
HttpHeaders headers, HttpContent? content)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ Use JToken as the type to parse arbitrary JSON.
Parses the JSON into an object of the specified type.

```csharp
public static Task<T> GetJsonAsAsync<T>(this WebServiceResponse response, JsonSettings jsonSettings)
public static Task<T> GetJsonAsAsync<T>(this WebServiceResponse response,
JsonSettings? jsonSettings)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public static bool HasJson(this WebServiceResponse response)

## Return Value

True if the response content uses the JSON content type ("application/json") and the content is not empty.
True if the response content uses the JSON content type ("application/json" or "application/schema+json") and the content is not empty.

## See Also

Expand Down
2 changes: 1 addition & 1 deletion docs/Faithlife.WebRequests/CookieManager/CookiesChanged.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Raised when cookies are changed.

```csharp
public event EventHandler CookiesChanged;
public event EventHandler? CookiesChanged;
```

## See Also
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ Creates an exception for the specified response.

```csharp
public static WebServiceException CreateWebServiceException(HttpResponseMessage response,
string message = null, Exception innerException = null, string contentPreview = null)
string? message = null, Exception? innerException = null, string? contentPreview = null)
```

| parameter | description |
| --- | --- |
| response | The response. |
| message | The message. |
| contentPreview | The content preview. |
| innerException | The inner exception. |
| contentPreview | The content preview. |

## Return Value

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Creates an exception for the specified response, reading a content preview from

```csharp
public static Task<WebServiceException> CreateWebServiceExceptionWithContentPreviewAsync(
HttpResponseMessage response, string message = null, Exception innerException = null)
HttpResponseMessage response, string? message = null, Exception? innerException = null)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Reads a content preview from the response.

```csharp
public static Task<string> ReadContentPreviewAsync(HttpResponseMessage response)
public static Task<string?> ReadContentPreviewAsync(HttpResponseMessage response)
```

| parameter | description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the request method.

```csharp
public string RequestMethod { get; }
public string? RequestMethod { get; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the request URI.

```csharp
public Uri RequestUri { get; }
public Uri? RequestUri { get; }
```

## Property Value
Expand Down
2 changes: 1 addition & 1 deletion docs/Faithlife.WebRequests/WebServiceException/Response.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the response.

```csharp
public WebServiceResponse Response { get; }
public WebServiceResponse? Response { get; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the response content preview.

```csharp
public string ResponseContentPreview { get; }
public string? ResponseContentPreview { get; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the response content type.

```csharp
public string ResponseContentType { get; }
public string? ResponseContentType { get; }
```

## Property Value
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Gets the response headers.

```csharp
public HttpHeaders ResponseHeaders { get; }
public HttpHeaders? ResponseHeaders { get; }
```

## Property Value
Expand Down
Loading

0 comments on commit 5d04e85

Please sign in to comment.