Line data Source code
1 : // Author(s): Wieger Wesselink 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 : // 9 : /// \file mcrl2/pbes/detail/pbes_command.h 10 : /// \brief add your file description here. 11 : 12 : #ifndef MCRL2_PBES_DETAIL_PBES_COMMAND_H 13 : #define MCRL2_PBES_DETAIL_PBES_COMMAND_H 14 : 15 : #include "mcrl2/data/rewriter.h" 16 : #include "mcrl2/pbes/parse.h" 17 : #include "mcrl2/pbes/detail/pbes_io.h" 18 : #include "mcrl2/utilities/detail/command.h" 19 : 20 : namespace mcrl2 { 21 : 22 : namespace pbes_system { 23 : 24 : namespace detail { 25 : 26 : /// \brief Command that operates on a PBES 27 : struct pbes_command: public utilities::detail::command 28 : { 29 : pbes_system::pbes pbesspec; 30 : 31 0 : pbes_command(const std::string& name, 32 : const std::string& input_filename, 33 : const std::string& output_filename, 34 : const std::vector<std::string>& options 35 : ) 36 0 : : utilities::detail::command(name, input_filename, output_filename, options) 37 0 : {} 38 : 39 0 : void execute() override 40 : { 41 0 : pbesspec = pbes_system::detail::load_pbes(input_filename); 42 0 : } 43 : }; 44 : 45 : /// \brief PBES command that uses a rewrite strategy 46 : struct pbes_rewriter_command: public pbes_command 47 : { 48 : data::rewrite_strategy strategy; 49 : 50 0 : pbes_rewriter_command(const std::string& name, 51 : const std::string& input_filename, 52 : const std::string& output_filename, 53 : const std::vector<std::string>& options, 54 : data::rewrite_strategy strategy_ 55 : ) 56 0 : : pbes_command(name, input_filename, output_filename, options), 57 0 : strategy(strategy_) 58 0 : {} 59 : }; 60 : 61 : } // namespace detail 62 : 63 : } // namespace pbes_system 64 : 65 : } // namespace mcrl2 66 : 67 : #endif // MCRL2_PBES_DETAIL_PBES_COMMAND_H