nlib
nn::nlib::succinct::WordFilterBuilder Class Referencefinal

Class to create a WordFilter object that corresponds to a term and excluded terms. More...

#include "nn/nlib/succinct/WordFilter.h"

Public Member Functions

bool Init () noexcept
 Initializes an object. More...
 
WordFilterBuild () noexcept
 Creates a WordFilter object. More...
 
bool AddWord (const char *str) noexcept
 Adds term to match to the filter. More...
 
bool AddWords (const char *str, size_t len) noexcept
 Adds a string from an array containing a set of target strings. The strings must be delimited by newlines (CRLF or LF). More...
 
bool AddWords (const char *str) noexcept
 Adds a string from an array containing a set of target strings. The strings must be delimited by newlines (CRLF or LF). More...
 
bool AddExcludeWord (const char *str) noexcept
 Adds an excluded term. More...
 
bool AddExcludeWords (const char *str, size_t len) noexcept
 Adds a string from an array containing a set of excluded terms. The strings must be delimited by newlines (CRLF or LF). More...
 
bool AddExcludeWords (const char *str) noexcept
 Adds a string from an array containing a set of excluded terms. The strings must be delimited by newlines (CRLF or LF). More...
 
Basic Member Functions
 WordFilterBuilder () noexcept
 Instantiates the object.
 
 ~WordFilterBuilder () noexcept
 Destructor.
 

Detailed Description

Class to create a WordFilter object that corresponds to a term and excluded terms.

Definition at line 59 of file WordFilter.h.

Member Function Documentation

§ AddExcludeWord()

nn::nlib::succinct::WordFilterBuilder::AddExcludeWord ( const char *  str)
noexcept

Adds an excluded term.

Parameters
[in]strExcluded term.
Returns
Returns true when successful.

§ AddExcludeWords() [1/2]

nn::nlib::succinct::WordFilterBuilder::AddExcludeWords ( const char *  str,
size_t  len 
)
noexcept

Adds a string from an array containing a set of excluded terms. The strings must be delimited by newlines (CRLF or LF).

Parameters
[in]strPointer to the string.
[in]lenThe string length (the value of strlen).
Returns
Returns true when successful.

§ AddExcludeWords() [2/2]

nn::nlib::succinct::WordFilterBuilder::AddExcludeWords ( const char *  str)
inlinenoexcept

Adds a string from an array containing a set of excluded terms. The strings must be delimited by newlines (CRLF or LF).

Parameters
[in]strPointer to the string.
Returns
Returns true when successful.

Definition at line 72 of file WordFilter.h.

§ AddWord()

nn::nlib::succinct::WordFilterBuilder::AddWord ( const char *  str)
noexcept

Adds term to match to the filter.

Parameters
[in]strTerm to match.
Returns
Returns true when successful.

§ AddWords() [1/2]

nn::nlib::succinct::WordFilterBuilder::AddWords ( const char *  str,
size_t  len 
)
noexcept

Adds a string from an array containing a set of target strings. The strings must be delimited by newlines (CRLF or LF).

Parameters
[in]strPointer to the string.
[in]lenThe string length (the value of strlen).
Returns
Returns true when successful.

§ AddWords() [2/2]

nn::nlib::succinct::WordFilterBuilder::AddWords ( const char *  str)
inlinenoexcept

Adds a string from an array containing a set of target strings. The strings must be delimited by newlines (CRLF or LF).

Parameters
[in]strPointer to the string.
Returns
Returns true when successful.

Definition at line 67 of file WordFilter.h.

§ Build()

nn::nlib::succinct::WordFilterBuilder::Build ( )
noexcept

Creates a WordFilter object.

Returns
Pointer to the WordFilter object.
Description
Call after setting target terms for the filter using functions such as AddWord and AddExcludeWord.

§ Init()

nn::nlib::succinct::WordFilterBuilder::Init ( )
noexcept

Initializes an object.

Returns
Returns true when successful.

The documentation for this class was generated from the following files: