Search Results for

    Show / Hide Table of Contents

    Interface IFineGrainedAligner

    Namespace: Sdl.Core.FineGrainedAlignment
    Assembly: Sdl.Core.FineGrainedAlignment.dll
    Syntax
    public interface IFineGrainedAligner

    Properties

    BulkMode

    Declaration
    bool BulkMode { get; set; }
    Property Value
    Type Description
    System.Boolean

    Methods

    Align(IEnumerable<IAlignableContentPair>)

    Performs alignment on the pairs provided - any 'native' alignments should be provided by the corpus

    Declaration
    bool Align(IEnumerable<IAlignableContentPair> pairs)
    Parameters
    Type Name Description
    System.Collections.Generic.IEnumerable<IAlignableContentPair> pairs
    Returns
    Type Description
    System.Boolean

    True if the pairs were aligned, false if alignment was not possible (e.g. model not yet built)

    Remarks

    The AlignmentData provided for each pair can either be null, or a LiftAlignedSpanPairSet containing any 'native' alignments that the corpus can provide. If alignment can't be peformed (e.g. model not built) implementations should set AlignmentData and TranslationModelDate to null for each pair. If alignment can be performed but no alignment data can be computed for a given pair (e.g. no significant tokens, or too many), AlignmentData for the pair should be set to an empty LiftAlignedSpanPairSet.

    Align(IEnumerable<IAlignableContentPair>, CancellationToken, IProgress<Int32>)

    Declaration
    bool Align(IEnumerable<IAlignableContentPair> pairs, CancellationToken token, IProgress<int> progress)
    Parameters
    Type Name Description
    System.Collections.Generic.IEnumerable<IAlignableContentPair> pairs
    System.Threading.CancellationToken token
    System.IProgress<System.Int32> progress
    Returns
    Type Description
    System.Boolean

    AlignEx(IEnumerable<IAlignableContentPair>)

    Same functionality as Align but with detailed result codes for each pair processed.

    Declaration
    AlignResult[] AlignEx(IEnumerable<IAlignableContentPair> pairs)
    Parameters
    Type Name Description
    System.Collections.Generic.IEnumerable<IAlignableContentPair> pairs
    Returns
    Type Description
    AlignResult[]

    An array of AlignResult, one per item in pairs

    AlignEx(IEnumerable<IAlignableContentPair>, CancellationToken, IProgress<Int32>)

    Declaration
    AlignResult[] AlignEx(IEnumerable<IAlignableContentPair> pairs, CancellationToken token, IProgress<int> progress)
    Parameters
    Type Name Description
    System.Collections.Generic.IEnumerable<IAlignableContentPair> pairs
    System.Threading.CancellationToken token
    System.IProgress<System.Int32> progress
    Returns
    Type Description
    AlignResult[]

    CanAlign(IEnumerable<IAlignableContentPair>)

    Declaration
    bool[] CanAlign(IEnumerable<IAlignableContentPair> pairs)
    Parameters
    Type Name Description
    System.Collections.Generic.IEnumerable<IAlignableContentPair> pairs
    Returns
    Type Description
    System.Boolean[]

    SetErrorLogger(Action<Exception, String>)

    Provides an implementation of an error logger for the aligner. In exception cases, the aligner may invoke the implementation, providing either an Exception object, a string, or both.

    Declaration
    void SetErrorLogger(Action<Exception, string> logger)
    Parameters
    Type Name Description
    System.Action<System.Exception, System.String> logger

    The logger implementation

    Remarks

    If the aligner wishes only to invoke using the Exception object, the string argument will be null, and vice versa.

    On this page

    Back to top Generated by DocFX