Class TMXWriter
Represents a writer for exporting translation units into the TMX format.
Inherited Members
Namespace: SdlSdl.LanguagePlatformIOTMX
Assembly: Sdl.LanguagePlatform.IO.dll
Syntax
public class TMXWriter : IEventReceiver, IDisposable
Constructors
TMXWriter(Stream)
Initializes a new instance of the TMXWriter class with the specified output stream and UTF8 encoding. The ICultureMetadataManager instance used is the obsolete LanguageRegistryApi.Instance.CultureMetadataManager.
Declaration
[Obsolete("Use version providing ICultureMetadataManager")]
public TMXWriter(Stream stream)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The output stream. |
TMXWriter(Stream, ICultureMetadataManager)
Initializes a new instance of the TMXWriter class with the specified output stream and UTF8 encoding.
Declaration
public TMXWriter(Stream stream, ICultureMetadataManager cultureMetadataManager)
Parameters
Type | Name | Description |
---|---|---|
Stream | stream | The output stream. |
ICultureMetadataManager | cultureMetadataManager | Language culture meta-data source. |
TMXWriter(Stream, TMXWriterSettings, ICultureMetadataManager)
Initializes a new instance of the TMXWriter class with the specified output stream and encoding.
Declaration
public TMXWriter(Stream outStream, TMXWriterSettings writerSettings, ICultureMetadataManager cultureMetadataManager)
Parameters
Type | Name | Description |
---|---|---|
Stream | outStream | The output stream. |
TMXWriterSettings | writerSettings | The TMXWriterSettingsTMX writer settings to apply. |
ICultureMetadataManager | cultureMetadataManager | Language culture meta-data source. |
TMXWriter(string)
Initializes a new instance of the TMXWriter class with the specified file name and UTF8 encoding.
Declaration
[Obsolete("Use version providing ICultureMetadataManager")]
public TMXWriter(string filename)
Parameters
Type | Name | Description |
---|---|---|
string | filename | The file name. |
TMXWriter(string, ICultureMetadataManager)
Initializes a new instance of the TMXWriter class with the specified file name and UTF8 encoding.
Declaration
public TMXWriter(string filename, ICultureMetadataManager cultureMetadataManager)
Parameters
Type | Name | Description |
---|---|---|
string | filename | The file name. |
ICultureMetadataManager | cultureMetadataManager | Language culture meta-data source. |
TMXWriter(string, TMXWriterSettings)
Initializes a new instance of the TMXWriter class with the specified file name and encoding.
Declaration
[Obsolete("Use version providing ICultureMetadataManager")]
public TMXWriter(string filename, TMXWriterSettings writerSettings)
Parameters
Type | Name | Description |
---|---|---|
string | filename | The file name. |
TMXWriterSettings | writerSettings | The TMXWriterSettingsTMX writer settings to apply. |
TMXWriter(string, TMXWriterSettings, ICultureMetadataManager)
Initializes a new instance of the TMXWriter class with the specified file name and encoding.
Declaration
public TMXWriter(string filename, TMXWriterSettings writerSettings, ICultureMetadataManager cultureMetadataManager)
Parameters
Type | Name | Description |
---|---|---|
string | filename | The file name. |
TMXWriterSettings | writerSettings | The TMXWriterSettingsTMX writer settings to apply. |
ICultureMetadataManager | cultureMetadataManager | Language culture meta-data source. |
Methods
Close()
Closes the underlying writer.
Declaration
public void Close()
Dispose()
Declaration
public void Dispose()
Emit(Event)
Declaration
public void Emit(Event e)
Parameters
Type | Name | Description |
---|---|---|
Event | e |
EmitAsync(Event)
Writes the specified event to the associated export writer.
Declaration
public Task EmitAsync(Event e)
Parameters
Type | Name | Description |
---|---|---|
Event | e | The event. |
Returns
Type | Description |
---|---|
Task |