Class TranslationProviderServer
Represents server-provided access to translation memories and provides related administrative and maintenance services.
Inheritance
Inherited Members
Namespace: Sdl.LanguagePlatform.TranslationMemoryApi
Assembly: Sdl.LanguagePlatform.TranslationMemoryApi.dll
Syntax
public class TranslationProviderServer
Constructors
TranslationProviderServer(Uri, Boolean, String, String)
Creates a new translation provider server.
Declaration
public TranslationProviderServer(Uri serverUri, bool useWindowsAuthentication, string userName, string password)
Parameters
Type | Name | Description |
---|---|---|
System. |
serverUri | The URI of the server. This is of the form http://servername:port. |
System. |
useWindowsAuthentication | Whether to use Windows authentication. When set to , userName
and password have to be specified. When set to , either pass for userName
and password in order to log on as the currently logged on Windows user, or set userName
to a domain-qualified Windows user name and password to the matching password to log on using basic Windows authentication.
|
System. |
userName | When using custom authentication or basic Windows authentication, the user name of the user. Pass
to use integrated Windows authentication(see useWindowsAuthentication ).
|
System. |
password | When using custom authentication or basic Windows authentication the password of the user. Pass
to use integrated Windows authentication (see useWindowsAuthentication ).
|
TranslationProviderServer(Uri, String, String, DateTime)
Creates a new translation provider server.
Declaration
public TranslationProviderServer(Uri serverUri, string userName, string authToken, DateTime expirationDate)
Parameters
Type | Name | Description |
---|---|---|
System. |
serverUri | The URI of the server. This is of the form http://servername:port. |
System. |
userName | |
System. |
authToken | |
System. |
expirationDate |
Properties
IsTranslationAndAnalysisServiceSupported
Check if the server has Translation and Analysis Service support.
Declaration
public bool IsTranslationAndAnalysisServiceSupported { get; }
Property Value
Type | Description |
---|---|
System. |
IsTranslationMemoryLocationSupported
If the server version is OnPremiseRest/Cloud, returns a flag to indicate if the translation memory location is supported
Declaration
public bool IsTranslationMemoryLocationSupported { get; }
Property Value
Type | Description |
---|---|
System. |
Uri
Gets the URI that was used to connect to this server.
Declaration
public Uri Uri { get; }
Property Value
Type | Description |
---|---|
System. |
Methods
DeleteBackgroundTask(Guid)
Deletes a background task.
Declaration
public void DeleteBackgroundTask(Guid taskId)
Parameters
Type | Name | Description |
---|---|---|
System. |
taskId | The unique identifier for the task to be deleted. |
DeleteBackgroundTasks(ICollection<Guid>)
Deletes a collection background tasks.
Declaration
public void DeleteBackgroundTasks(ICollection<Guid> tasksIdentities)
Parameters
Type | Name | Description |
---|---|---|
System. |
tasksIdentities | The unique identifiers for the tasks to be deleted. |
GetContainer(Guid, ContainerProperties)
Gets the Translation
Declaration
public TranslationMemoryContainer GetContainer(Guid id, ContainerProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
id | The container id. |
Container |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Translation |
The container, or null if no container with given id exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetContainer(String, ContainerProperties)
Gets the Translation
Declaration
public TranslationMemoryContainer GetContainer(string path, ContainerProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
path | The path of the container |
Container |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Translation |
The container, or null if no container with given path exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetContainers(ContainerProperties)
Gets all translation memory containers managed by this translation provider server.
Declaration
public ReadOnlyCollection<TranslationMemoryContainer> GetContainers(ContainerProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
Container |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
System. |
A read-only collection of translation memory containers. |
GetDatabaseServer(Guid, DatabaseServerProperties)
Obtains a representation of an existing database server.
Declaration
public DatabaseServer GetDatabaseServer(Guid id, DatabaseServerProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
id | The database server id. |
Database |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Database |
The database server, or null if no database server with the given id exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetDatabaseServer(String, DatabaseServerProperties)
Obtains a representation of an existing database server.
Declaration
public DatabaseServer GetDatabaseServer(string path, DatabaseServerProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
path | The path of the database server (note that this is not the physical server name). |
Database |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Database |
The database server, or null if no database server with the given id exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetDatabaseServers(DatabaseServerProperties)
Gets the database servers registered with this server for use as translation memory container hosts.
Declaration
public ReadOnlyCollection<DatabaseServer> GetDatabaseServers(DatabaseServerProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
Database |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
System. |
A read-only collection of database servers registered with this server. |
GetDefaultLanguageResources(CultureInfo)
Gets default language resources for the specified language from the server.
Declaration
public LanguageResourceBundle GetDefaultLanguageResources(CultureInfo language)
Parameters
Type | Name | Description |
---|---|---|
System. |
language | The language for which to get the default language resources. |
Returns
Type | Description |
---|---|
Language |
A Language |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetDefaultLanguageResources(String)
Gets default language resources for the specified language code from the server.
Declaration
public LanguageResourceBundle GetDefaultLanguageResources(string languageCode)
Parameters
Type | Name | Description |
---|---|---|
System. |
languageCode | The language code for which to get the default language resources. |
Returns
Type | Description |
---|---|
Language |
A Language |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetFieldsTemplate(Guid, FieldsTemplateProperties)
Gets the fields template with the specified id
,
or null if no such fields template exists.
Declaration
public ServerBasedFieldsTemplate GetFieldsTemplate(Guid id, FieldsTemplateProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
id | The fields template ID. |
Fields |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Server |
The fields template, or null if no fields template with given id exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetFieldsTemplate(String, FieldsTemplateProperties)
Gets the fields template with the specified path
,
or null if no such fields template exists.
Declaration
public ServerBasedFieldsTemplate GetFieldsTemplate(string path, FieldsTemplateProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
path | The fields template path. |
Fields |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Server |
The fields template, or null if no fields template with given id exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetFieldsTemplates(FieldsTemplateProperties, Boolean)
Gets all the fields templates available on this server.
Declaration
public ReadOnlyCollection<ServerBasedFieldsTemplate> GetFieldsTemplates(FieldsTemplateProperties additionalProperties, bool includeTmSpecific = true)
Parameters
Type | Name | Description |
---|---|---|
Fields |
additionalProperties | |
System. |
includeTmSpecific |
Returns
Type | Description |
---|---|
System. |
A read-only collection of fields templates. |
GetLanguageResourcesTemplate(Guid, LanguageResourcesTemplateProperties)
Gets the LanguageResourcesTemplate with the specified ID.
Declaration
public ServerBasedLanguageResourcesTemplate GetLanguageResourcesTemplate(Guid id, LanguageResourcesTemplateProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
id | The language resources template ID. |
Language |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Server |
The language resource group template, or |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetLanguageResourcesTemplate(String, LanguageResourcesTemplateProperties)
Gets the language resources template with the specified path.
Declaration
public ServerBasedLanguageResourcesTemplate GetLanguageResourcesTemplate(string path, LanguageResourcesTemplateProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
path | The language resources template path. |
Language |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Server |
The language resource group template, or |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetLanguageResourcesTemplates(LanguageResourcesTemplateProperties, Boolean)
Gets all the language resources templates available on this server.
Declaration
public ReadOnlyCollection<ServerBasedLanguageResourcesTemplate> GetLanguageResourcesTemplates(LanguageResourcesTemplateProperties additionalProperties, bool includeTmSpecific = true)
Parameters
Type | Name | Description |
---|---|---|
Language |
additionalProperties | |
System. |
includeTmSpecific |
Returns
Type | Description |
---|---|
System. |
A read-only collection of language resources templates. |
GetLicensingStatusInformation()
Gets the license status information for this translation provider server.
Declaration
public LicensingStatusInformation GetLicensingStatusInformation()
Returns
Type | Description |
---|---|
Licensing |
A license status information object. |
GetScheduledTranslationMemoryExport(Guid)
Gets a scheduled translation memory export by export Id.
Declaration
public ScheduledServerTranslationMemoryExport GetScheduledTranslationMemoryExport(Guid exportId)
Parameters
Type | Name | Description |
---|---|---|
System. |
exportId |
Returns
Type | Description |
---|---|
Scheduled |
GetScheduledTranslationMemoryImport(Guid)
Gets a scheduled translation memory import by import Id.
Declaration
public ScheduledServerTranslationMemoryImport GetScheduledTranslationMemoryImport(Guid importId)
Parameters
Type | Name | Description |
---|---|---|
System. |
importId |
Returns
Type | Description |
---|---|
Scheduled |
GetTranslationMemories(TranslationMemoryProperties)
Returns a collection of all the server-based translation memories on this server.
Declaration
public ReadOnlyCollection<ServerBasedTranslationMemory> GetTranslationMemories(TranslationMemoryProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
Translation |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
System. |
A read-only collection of server-based translation memories. |
GetTranslationMemoriesByQuery(TranslationMemoryQuery)
Returns the paged collection of the server-based translation memories on this server.
Declaration
public PagedTranslationMemories GetTranslationMemoriesByQuery(TranslationMemoryQuery query)
Parameters
Type | Name | Description |
---|---|---|
Translation |
query |
Returns
Type | Description |
---|---|
Paged |
A read-only paged collection of server-based translation memories. |
GetTranslationMemoriesQueryFilters()
Gets all the available filters to be queried for translation memories.
Declaration
public TranslationMemoryQueryFilters GetTranslationMemoriesQueryFilters()
Returns
Type | Description |
---|---|
Translation |
GetTranslationMemory(Guid, TranslationMemoryProperties)
Gets the translation memory with the corresponding unique id.
Declaration
public ServerBasedTranslationMemory GetTranslationMemory(Guid id, TranslationMemoryProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
id | The translation memory's unique id. |
Translation |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Server |
The translation memory, or null if no translation memory with given id exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetTranslationMemory(String, TranslationMemoryProperties)
Gets the translation memory with the corresponding unique path. Gets a translation memory through its path.
Declaration
public ServerBasedTranslationMemory GetTranslationMemory(string path, TranslationMemoryProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
path | The translation memory's name. |
Translation |
additionalProperties | The additional related objects to retrieve. |
Returns
Type | Description |
---|---|
Server |
The translation memory, or null if no translation memory with given path exists. |
Exceptions
Type | Condition |
---|---|
System. |
Thrown when |
GetTranslationMemorySummary(String, TranslationMemoryProperties)
Gets the translation memory summary with the corresponding unique path. Gets a translation memory summary through its path. No template information is provided.
Declaration
public ServerBasedTranslationMemory GetTranslationMemorySummary(string path, TranslationMemoryProperties additionalProperties)
Parameters
Type | Name | Description |
---|---|---|
System. |
path | |
Translation |
additionalProperties |
Returns
Type | Description |
---|---|
Server |
Exceptions
Type | Condition |
---|---|
System. |
Release()
Calls endpoint to release Translation Provider CALs
Declaration
public void Release()