![]() |
OpenMS
|
#include <OpenMS/ANALYSIS/ID/AhoCorasickAmbiguous.h>
Public Member Functions | |
| void | setQuery (const std::string &haystack) |
| size_t | textPos () const |
| const char * | textPosIt () const |
| const std::string & | getQuery () const |
| The current query. | |
| AA | nextValidAA () |
Public Attributes | |
| friend | ACScout |
| std::vector< Hit > | hits |
| std::queue< ACScout > | scouts |
| Index | tree_pos |
| position in trie (for the Primary) | |
Private Attributes | |
| const char * | it_q_ = "" |
| std::string | query_ |
| current query ( = haystack = text) | |
A state object for an ACTrie, i.e. dynamic information when traversing the trie (which is 'const' after construction) Useful when using multi-threading; each thread can walk the trie and keep track of its state using an instance of this class
| const std::string & getQuery | ( | ) | const |
The current query.
| AA nextValidAA | ( | ) |
| void setQuery | ( | const std::string & | haystack | ) |
Set a haystack (query) where the needles (patterns) are to be searched This also resets the current trie-node to ROOT, and voids the hits
| size_t textPos | ( | ) | const |
Where in the text are we currently?
| const char * textPosIt | ( | ) | const |
Where in the text are we currently?
| friend ACScout |
| std::vector<Hit> hits |
current hits found
|
private |
position in query; defaults to an empty string literal, so that a state which never saw a setQuery() reads as 'query fully consumed' instead of dereferencing an uninitialized pointer (could happen in OpenMP context, with more threads than proteins to search, where some threads never get a protein to search)
|
private |
current query ( = haystack = text)
| std::queue<ACScout> scouts |
initial scout points which are currently active and need processing. this needs a deque: ACTrie::nextHitsNoClear_() holds a reference to front() while pushing new scouts, which only a deque (not a vector) keeps valid.
| Index tree_pos |
position in trie (for the Primary)