Class LF
LF is an object storing all necessary information for the LF-mapping.

Defined in <seqan/Index.h>
Signature template <typename TText, typename TSpec, typename TConfig> struct LF;

Template Parameters

TText The type of the text the LF table is constructed from.
TSpec A possibility to specialize the LF table. Default: void
TConfig A configuration object for easily defining the LF table fibres.

Interface Function Overview

Interface Functions Detail

void clear(lfTable);

Resets the LF table.

Parameters

lfTable The LF table to be cleared.

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

void createLF(lfTable, text, sa);

Creates the LF table

Parameters

lfTable The LF table to be constructed.
text The underlying text Types: String.
sa The suffix array of the LF table underlying text. Types: String, StringSet.

Returns

TReturn Returns a bool which is true on successes and false otherwise.

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

bool empty(lfTable);

Clears the LF table.

Parameters

lfTable The LF table to be checked.

Returns

bool true if the LF table is empty, false otherwise.

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

TFibre getFibre(lfTable, fibreTag);

Returns a specific fibre of a LF table.

Parameters

fibreTag A tag that identifies the Fibre. Types: LFTableFibres
lfTable The LF table.

Returns

TFibre A reference to the Fibre object of type Fibre<LF<TText, TSpec, TConfig>, FibrePrefixSums>::Type

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

lfMapping(lfTable, pos)

Returns the position of an character at a specified position of L in F. L corresponds to the last column of the sorted cyclic rotations of the original text, while F correspond to the first column.

Parameters

lfTable The LF holding the occurrence and prefix sum table.
pos The position in L. Types: UnsignedIntegerConcept

Returns

TReturn Returns the position of the character L[c] in F. The returned position is of the same type as pos. Types: The type of the position.

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

bool open(lfTable, fileName[, openMode]);

This functions loads a LF table from disk.

Parameters

lfTable The LF object.
fileName C-style character string containing the file name.
openMode The combination of flags defining how the file should be opened. To open a file read-only, write-only or to read and write use OPEN_RDONLY, OPEN_WRONLY, or OPEN_RDWR. To create or overwrite a file add OPEN_CREATE. To append a file if existing add OPEN_APPEND. To circumvent problems, files are always opened in binary mode. Default: OPEN_RDWR | OPEN_CREATE | OPEN_APPEND.

Returns

bool true on success.

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.

bool save(lfTable, fileName[, openMode]);

This functions saves a LF table to disk.

Parameters

lfTable The LF object to save.
fileName C-style character string containing the file name.
openMode The combination of flags defining how the file should be opened. To open a file read-only, write-only or to read and write use OPEN_RDONLY, OPEN_WRONLY, or OPEN_RDWR. To create or overwrite a file add OPEN_CREATE. To append a file if existing add OPEN_APPEND. To circumvent problems, files are always opened in binary mode. Default: OPEN_RDWR | OPEN_CREATE | OPEN_APPEND.

Returns

bool true on success.

Data Races

If not stated otherwise, concurrent invocation is not guaranteed to be thread-safe.