12#ifndef MCRL2_CORE_LOAD_ATERM_H
13#define MCRL2_CORE_LOAD_ATERM_H
27 if (filename.empty() || filename ==
"-")
29 return "standard input";
46 const std::string& format =
"aterm",
47 const std::string& source =
"",
62 catch (std::exception &e)
66 throw mcrl2::runtime_error(
"Failed to read a valid " + format +
" from the input.\n" + e.what());
70 throw mcrl2::runtime_error(
"Failed to read a valid " + format +
" from the input " + source +
".\n" + e.what());
Reads terms from a stream in the steamable binary aterm format.
Reads terms in textual format from an input stream.
Standard exception class for reporting runtime errors.
aterm identity(const aterm &x)
The default transformer that maps each term to itself.
aterm(const aterm &) aterm_transformer
A function that is applied to all terms. The resulting term should only use a subset of the original ...
std::string file_source(const std::string &filename)
atermpp::aterm load_aterm(std::istream &stream, bool binary=true, const std::string &format="aterm", const std::string &source="", atermpp::aterm_transformer transformer=atermpp::identity)
Attempts to read an aterm from a stream.
A class that takes a linear process specification and checks all tau-summands of that LPS for conflue...