TIPHTTPRequestHeaders
Overview
The TIPHTTPRequestHeaders class represents a collection of HTTP Request headers of incoming requests.
You can use this class in custom Super HTTP Server. For example, in the Remoting SDK, the TIPHTTPRequestHeaders class is used in the TROBaseSuperHTTPServer and TROIpSuperHTTPServer servers.
Location
- Unit: uIPHttpHeaders.pas
- Ancestry: TIPInterfacedObject | TIPHTTPRequestHeaders
constructor Create
Creates a new instance with a new empty collection of Headers.
constructor Create
AddHeaderLine
Adds a new header line to the Headers collection.
procedure AddHeaderLine(const aLine: string)
Parameters:
- aLine: Specified header line that should be added
AuthPassword
Represents the authentication password of the current request.
property AuthPassword: UnicodeString read write
AuthUsername
Represents the authentication user name of the current request.
property AuthUsername: UnicodeString read write
Clear
Clears all the properties of the current TIPHTTPRequestHeaders object, such as Headers, Method, Path, Version and TargetUrl.
procedure Clear
ClientAddress
Represents the client address of the current request.
property ClientAddress: string read write
ContentLength
Represents the Content-Length entity-header of the current request.
property ContentLength: Int64 read
ContentType
Represents the Content-Type entity-header of the current request.
property ContentType: string read
GetQueryString
Gets the specified part of the query string with the specified value.
function GetQueryString(aValue: string): string
Parameters:
- aValue: Specified value of the query string part
Headers
Represents the collection of headers of the current request in "Name=Value" format. This property is read-only.
property Headers: TStrings read
IsHTTPS
Specifies which version is used (HTTP or HTTPS)
property IsHTTPS: Boolean read write
Location
Represents the location of the current host.
property Location: string read
Method
Represents the HTTP method (like GET, POST, etc.) of the current request.
property Method: string read write
Path
Represents the path of the request URL and contains dispatcher name and service name.
property Path: string read write
QueryString
Returns the result string with the request parameters.
property QueryString: string read
UsesAuthentication
Returns true if the current request contains authentication information, otherwise false.
property UsesAuthentication: Boolean read write
Version
Represents the HTTP request version (for example, "HTTP/1.1").
property Version: string read write
AuthPassword
Represents the authentication password of the current request.
property AuthPassword: UnicodeString read write
AuthUsername
Represents the authentication user name of the current request.
property AuthUsername: UnicodeString read write
ClientAddress
Represents the client address of the current request.
property ClientAddress: string read write
ContentLength
Represents the Content-Length entity-header of the current request.
property ContentLength: Int64 read
ContentType
Represents the Content-Type entity-header of the current request.
property ContentType: string read
Headers
Represents the collection of headers of the current request in "Name=Value" format. This property is read-only.
property Headers: TStrings read
IsHTTPS
Specifies which version is used (HTTP or HTTPS)
property IsHTTPS: Boolean read write
Location
Represents the location of the current host.
property Location: string read
Method
Represents the HTTP method (like GET, POST, etc.) of the current request.
property Method: string read write
Path
Represents the path of the request URL and contains dispatcher name and service name.
property Path: string read write
QueryString
Returns the result string with the request parameters.
property QueryString: string read
UsesAuthentication
Returns true if the current request contains authentication information, otherwise false.
property UsesAuthentication: Boolean read write
Version
Represents the HTTP request version (for example, "HTTP/1.1").
property Version: string read write
constructor Create
Creates a new instance with a new empty collection of Headers.
constructor Create
AddHeaderLine
Adds a new header line to the Headers collection.
procedure AddHeaderLine(const aLine: string)
Parameters:
- aLine: Specified header line that should be added
Clear
Clears all the properties of the current TIPHTTPRequestHeaders object, such as Headers, Method, Path, Version and TargetUrl.
procedure Clear
GetQueryString
Gets the specified part of the query string with the specified value.
function GetQueryString(aValue: string): string
Parameters:
- aValue: Specified value of the query string part
- HTTP
- HTTP Request headers