Example #1
0
        public static PropositionalConnective GetInstance(char symbol)
        {
            if (Negation.IsThis(symbol))
            {
                return(Negation.GetInstance());
            }

            if (Disjunction.IsThis(symbol))
            {
                return(Disjunction.GetInstance());
            }

            if (Conjunction.IsThis(symbol))
            {
                return(Conjunction.GetInstance());
            }

            if (Implication.IsThis(symbol))
            {
                return(Implication.GetInstance());
            }

            throw new ArgumentException();
        }
Example #2
0
 public static bool IsThis(char symbol)
 {
     return(Negation.IsThis(symbol) || Disjunction.IsThis(symbol) || Conjunction.IsThis(symbol) ||
            Implication.IsThis(symbol));
 }