Table of Contents

Class ResourceTranslationInfoProvider

Namespace
CMS.Localization
Assembly
CMS.Globalization.dll

Resource translation management.

[ProviderInterface(typeof(IResourceTranslationInfoProvider))]
[Obsolete("This API was not intended for public use.")]
[ObsoleteSince(29, 1)]
public class ResourceTranslationInfoProvider : AbstractInfoProvider<ResourceTranslationInfo, ResourceTranslationInfoProvider>, IInfoProvider, ICustomizableProvider, IBulkOperationProvider, IWebFarmProvider, IInfoValidator<ResourceTranslationInfo>, IInfoByGuidProvider<ResourceTranslationInfo>, IInfoByNameProvider<ResourceTranslationInfo>, IBulkInfoProvider<ResourceTranslationInfo>, IResourceTranslationInfoProvider, IInfoProvider<ResourceTranslationInfo>, IInfoByIdProvider<ResourceTranslationInfo>
Inheritance
object
ResourceTranslationInfoProvider
Implements
Inherited Members
Extension Methods

Methods

Add(int, int, string)

Creates ResourceTranslationInfo binding.

public virtual void Add(int resourceStringId, int cultureId, string translationText)

Parameters

resourceStringId int

Resource string ID.

cultureId int

Culture ID.

translationText string

Translation text.

DeleteInfo(ResourceTranslationInfo)

Deletes the object to the database.

protected override void DeleteInfo(ResourceTranslationInfo info)

Parameters

info ResourceTranslationInfo

Object to delete

Get(int, int)

Gets an instance of the ResourceTranslationInfo binding structure.

public virtual ResourceTranslationInfo Get(int resourceStringId, int cultureId)

Parameters

resourceStringId int

Resource string ID.

cultureId int

Culture ID.

Returns

ResourceTranslationInfo

Returns an instance of ResourceTranslationInfo corresponding to given identifiers or null.

GetAsync(int, int, CancellationToken?)

Asynchronously gets an instance of the ResourceTranslationInfo binding structure.

public virtual Task<ResourceTranslationInfo> GetAsync(int resourceStringId, int cultureId, CancellationToken? cancellationToken = null)

Parameters

resourceStringId int

Resource string ID.

cultureId int

Culture ID.

cancellationToken CancellationToken?

The cancellation instruction.

Returns

Task<ResourceTranslationInfo>

Returns a task returning either an instance of ResourceTranslationInfo corresponding to given identifiers or null.

Remove(int, int)

Deletes ResourceTranslationInfo binding.

public virtual void Remove(int resourceStringId, int cultureId)

Parameters

resourceStringId int

Resource string ID.

cultureId int

Culture ID.

SetInfo(ResourceTranslationInfo)

Inserts or Updates the object to the database.

protected override void SetInfo(ResourceTranslationInfo info)

Parameters

info ResourceTranslationInfo

Object to insert / update