tetengo
1.8.2
A multipurpose library set
Loading...
Searching...
No Matches
path.hpp
Go to the documentation of this file.
1
7
#if !defined(TETENGO_LATTICE_PATH_HPP)
8
#define TETENGO_LATTICE_PATH_HPP
9
10
#include <vector>
11
12
#include <
tetengo/lattice/node.hpp
>
13
14
15
namespace
tetengo::lattice
16
{
20
class
path
21
{
22
public
:
23
// constructors and destructor
24
28
path
();
29
36
path
(std::vector<node>
nodes
,
int
cost
);
37
38
39
// functions
40
47
[[nodiscard]]
bool
empty
()
const
;
48
54
[[nodiscard]]
const
std::vector<node>&
nodes
()
const
;
55
61
[[nodiscard]]
int
cost
()
const
;
62
63
64
private
:
65
// variables
66
67
std::vector<node> m_nodes;
68
69
int
m_cost;
70
};
71
72
73
}
74
75
76
#endif
tetengo::lattice::path
A path.
Definition
path.hpp:21
tetengo::lattice::path::empty
bool empty() const
Returns true when this path is empty.
tetengo::lattice::path::cost
int cost() const
Returns the cost.
tetengo::lattice::path::path
path()
Creates an empty path.
tetengo::lattice::path::nodes
const std::vector< node > & nodes() const
Returns the nodes.
tetengo::lattice::path::path
path(std::vector< node > nodes, int cost)
Creates a path.
tetengo::lattice
A lattice library.
node.hpp
A node.
library
lattice
cpp
include
tetengo
lattice
path.hpp
Generated on Sat Aug 31 2024 15:54:00 for tetengo by
1.12.0