RequestHeaders.Get<T>(String) Method
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.
Gets the value of header with name
.
public:
generic <typename T>
T Get(System::String ^ name);
public T Get<T> (string name);
public T? Get<T> (string name);
member this.Get : string -> 'T
Public Function Get(Of T) (name As String) As T
Type Parameters
- T
The type of the header. The given type must have a static TryParse method.
Parameters
- name
- String
The name of the header to retrieve.
Returns
T
The value of the header.
Remarks
T
must contain a TryParse method with the signature public static bool TryParse(string, out T)
.
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for