Commit bcb55017 authored by Etienne Renault's avatar Etienne Renault
Browse files

cube: rename get_ap into ap

* spot/kripke/kripke.hh,
spot/ltsmin/spins_kripke.hh,
spot/ltsmin/spins_kripke.hxx,
spot/mc/mc_instanciator.hh,
spot/mc/utils.hh,
spot/twacube/twacube.cc,
spot/twacube/twacube.hh,
spot/twacube_algos/convert.cc,
tests/core/twacube.cc,
tests/ltsmin/modelcheck.cc: Here.
parent 44546021
...@@ -58,7 +58,7 @@ namespace spot ...@@ -58,7 +58,7 @@ namespace spot
void recycle(SuccIterator*, unsigned tid); void recycle(SuccIterator*, unsigned tid);
/// \brief This method allow to deallocate a given state. /// \brief This method allow to deallocate a given state.
const std::vector<std::string> get_ap(); const std::vector<std::string> ap();
}; };
#ifndef SWIG #ifndef SWIG
...@@ -84,7 +84,7 @@ namespace spot ...@@ -84,7 +84,7 @@ namespace spot
std::is_same<SuccIter*, decltype(u->succ(State(), 0))>::value && std::is_same<SuccIter*, decltype(u->succ(State(), 0))>::value &&
std::is_same<void, decltype(u->recycle(nullptr, 0))>::value && std::is_same<void, decltype(u->recycle(nullptr, 0))>::value &&
std::is_same<const std::vector<std::string>, std::is_same<const std::vector<std::string>,
decltype(u->get_ap())>::value && decltype(u->ap())>::value &&
std::is_same<void, decltype(u->recycle(nullptr, 0))>::value && std::is_same<void, decltype(u->recycle(nullptr, 0))>::value &&
// Check the SuccIterator // Check the SuccIterator
......
// -*- coding: utf-8 -*- // -*- coding: utf-8 -*-
// Copyright (C) 2017, 2018, 2019 Laboratoire de Recherche et Développement de // Copyright (C) 2017, 2018, 2019, 2020 Laboratoire de Recherche et Développement de
// l'Epita (LRDE) // l'Epita (LRDE)
// //
// This file is part of Spot, a model checking library. // This file is part of Spot, a model checking library.
...@@ -221,7 +221,7 @@ namespace spot ...@@ -221,7 +221,7 @@ namespace spot
void recycle(cspins_iterator* it, unsigned tid); void recycle(cspins_iterator* it, unsigned tid);
/// \brief List the atomic propositions used by *this* kripke /// \brief List the atomic propositions used by *this* kripke
const std::vector<std::string> get_ap(); const std::vector<std::string> ap();
/// \brief The number of thread used by *this* kripke /// \brief The number of thread used by *this* kripke
unsigned get_threads(); unsigned get_threads();
......
// -*- coding: utf-8 -*- // -*- coding: utf-8 -*-
// Copyright (C) 2017, 2018 Laboratoire de Recherche et Développement de // Copyright (C) 2017, 2018, 2020 Laboratoire de Recherche et Développement de
// l'Epita (LRDE) // l'Epita (LRDE)
// //
// This file is part of Spot, a model checking library. // This file is part of Spot, a model checking library.
...@@ -302,7 +302,7 @@ namespace spot ...@@ -302,7 +302,7 @@ namespace spot
} }
const std::vector<std::string> const std::vector<std::string>
kripkecube<cspins_state, cspins_iterator>::get_ap() kripkecube<cspins_state, cspins_iterator>::ap()
{ {
return aps_; return aps_;
} }
......
...@@ -166,9 +166,9 @@ namespace spot ...@@ -166,9 +166,9 @@ namespace spot
algo == mc_algorithm::SWARMING) algo == mc_algorithm::SWARMING)
{ {
SPOT_ASSERT(prop != nullptr); SPOT_ASSERT(prop != nullptr);
SPOT_ASSERT(sys->get_ap().size() == prop->get_ap().size()); SPOT_ASSERT(sys->ap().size() == prop->ap().size());
for (unsigned int i = 0; i < sys->get_ap().size(); ++i) for (unsigned int i = 0; i < sys->ap().size(); ++i)
SPOT_ASSERT(sys->get_ap()[i].compare(prop->get_ap()[i]) == 0); SPOT_ASSERT(sys->ap()[i].compare(prop->ap()[i]) == 0);
} }
switch (algo) switch (algo)
......
...@@ -55,7 +55,7 @@ namespace spot ...@@ -55,7 +55,7 @@ namespace spot
res_->new_state(); res_->new_state();
// Compute the reverse binder. // Compute the reverse binder.
auto aps = this->sys_.get_ap(); auto aps = this->sys_.ap();
for (unsigned i = 0; i < aps.size(); ++i) for (unsigned i = 0; i < aps.size(); ++i)
{ {
auto k = res_->register_ap(aps[i]); auto k = res_->register_ap(aps[i]);
...@@ -72,7 +72,7 @@ namespace spot ...@@ -72,7 +72,7 @@ namespace spot
void edge(unsigned src, unsigned dst) void edge(unsigned src, unsigned dst)
{ {
cubeset cs(this->sys_.get_ap().size()); cubeset cs(this->sys_.ap().size());
bdd cond = cube_to_bdd(this->todo.back().it->condition(), bdd cond = cube_to_bdd(this->todo.back().it->condition(),
cs, reverse_binder_); cs, reverse_binder_);
res_->new_edge(src, dst, cond); res_->new_edge(src, dst, cond);
...@@ -345,7 +345,7 @@ namespace spot ...@@ -345,7 +345,7 @@ namespace spot
names_ = new std::vector<std::string>(); names_ = new std::vector<std::string>();
int i = 0; int i = 0;
for (auto ap : this->twa_->get_ap()) for (auto ap : this->twa_->ap())
{ {
auto idx = res_->register_ap(ap); auto idx = res_->register_ap(ap);
reverse_binder_[i++] = idx; reverse_binder_[i++] = idx;
......
// -*- coding: utf-8 -*- // -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016, 2018 Laboratoire de Recherche et Developpement de // Copyright (C) 2015, 2016, 2018, 2020 Laboratoire de Recherche et Developpement de
// l'EPITA (LRDE). // l'EPITA (LRDE).
// //
// This file is part of Spot, a model checking library. // This file is part of Spot, a model checking library.
...@@ -66,7 +66,7 @@ namespace spot ...@@ -66,7 +66,7 @@ namespace spot
return acc_; return acc_;
} }
std::vector<std::string> twacube::get_ap() const std::vector<std::string> twacube::ap() const
{ {
return aps_; return aps_;
} }
......
// -*- coding: utf-8 -*- // -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016 Laboratoire de Recherche // Copyright (C) 2015, 2016, 2020 Laboratoire de Recherche
// et Développement de l'Epita (LRDE). // et Développement de l'Epita (LRDE).
// //
// This file is part of Spot, a model checking library. // This file is part of Spot, a model checking library.
...@@ -139,7 +139,7 @@ namespace spot ...@@ -139,7 +139,7 @@ namespace spot
acc_cond& acc(); acc_cond& acc();
/// \brief Returns the names of the atomic properties. /// \brief Returns the names of the atomic properties.
std::vector<std::string> get_ap() const; std::vector<std::string> ap() const;
/// \brief This method creates a new state. /// \brief This method creates a new state.
unsigned new_state(); unsigned new_state();
......
...@@ -154,7 +154,7 @@ namespace spot ...@@ -154,7 +154,7 @@ namespace spot
// Grep bdd id for each atomic propositions // Grep bdd id for each atomic propositions
std::vector<int> bdds_ref; std::vector<int> bdds_ref;
for (auto& ap : twacube->get_ap()) for (auto& ap : twacube->ap())
bdds_ref.push_back(res->register_ap(ap)); bdds_ref.push_back(res->register_ap(ap));
// Build all resulting states // Build all resulting states
......
// -*- coding: utf-8 -*- // -*- coding: utf-8 -*-
// Copyright (C) 2015, 2016, 2018 Laboratoire de Recherche et Développement // Copyright (C) 2015, 2016, 2018, 2020 Laboratoire de Recherche et
// de l'Epita. // Développement de l'Epita.
// //
// This file is part of Spot, a model checking library. // This file is part of Spot, a model checking library.
// //
...@@ -52,7 +52,7 @@ int main() ...@@ -52,7 +52,7 @@ int main()
spot::print_dot(std::cout, tg, "A"); spot::print_dot(std::cout, tg, "A");
std::cout << "-----------\n" << *aut << "-----------\n"; std::cout << "-----------\n" << *aut << "-----------\n";
const std::vector<std::string>& aps = aut->get_ap(); const std::vector<std::string>& aps = aut->ap();
unsigned int seed = 17; unsigned int seed = 17;
for (auto it = aut->succ(2); !it->done(); it->next()) for (auto it = aut->succ(2); !it->done(); it->next())
{ {
......
...@@ -470,7 +470,7 @@ static int checked_main() ...@@ -470,7 +470,7 @@ static int checked_main()
{ {
std::vector<std::string> aps = {}; std::vector<std::string> aps = {};
if (propcube != nullptr) if (propcube != nullptr)
aps = propcube->get_ap(); aps = propcube->ap();
modelcube = spot::ltsmin_model::load(mc_options.model) modelcube = spot::ltsmin_model::load(mc_options.model)
.kripkecube(aps, deadf, mc_options.compress, mc_options.nb_threads); .kripkecube(aps, deadf, mc_options.compress, mc_options.nb_threads);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment