mCRL2
Loading...
Searching...
No Matches
basic_sort.h
Go to the documentation of this file.
1// Author(s): Jeroen Keiren
2// Copyright: see the accompanying file COPYING or copy at
3// https://github.com/mCRL2org/mCRL2/blob/master/COPYING
4//
5// Distributed under the Boost Software License, Version 1.0.
6// (See accompanying file LICENSE_1_0.txt or copy at
7// http://www.boost.org/LICENSE_1_0.txt)
8//
11
12#ifndef MCRL2_DATA_BASIC_SORT_H
13#define MCRL2_DATA_BASIC_SORT_H
14
16
17namespace mcrl2
18{
19
20namespace data
21{
22
23//--- start generated class basic_sort ---//
26{
27 public:
30 : sort_expression(core::detail::default_values::SortId)
31 {}
32
35 explicit basic_sort(const atermpp::aterm& term)
36 : sort_expression(term)
37 {
39 }
40
43 : sort_expression(atermpp::aterm(core::detail::function_symbol_SortId(), name))
44 {}
45
47 basic_sort(const std::string& name)
48 : sort_expression(atermpp::aterm(core::detail::function_symbol_SortId(), core::identifier_string(name)))
49 {}
50
52 basic_sort(const basic_sort&) noexcept = default;
53 basic_sort(basic_sort&&) noexcept = default;
54 basic_sort& operator=(const basic_sort&) noexcept = default;
55 basic_sort& operator=(basic_sort&&) noexcept = default;
56
57 const core::identifier_string& name() const
58 {
59 return atermpp::down_cast<core::identifier_string>((*this)[0]);
60 }
61};
62
65template <class... ARGUMENTS>
66inline void make_basic_sort(atermpp::aterm& t, const ARGUMENTS&... args)
67{
69}
70
71// prototype declaration
72std::string pp(const basic_sort& x);
73
78inline
79std::ostream& operator<<(std::ostream& out, const basic_sort& x)
80{
81 return out << data::pp(x);
82}
83
85inline void swap(basic_sort& t1, basic_sort& t2)
86{
87 t1.swap(t2);
88}
89//--- end generated class basic_sort ---//
90
94typedef std::vector<basic_sort> basic_sort_vector;
95
96} // namespace data
97
98} // namespace mcrl2
99
100#endif // MCRL2_DATA_BASIC_SORT_H
101
Term containing a string.
aterm()
Default constructor.
Definition aterm.h:48
A list of aterm objects.
Definition aterm_list.h:24
void swap(unprotected_aterm_core &t) noexcept
Swaps this term with its argument.
Definition aterm_core.h:152
\brief A basic sort
Definition basic_sort.h:26
basic_sort(const basic_sort &) noexcept=default
Move semantics.
basic_sort()
\brief Default constructor X3.
Definition basic_sort.h:29
const core::identifier_string & name() const
Definition basic_sort.h:57
basic_sort(basic_sort &&) noexcept=default
basic_sort(const core::identifier_string &name)
\brief Constructor Z14.
Definition basic_sort.h:42
basic_sort(const std::string &name)
\brief Constructor Z2.
Definition basic_sort.h:47
basic_sort(const atermpp::aterm &term)
Definition basic_sort.h:35
\brief A sort expression
The main namespace for the aterm++ library.
Definition algorithm.h:21
void make_term_appl(Term &target, const function_symbol &sym, ForwardIterator begin, ForwardIterator end)
Constructor an aterm in a variable based on a function symbol and an forward iterator providing the a...
Definition aterm.h:213
bool check_term_SortId(const Term &t)
const atermpp::function_symbol & function_symbol_SortId()
void swap(abstraction &t1, abstraction &t2)
\brief swap overload
void make_basic_sort(atermpp::aterm &t, const ARGUMENTS &... args)
Definition basic_sort.h:66
std::string pp(const abstraction &x)
Definition data.cpp:39
atermpp::term_list< basic_sort > basic_sort_list
list of basic sorts
Definition basic_sort.h:92
std::vector< basic_sort > basic_sort_vector
vector of basic sorts
Definition basic_sort.h:94
std::ostream & operator<<(std::ostream &out, const abstraction &x)
Definition abstraction.h:94
A class that takes a linear process specification and checks all tau-summands of that LPS for conflue...
Definition indexed_set.h:72
The class sort_expression.