2000-07-18 11:06:04 +00:00
|
|
|
// -*- C++ -*-
|
2003-08-23 00:17:00 +00:00
|
|
|
/**
|
|
|
|
* \file Variables.h
|
|
|
|
* This file is part of LyX, the document processor.
|
|
|
|
* Licence details can be found in the file COPYING.
|
|
|
|
*
|
2008-11-14 15:58:50 +00:00
|
|
|
* \author Lars Gullik Bjønnes
|
2003-08-23 00:17:00 +00:00
|
|
|
* \author Jean-Marc Lasgouttes
|
|
|
|
*
|
|
|
|
* Full author contact details are available in file CREDITS.
|
|
|
|
*/
|
2000-07-18 11:06:04 +00:00
|
|
|
|
|
|
|
#ifndef VARIABLES_H
|
|
|
|
#define VARIABLES_H
|
|
|
|
|
|
|
|
#include <map>
|
|
|
|
|
|
|
|
|
2006-10-21 00:16:43 +00:00
|
|
|
namespace lyx {
|
|
|
|
|
|
|
|
|
2000-07-18 17:45:27 +00:00
|
|
|
///
|
2000-07-18 11:06:04 +00:00
|
|
|
class Variables {
|
|
|
|
public:
|
2002-03-21 17:27:08 +00:00
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
void set(std::string const &, std::string const &);
|
2002-03-21 17:27:08 +00:00
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
std::string const get(std::string const &) const;
|
2001-06-29 06:40:08 +00:00
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
bool isSet(std::string const & var) const;
|
2002-03-21 17:27:08 +00:00
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
std::string const expand(std::string const &) const;
|
2000-07-18 11:06:04 +00:00
|
|
|
private:
|
2001-06-29 06:40:08 +00:00
|
|
|
///
|
2003-10-06 15:43:21 +00:00
|
|
|
typedef std::map<std::string, std::string> Vars;
|
2001-06-29 06:40:08 +00:00
|
|
|
///
|
|
|
|
Vars vars_;
|
2000-07-18 11:06:04 +00:00
|
|
|
};
|
|
|
|
|
2006-10-21 00:16:43 +00:00
|
|
|
|
|
|
|
} // namespace lyx
|
|
|
|
|
2000-07-18 11:06:04 +00:00
|
|
|
#endif
|