Fawkes API
Fawkes Development Version
edge_cost_constraint.h
1
/***************************************************************************
2
* edge_cost_constraint.h - base class for edge cost constraints
3
*
4
* Created: Fri Jul 18 12:08:41 2014
5
* Copyright 2014 Tim Niemueller
6
****************************************************************************/
7
8
/* This program is free software; you can redistribute it and/or modify
9
* it under the terms of the GNU General Public License as published by
10
* the Free Software Foundation; either version 2 of the License, or
11
* (at your option) any later version.
12
*
13
* This program is distributed in the hope that it will be useful,
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
* GNU Library General Public License for more details.
17
*
18
* Read the full text in the LICENSE.GPL file in the doc directory.
19
*/
20
21
#ifndef __NAVGRAPH_CONSTRAINTS_EDGE_COST_CONSTRAINT_H_
22
#define __NAVGRAPH_CONSTRAINTS_EDGE_COST_CONSTRAINT_H_
23
24
#include <vector>
25
#include <string>
26
27
#include <navgraph/navgraph_node.h>
28
29
namespace
fawkes
{
30
#if 0
/* just to make Emacs auto-indent happy */
31
}
32
#endif
33
34
class
Logger;
35
36
class
NavGraphEdgeCostConstraint
37
{
38
public
:
39
NavGraphEdgeCostConstraint
(std::string &name);
40
NavGraphEdgeCostConstraint
(
const
char
*name);
41
virtual
~
NavGraphEdgeCostConstraint
();
42
43
std::string name();
44
45
virtual
bool
compute(
void
)
throw
();
46
virtual
float
cost_factor(
const
fawkes::NavGraphNode
&from,
47
const
fawkes::NavGraphNode
&to)
throw
() = 0;
48
49
bool
operator==(
const
std::string &name)
const
;
50
51
protected
:
52
std::string
name_
;
53
54
};
55
56
}
// end namespace fawkes
57
58
#endif
fawkes
Fawkes library namespace.
fawkes::NavGraphEdgeCostConstraint
Constraint that can be queried for an edge cost factor.
Definition:
edge_cost_constraint.h:36
fawkes::NavGraphEdgeCostConstraint::name_
std::string name_
Name of constraint.
Definition:
edge_cost_constraint.h:52
fawkes::NavGraphNode
Topological graph node.
Definition:
navgraph_node.h:38
src
libs
navgraph
constraints
edge_cost_constraint.h
Generated by
1.8.14