Google Cloud Translation v3 API - Class DetectLanguageRequest (3.3.0)

public sealed class DetectLanguageRequest : IMessage<DetectLanguageRequest>, IEquatable<DetectLanguageRequest>, IDeepCloneable<DetectLanguageRequest>, IBufferMessage, IMessage

Reference documentation and code samples for the Google Cloud Translation v3 API class DetectLanguageRequest.

The request message for language detection.

Inheritance

object > DetectLanguageRequest

Namespace

Google.Cloud.Translate.V3

Assembly

Google.Cloud.Translate.V3.dll

Constructors

DetectLanguageRequest()

public DetectLanguageRequest()

DetectLanguageRequest(DetectLanguageRequest)

public DetectLanguageRequest(DetectLanguageRequest other)
Parameter
NameDescription
otherDetectLanguageRequest

Properties

Content

public string Content { get; set; }

The content of the input stored as a string.

Property Value
TypeDescription
string

HasContent

public bool HasContent { get; }

Gets whether the "content" field is set

Property Value
TypeDescription
bool

Labels

public MapField<string, string> Labels { get; }

Optional. The labels with user-defined metadata for the request.

Label keys and values can be no longer than 63 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. Label values are optional. Label keys must start with a letter.

See https://cloud.google.com/translate/docs/advanced/labels for more information.

Property Value
TypeDescription
MapFieldstringstring

MimeType

public string MimeType { get; set; }

Optional. The format of the source text, for example, "text/html", "text/plain". If left blank, the MIME type defaults to "text/html".

Property Value
TypeDescription
string

Model

public string Model { get; set; }

Optional. The language detection model to be used.

Format: projects/{project-number-or-id}/locations/{location-id}/models/language-detection/{model-id}

Only one language detection model is currently supported: projects/{project-number-or-id}/locations/{location-id}/models/language-detection/default.

If not specified, the default model is used.

Property Value
TypeDescription
string

Parent

public string Parent { get; set; }

Required. Project or location to make a call. Must refer to a caller's project.

Format: projects/{project-number-or-id}/locations/{location-id} or projects/{project-number-or-id}.

For global calls, use projects/{project-number-or-id}/locations/global or projects/{project-number-or-id}.

Only models within the same region (has same location-id) can be used. Otherwise an INVALID_ARGUMENT (400) error is returned.

Property Value
TypeDescription
string

ParentAsLocationName

public LocationName ParentAsLocationName { get; set; }

LocationName-typed view over the Parent resource name property.

Property Value
TypeDescription
LocationName

SourceCase

public DetectLanguageRequest.SourceOneofCase SourceCase { get; }
Property Value
TypeDescription
DetectLanguageRequestSourceOneofCase