tetengo 1.9.2
A multipurpose library set
Loading...
Searching...
No Matches
vocabulary.hpp
Go to the documentation of this file.
1
6
7#if !defined(TETENGO_LATTICE_VOCABULARY_HPP)
8#define TETENGO_LATTICE_VOCABULARY_HPP
9
10#include <vector>
11
12#include <boost/core/noncopyable.hpp>
13
14
15namespace tetengo::lattice
16{
17 class connection;
18 class entry_view;
19 class input;
20 class node;
21
22
26 class vocabulary : private boost::noncopyable
27 {
28 public:
29 // constructors and destructor
30
35
39 virtual ~vocabulary();
40
41
42 // functions
43
51 [[nodiscard]] std::vector<entry_view> find_entries(const input& key) const;
52
61 [[nodiscard]] connection find_connection(const node& from, const entry_view& to) const;
62
63
64 private:
65 // virtual functions
66
67 virtual std::vector<entry_view> find_entries_impl(const input& key) const = 0;
68
69 virtual connection find_connection_impl(const node& from, const entry_view& to) const = 0;
70 };
71
72
73}
74
75
76#endif
A connection.
Definition connection.hpp:17
An entry view.
Definition entry.hpp:110
An input.
Definition input.hpp:24
A node.
Definition node.hpp:27
std::vector< entry_view > find_entries(const input &key) const
Finds entries.
vocabulary()
Creates a vocabulary.
virtual ~vocabulary()
Destroys the vocabulary.
connection find_connection(const node &from, const entry_view &to) const
Finds a connection between an origin node and a destination entry.
A lattice library.