Helper class that handles HTTP-based requests.
Description
The HttpRequestHelper class is used to handle HTTP-based requests.
Static methods
GetCorrelationId
Gets the correlationId.
public static
string GetCorrelationId(HttpRequest request)
- request: HttpRequest - HTTP request to process.
- returns: string - TODO: correlationId or null if not found.
GetFilterParams
Gets the filter parameters
public static
FilterParams GetFilterParams(HttpRequest request)
- request: HttpRequest - HTTP request to process.
- returns: FilterParams - filter parameters.
GetPagingParams
Gets the paging paramters
public static
PagingParams GetPagingParams(HttpRequest request)
- request: HttpRequest - HTTP request to process.
- returns: PagingParams - paging paramters
GetParameters
Gets the paramters from an Http request.
public static
RestOperationParameters GetParameters(HttpRequest request)
- request: HttpRequest - HTTP request to process.
- returns: RestOperationParameters - parameters.
GetSortParams
Gets sort parameters.
public static
SortParams GetSortParams(HttpRequest request)
- request: HttpRequest - HTTP request to process.
- returns: SortParams - sort parameters.
GetContextItem
Gets a context item.
public static
T GetContextItem<T>(HttpRequest request, string name)
- request: HttpRequest - HTTP request to process.
- name: string - name of context item
- returns: T - value of context item or null otherwise.
ExtractFromQuery
Gets a parameter from a query.
public static
string ExtractFromQuery(string parameter, HttpRequest request)
- parameter: string - parameter
- request: HttpRequest - HTTP request to process.
- returns: RestOperationParameters - parameter or empty string.