* src/ltlast/atomic_prop.hh, src/ltlast/binop.hh,

src/ltlast/constant.hh, src/ltlast/formula.hh,
src/ltlast/multop.hh, src/ltlast/unop.hh, src/ltlast/visitor.hh,
src/ltlenv/defaultenv.hh, src/ltlenv/environment.hh,
src/ltlparse/public.hh, src/ltlvisit/clone.hh,
src/ltlvisit/dotty.hh, src/ltlvisit/dump.hh,
src/ltlvisit/equals.hh, src/ltlvisit/lunabbrev.hh,
src/ltlvisit/nenoform.hh, src/ltlvisit/tunabbrev.hh: Add
Doxygen comments.
* src/visitor.hh: Do not use const_sel.  This clarify
the code and helps Doxygen.
This commit is contained in:
Alexandre Duret-Lutz 2003-04-18 15:02:55 +00:00
parent 4b8b02e811
commit d35817ccd9
19 changed files with 239 additions and 51 deletions

View file

@ -9,13 +9,19 @@ namespace spot
namespace ltl
{
/// \brief A laxist environment.
///
/// The environment recognize all atomic propositions.
///
/// This is a singleton. Use default_environment::instance()
/// to obtain the instance.
class default_environment : public environment
{
public:
virtual formula* require(const std::string& prop_str);
virtual const std::string& name();
/* This class is a singleton. */
/// Get the sole instance of spot::ltl::default_environment.
static default_environment& instance();
protected:
default_environment();

View file

@ -9,20 +9,32 @@ namespace spot
namespace ltl
{
/// An environment that describe atomic propositions.
class environment
{
public:
// Check whether the environment contains the atomic proposition
// described by prop_str.
// Note this is NOT a const method. Some environment will
// "create" the atomic proposition when asked.
// We return a formula instead of an atomic_prop, because this
// will allow nifty tricks (e.g., we could name formulae in an
// environment, and let the parser build a larger tree from
// these).
/// \brief Obtain the formula associated to \a prop_str
///
/// Usually \a prop_str, is the name of an atomic proposition,
/// a spot::ltl::require simply returns the associated
/// spot::ltl::atomic_prop.
///
/// Note this is not a \c const method. Some environment will
/// "create" the atomic proposition when asked.
///
/// We return a spot::ltl::formula instead of an
/// spot::ltl::atomic_prop, because this
/// will allow nifty tricks (e.g., we could name formulae in an
/// environment, and let the parser build a larger tree from
/// these).
///
/// \return 0 iff \a prop_str is not part of the environment,
/// or the associated spot::ltl::formula otherwise.
virtual formula* require(const std::string& prop_str) = 0;
/// Get the name of the environment.
virtual const std::string& name() = 0;
// FIXME: More functions will be needed later, but
// it's enough for now.
};