liblevenshtein 4.0.0
A library for generating Finite State Transducers based on Levenshtein Automata.
Loading...
Searching...
No Matches
transition.h
Go to the documentation of this file.
1#ifndef LIBLEVENSHTEIN_COLLECTION_TRANSITION_H
2#define LIBLEVENSHTEIN_COLLECTION_TRANSITION_H
3
5
6
7namespace liblevenshtein {
8
14public:
15
25
31 Transition(const Transition& transition) = default;
32
38 Transition(Transition&& transition) noexcept;
39
46 [[nodiscard]] auto label() const -> char;
47
54
61
70
72
74 char _label;
75
78
81};
82
83} // namespace liblevenshtein
84
85#endif // LIBLEVENSHTEIN_COLLECTION_TRANSITION_H
Represents a position within one or more terms of a DAWG dictionary.
Definition dawg_node.h:20
Represents an edge from one DawgNode to another, annotated with a character label from the current po...
Definition transition.h:13
Transition(const Transition &transition)=default
Copy constructor for this Transition.
DawgNode * _source
DawgNode at the beginning of this Transition.
Definition transition.h:77
auto source() const -> DawgNode *
Returns the initial DawgNode along the edge of this transition.
DawgNode * _target
DawgNode at the ending of this Transition.
Definition transition.h:80
auto label() const -> char
Returns the label annotating the edge from the source to the target of this Transition.
char _label
Annotation along the edge of this Transition.
Definition transition.h:74
Transition(char label, DawgNode *source, DawgNode *target)
Constructs a new Transition from a source DawgNode to its target, annotated by the given label.
Definition transition.cpp:6
auto target() const -> DawgNode *
Returns the destination DawgNode along the edge of this transition.
void query(ll::Dawg *dawg, const std::string &query_term, std::size_t max_distance)
Definition main.cpp:25
Various utilities regarding Levenshtein transducers.
Definition namespaces.dox:9