1. Stylelabs.M.Sdk.Clients

Interface ITranslationsClient

Contains functionality to manage translations.

Namespace: StylelabsStylelabs.MSdkClients

Assembly: Stylelabs.M.Sdk.dll

Syntax

public interface ITranslationsClient

Methods

LocalizeAsync(string, CultureInfo, params Parameter[])

Retrieves the localized string for the given entryName.

Declaration

Task<string> LocalizeAsync(string entryName, CultureInfo culture = null, params Parameter[] parameters)

Parameters

TypeNameDescription
stringentryNameThe name of the translation entry.
CultureInfocultureThe culture to load the translation in.
ParameterparametersThe named or positional parameters that will be inserted into the returned value.

Returns

TypeDescription
Task<>stringThe localized string for the given entryName.

LocalizeAsync(string, string, CultureInfo, params Parameter[])

Retrieves the localized string for the given entryName.

Declaration

Task<string> LocalizeAsync(string contextName, string entryName, CultureInfo culture = null, params Parameter[] parameters)

Parameters

TypeNameDescription
stringcontextNameThe name of the translation context.
stringentryNameThe name of the translation entry.
CultureInfocultureThe culture to load the translation in.
ParameterparametersThe named or positional parameters that will be inserted into the returned value.

Returns

TypeDescription
Task<>stringThe localized string for the given entryName.
If you have suggestions for improving this article, let us know!