Table of Contents

TTMSFNCCustomCloudTranslation Class

Base class for the cloud translation component. Connects to a selectable translation service and exposes asynchronous methods to translate text, detect the language of text and retrieve the languages supported by the service.

API unit family: TMSFNCCloudTranslation Inherits from: TTMSFNCCloudBase Implements: ITMSFNCCustomCloudTranslationProperties

Syntax

TTMSFNCCustomCloudTranslation = class(TTMSFNCCloudBase, ITMSFNCCustomCloudTranslationProperties)

Remarks

Set APIKey and select a provider through Service before issuing requests. Results are delivered through the request callbacks and the matching events.

Methods

Name Description
Detect Detects the source language of a single text value. The request runs asynchronously; the result is delivered through the callback and the detect event.
GetSupportedLanguages Requests the list of languages supported by the selected service. The request runs asynchronously; the result is delivered through the callback and the supported-languages event.
Translate Translates a single text value into the target language. The request runs asynchronously; the result is delivered through the callback and the translate event.