HeaderUtilities Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides utilities to parse and modify HTTP header values.
public ref class HeaderUtilities abstract sealed
public static class HeaderUtilities
type HeaderUtilities = class
Public Class HeaderUtilities
- Inheritance
-
HeaderUtilities
Methods
ContainsCacheDirective(StringValues, String) |
Check if a target directive exists among the set of given cache control directives. |
EscapeAsQuotedString(StringSegment) |
Escapes a StringSegment as a quoted-string, which is defined by the RFC specification. |
FormatDate(DateTimeOffset, Boolean) |
Formats the |
FormatDate(DateTimeOffset) |
Formats the |
FormatInt64(Int64) | |
FormatNonNegativeInt64(Int64) |
Converts the non-negative 64-bit numeric value to its equivalent string representation. |
IsQuoted(StringSegment) |
Determines if the specified |
RemoveQuotes(String) | |
RemoveQuotes(StringSegment) |
Removes quotes from the specified |
TryParseDate(String, DateTimeOffset) | |
TryParseDate(StringSegment, DateTimeOffset) |
Attempts to parse the specified |
TryParseInt64(String, Int64) | |
TryParseNonNegativeInt32(StringSegment, Int32) |
Try to convert a string representation of a positive number to its 64-bit signed integer equivalent. A return value indicates whether the conversion succeeded or failed. |
TryParseNonNegativeInt64(StringSegment, Int64) |
Try to convert a StringSegment representation of a positive number to its 64-bit signed integer equivalent. A return value indicates whether the conversion succeeded or failed. |
TryParseSeconds(StringValues, String, Nullable<TimeSpan>) |
Try to find a target header value among the set of given header values and parse it as a TimeSpan. |
UnescapeAsQuotedString(StringSegment) |
Given a quoted-string as defined by the RFC specification, removes quotes and unescapes backslashes and quotes. This assumes that the input is a valid quoted-string. |