Added IndexFormatter for printing Indices

release/4.3a0
Richard Roberts 2012-06-25 03:46:58 +00:00
parent e81a442c96
commit 3dd2eec937
1 changed files with 6 additions and 0 deletions

View File

@ -21,11 +21,17 @@
#include <cstddef>
#include <boost/function/function1.hpp>
namespace gtsam {
/// Integer variable index type
typedef size_t Index;
/** A function to convert indices to strings, for example by translating back
* to a nonlinear key and then to a Symbol. */
typedef boost::function<std::string(Index)> IndexFormatter;
/**
* Helper class that uses templates to select between two types based on
* whether TEST_TYPE is const or not.