Class AbstractBilingualParser
Base class that can be used to implement bilingual parsers.
Takes care of the basics involved in implementing the IBilingualParser and IBilingualFileTypeComponent interfaces.
Implements
Inherited Members
Namespace: SdlSdl.FileTypeSupportFrameworkBilingualApi
Assembly: Sdl.FileTypeSupport.Framework.Core.dll
Syntax
public abstract class AbstractBilingualParser : AbstractBilingualFileTypeComponent, IBilingualContentMessageReporter, IBasicMessageReporter, IBilingualContentMessageReporterWithExtendedData, IBasicMessageReporterWithExtendedData, IBilingualParser, IParser, IDisposable, IBilingualFileTypeComponent
Remarks
Implementations are not required to derive from this class. It is designed as a convenient default implementation to be used when appropriate.
Constructors
AbstractBilingualParser()
Declaration
protected AbstractBilingualParser()
Properties
DocumentProperties
Default implementation; stores the value in a data member.
Declaration
public IDocumentProperties DocumentProperties { get; set; }
Property Value
Type | Description |
---|---|
IDocumentProperties |
FileRestriction
Default implementation; sotres the value in a data member.
Declaration
public Predicate<IPersistentFileConversionProperties> FileRestriction { get; set; }
Property Value
Type | Description |
---|---|
PredicateIPersistentFileConversionProperties |
Output
Default implementation; stores the value in a data member.
Declaration
public IBilingualContentHandler Output { get; set; }
Property Value
Type | Description |
---|---|
IBilingualContentHandler |
Methods
Dispose()
Implements IDisposable. Just calls Dispose saying that this is an explicit disposal and tells the GC not to call the Finalizer.
Declaration
public void Dispose()
Dispose(bool)
Last change for the Parser to dispose manage and unmanged objects. It can be overriden by subclases.
Declaration
protected virtual void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
bool | disposing | indicates if the dispose is explicit or implicit (from GC) |
~AbstractBilingualParser()
The distructor just calls Dispose with false parameter specifying this is a cakl from GC.
Declaration
protected ~AbstractBilingualParser()
OnProgress(byte)
Raises the Progress event.
Declaration
public virtual void OnProgress(byte percent)
Parameters
Type | Name | Description |
---|---|---|
byte | percent |
ParseNext()
The framework calls this method to parse a chunk of content. It must be overridden in derived classes to provide the actual parser implementation.
Declaration
public abstract bool ParseNext()
Returns
Type | Description |
---|---|
bool |
|
Events
Progress
Default implementation of this event. Use OnProgress(byte) to raise the event.
Declaration
public event EventHandler<ProgressEventArgs> Progress
Event Type
Type | Description |
---|---|
EventHandlerProgressEventArgs |