HarPostDataExtensions Class
Provides helper methods for working with HAR post data payloads.
public static class HarPostDataExtensionsMethods
| Name | Description |
|---|---|
| TryGetRawData(HarPostData?, byte[]?, string) | Gets the raw payload bytes represented by the HAR post data. |
TryGetRawData(HarPostData?, byte[]?, string)
HarPostDataExtensions.csGets the raw payload bytes represented by the HAR post data.
public static bool TryGetRawData(this HarPostData? postData, out byte[]? rawData, string encodingExtensionName = "x-meziantou-encoding")Parameters
postDataHarPostData?- The HAR post data.
rawDatabyte[]?- The decoded raw bytes if available.
encodingExtensionNamestring- The extension field name containing the encoding metadata.
Returns
bool true when payload bytes are available; otherwise, false. Returns false when the text is not valid for the declared encoding, or when the declared encoding is not understood, rather than reporting the undecoded text as the payload.
Constants
| Name | Description |
|---|---|
| DefaultEncodingExtensionName | Default extension field name used to store the post data encoding. |
DefaultEncodingExtensionName
Default extension field name used to store the post data encoding.
public const string DefaultEncodingExtensionName = "x-meziantou-encoding"