Storm
A Modern Probabilistic Model Checker
Loading...
Searching...
No Matches
StateBlock.cpp
Go to the documentation of this file.
2
3namespace storm {
4namespace storage {
6 return states.begin();
7}
8
10 return states.begin();
11}
12
14 return states.end();
15}
16
18 return states.end();
19}
20
21std::size_t StateBlock::size() const {
22 return states.size();
23}
24
25bool StateBlock::empty() const {
26 return states.empty();
27}
28
29void StateBlock::insert(value_type const& state) {
30 states.insert(state);
31}
32
33StateBlock::iterator StateBlock::insert(container_type::const_iterator iterator, value_type const& state) {
34 return states.insert(iterator, state);
35}
36
37void StateBlock::erase(value_type const& state) {
38 states.erase(state);
39}
40
41bool StateBlock::containsState(value_type const& state) const {
42 return this->states.find(state) != this->states.end();
43}
44
46 return this->states;
47}
48
49std::ostream& operator<<(std::ostream& out, FlatSetStateContainer const& block) {
50 out << "{";
51 for (auto const& element : block) {
52 out << element << ", ";
53 }
54 out << "}";
55 return out;
56}
57
58std::ostream& operator<<(std::ostream& out, StateBlock const& block) {
59 out << block.getStates();
60 return out;
61}
62
63} // namespace storage
64} // namespace storm
std::size_t size() const
Retrieves the number of states in this SCC.
container_type::iterator iterator
Definition StateBlock.h:25
iterator begin()
Returns an iterator to the states in this SCC.
Definition StateBlock.cpp:5
bool containsState(value_type const &state) const
Retrieves whether the given state is in the SCC.
FlatSetStateContainer container_type
Definition StateBlock.h:22
void insert(value_type const &state)
Inserts the given element into this SCC.
void erase(value_type const &state)
Removes the given element from this SCC.
iterator end()
Returns an iterator that points one past the end of the states in this SCC.
container_type::value_type value_type
Definition StateBlock.h:23
container_type const & getStates() const
Retrieves the set of states contained in the StateBlock.
container_type::const_iterator const_iterator
Definition StateBlock.h:26
bool empty() const
Retrieves whether this SCC is empty.
storm::storage::FlatSet< sparse::state_type > FlatSetStateContainer
Definition StateBlock.h:16
std::ostream & operator<<(std::ostream &out, ParameterRegion< ParametricType > const &region)
LabParser.cpp.
Definition cli.cpp:18