Table of Contents

TTMSMCPCloudBaseRequestResult Class

Extends TTMSMCPCloudBaseRequest with response data, execution state, progress tracking, and result callbacks for a completed or in-progress HTTP request.

API unit family: TMS.MCP.CloudBase Inherits from: TTMSMCPCloudBaseRequest

Syntax

TTMSMCPCloudBaseRequestResult = class(TTMSMCPCloudBaseRequest)

Properties

Name Description
Agent The HTTP User-Agent string sent with the request. (inherited from TTMSMCPCloudBaseRequest)
Async When True, the request executes asynchronously on a background task rather than blocking the calling thread.
ConnectTimeout The maximum time in milliseconds to wait for the initial connection to succeed. Use 0 for no timeout. (inherited from TTMSMCPCloudBaseRequest)
CustomHeaders When True, the request uses the custom headers defined in Headers instead of any default headers. (inherited from TTMSMCPCloudBaseRequest)
DataBoolean General-purpose Boolean slot for attaching caller-controlled state to the request. True when the caller has set this flag; False by default. (inherited from TTMSMCPCloudBaseRequest)
DataInt64 General-purpose 64-bit integer slot for attaching caller-controlled numeric data to the request. (inherited from TTMSMCPCloudBaseRequest)
DataInteger General-purpose integer slot for attaching caller-controlled numeric data to the request. (inherited from TTMSMCPCloudBaseRequest)
DataObject General-purpose object reference slot for attaching caller-controlled objects to the request. (inherited from TTMSMCPCloudBaseRequest)
DataPointer General-purpose pointer slot for attaching caller-controlled data to the request. (inherited from TTMSMCPCloudBaseRequest)
DataString General-purpose string slot for attaching caller-controlled text to the request. (inherited from TTMSMCPCloudBaseRequest)
DataUpload File reference used as the upload source for file-based upload requests. (inherited from TTMSMCPCloudBaseRequest)
Headers The collection of custom HTTP headers to include with the request. (inherited from TTMSMCPCloudBaseRequest)
Host The host name or IP address of the target server. (inherited from TTMSMCPCloudBaseRequest)
Method The HTTP method used for the request. Defaults to rmGET. (inherited from TTMSMCPCloudBaseRequest)
Name An optional logical name for the request, used to identify it in callbacks and logs. (inherited from TTMSMCPCloudBaseRequest)
Path The URL path component of the request, beginning with a forward slash. (inherited from TTMSMCPCloudBaseRequest)
Port The TCP port number of the target server. Use 0 to apply the scheme default. (inherited from TTMSMCPCloudBaseRequest)
PostData The raw POST body content to send with the request. (inherited from TTMSMCPCloudBaseRequest)
Query The URL query string component of the request, without the leading question mark. (inherited from TTMSMCPCloudBaseRequest)
ReadTimeout The maximum time in milliseconds to wait for data after the connection is established. Use 0 for no timeout. (inherited from TTMSMCPCloudBaseRequest)
ResponseCode The HTTP status code returned by the server.
ResponseHeaders The collection of HTTP response headers returned by the server.
ResultBytesReceived The number of bytes received so far for the current response body.
ResultFile The local file path where the response body is saved when ResultType is rrtFile. (inherited from TTMSMCPCloudBaseRequest)
ResultFileSize The maximum number of bytes to receive when saving the response to a file. Use 0 for unlimited. (inherited from TTMSMCPCloudBaseRequest)
ResultStream The response body captured as a memory stream when TTMSMCPCloudBaseRequest.ResultType is rrtStream.
ResultString The response body captured as a string when TTMSMCPCloudBaseRequest.ResultType is rrtString.
ResultTotalBytes The total expected size in bytes of the response body, if reported by the server.
ResultType Specifies how the response body is captured: as a string, a stream, or saved to a file. Defaults to rrtString. (inherited from TTMSMCPCloudBaseRequest)
Running When True, the request is currently executing. Defaults to False.
Success When True, the server returned a success HTTP status code.
Task The background task handle associated with this asynchronous request.
UploadFile File reference for the file to upload with the request. (inherited from TTMSMCPCloudBaseRequest)
UploadStream The in-memory stream used as the upload body for stream-based upload requests. (inherited from TTMSMCPCloudBaseRequest)

Methods

Name Description
AddBasicAuthHeader Adds an HTTP Basic Authorization header using Base64-encoded credentials and returns the created header object. (inherited from TTMSMCPCloudBaseRequest)
AddHeader Adds a custom HTTP header to the request and returns the created header object. (inherited from TTMSMCPCloudBaseRequest)
Cancel Cancels the request if it is currently running.
CheckTaskStatus Returns True when the background task associated with this request is still active.
Clear Resets all request properties to their default values. (inherited from TTMSMCPCloudBaseRequest)
ClearHeaders Removes all custom HTTP headers from the request. (inherited from TTMSMCPCloudBaseRequest)
GenerateHeaders Builds and returns the HTTP header block as a single formatted string. (inherited from TTMSMCPCloudBaseRequest)
GetMethodString Returns the HTTP method name string corresponding to the current Method value, such as GET or POST. (inherited from TTMSMCPCloudBaseRequest)
GetPort Returns the effective port number, using the scheme default when Port is not explicitly set. (inherited from TTMSMCPCloudBaseRequest)
GetQueryPath Returns the path and query portion of the URL. (inherited from TTMSMCPCloudBaseRequest)
GetResponseHeader Returns the value of a named response header, or an empty string if the header is not present.
GetServer Returns the server authority portion of the URL, combining host and port. (inherited from TTMSMCPCloudBaseRequest)
GetURL Returns the fully composed URL for this request, combining scheme, host, port, path, and query. (inherited from TTMSMCPCloudBaseRequest)
HasUploadFile Returns True when a file path for uploading has been assigned to this request. (inherited from TTMSMCPCloudBaseRequest)
HasUploadStream Returns True when an in-memory upload stream has been assigned to this request. (inherited from TTMSMCPCloudBaseRequest)
Log Appends a message to the request log and fires the OnLog event.

Events

Name Description
CallBackProgress Callback invoked during upload or download progress, receiving this result object and the current progress fraction.
CallBackResult Callback invoked when the request completes, receiving this result object.
OnCancelled Fires when the request is cancelled before it completes.
OnComplete Fires when the request completes, whether successfully or not.
OnLog Fires when a log message is recorded for this request.
OnProgress Fires during upload or download progress, reporting the current progress fraction and direction.

Used by