func url(request: Request): Uri {...}{.inline, raises: [], tags: [].}
-
Gets the url of the request.
Source
Edit
func port(request: Request): string {...}{.inline, raises: [], tags: [].}
-
Gets the port of the request.
Source
Edit
func path(request: Request): string {...}{.inline, raises: [], tags: [].}
-
Gets the path of the request.
Source
Edit
func stripPath(request: var Request) {...}{.inline, raises: [], tags: [].}
-
Strips the path of the request.
Source
Edit
func query(request: Request): string {...}{.inline, raises: [], tags: [].}
-
Gets the query strings of the request.
Source
Edit
func scheme(request: Request): string {...}{.inline, raises: [], tags: [].}
-
Gets the scheme of the request.
Source
Edit
func setScheme(request: var Request; value: string) {...}{.inline, raises: [],
tags: [].}
-
Sets the scheme of the request.
Source
Edit
func body(request: Request): string {...}{.inline, raises: [KeyError, ValueError],
tags: [].}
-
Gets the body of the request. It is only present when using HttpPost method.
Source
Edit
func headers(request: Request): HttpHeaders {...}{.inline, raises: [], tags: [].}
-
Gets the HttpHeaders of the request.
Source
Edit
func reqMethod(request: Request): HttpMethod {...}{.inline, raises: [], tags: [].}
-
Gets the HttpMethod of the request.
Source
Edit
func getCookie(request: Request; key: string; default: string): string {...}{.inline,
raises: [], tags: [].}
-
Gets the value of request.cookies[key] if key is in cookies. Otherwise, the default value will be returned.
Source
Edit
func contentType(request: Request): string {...}{.inline, raises: [KeyError],
tags: [].}
-
Gets the contentType of the request.
Source
Edit
func charset(request: Request): string {...}{.inline, raises: [KeyError], tags: [].}
-
Gets the charset of the request.
Source
Edit
func secure(request: Request): bool {...}{.inline, raises: [KeyError], tags: [].}
-
Returns True if the request is secure.
Source
Edit
func hostName(request: Request): string {...}{.inline, raises: [KeyError], tags: [].}
-
Gets the hostname of the request.
Source
Edit
func initRequest(nativeRequest: NativeRequest; cookies = initCookieJar();
pathParams = newStringTable(modeCaseSensitive);
queryParams = newStringTable(modeCaseSensitive);
postParams = newStringTable(modeCaseSensitive)): Request {...}{.
raises: [KeyError], tags: [].}
-
Initializes a new Request.
Source
Edit
func initMockingRequest(httpMethod: HttpMethod; headers: HttpHeaders; url: Uri;
cookies = initCookieJar();
postParams = newStringTable();
queryParams = newStringTable();
formParams = initFormPart();
pathParams = newStringTable()): Request {...}{.raises: [],
tags: [].}
-
Initializes a new Request.
Source
Edit