diff --git a/adeterminize/src/common/Utils.h b/adeterminize/src/common/Utils.h index 534e02e50bad4a406b7cd0f423e33a65a7d3f27d..bcfe020a3efedf06fca279fa845923d72689f070 100644 --- a/adeterminize/src/common/Utils.h +++ b/adeterminize/src/common/Utils.h @@ -13,12 +13,39 @@ using namespace automaton; namespace determinization { +/** + * Library class with some basic methods that can be used by determinization algorithms. + */ class Utils { + public: + + /** + * Copies input alphabet of source automaton into given dest automaton. + * + * @param source automaton to copy input alphabet from + * @param dest automaton to copy input alphabet into + */ static void copyInputAlphabet(const Automaton& source, Automaton& dest); + + /** + * Returns if given set of states contains at least one final state of given automaton. + * + * @param states set of states from given automaton + * @param automaton + * @return true, if given set of states contains final state, or false, if not + */ static bool containFinalState(const set<State>& states, const Automaton& automaton); + + /** + * Copies stack alphabet of source pda into given dest pda. + * + * @param source pushdown automaton to copy stack alphabet from + * @param dest pushdown automaton to copy stack alphabet into + */ static void copyStackAlphabet(const PDA& source, PDA& dest); + }; }