public ISwitchConditionEvaluator GetFor(Expression rep, PatternDialect dialect, TextManager manager)
        {
            if (rep == null)
            {
                return GetFor("", dialect, manager);
            }
            else if (rep.Parts.Count == 1)
            {
                var text = rep.Parts[0] as Text;
                if (text != null)
                {
                    return GetFor(text.Spelling.Trim(), dialect, manager);
                }
            }

            //Unsupported expression
            return null;
        }
        public ISwitchConditionEvaluator GetFor(Expression rep, PatternDialect dialect, TextManager manager)
        {
            if (rep == null)
            {
                return(GetFor("", dialect, manager));
            }
            else if (rep.Parts.Count == 1)
            {
                var text = rep.Parts[0] as Text;
                if (text != null)
                {
                    return(GetFor(text.Spelling.Trim(), dialect, manager));
                }
            }

            //Unsupported expression
            return(null);
        }
Beispiel #3
0
 public IParameterEvaluator GetFor(ParameterSpec spec, PatternDialect pattern, TextManager manager)
 {
     return(_factory(spec, pattern, manager));
 }
 public IParameterEvaluator GetFor(ParameterSpec spec, PatternDialect pattern, TextManager manager)
 {
     return _factory(spec, pattern, manager);
 }
 public abstract ISwitchConditionEvaluator GetFor(string spelling, PatternDialect dialect, TextManager manager);
Beispiel #6
0
 public ISwitchConditionEvaluator GetFor(Expression rep, PatternDialect pattern, TextManager manager)
 {
     return(_factory(rep, pattern, manager));
 }
 public IValueFormatter GetFor(string rep, PatternDialect pattern, TextManager manager)
 {
     return _factory(rep, pattern, manager);
 }
 public ISwitchConditionEvaluator GetFor(Expression rep, PatternDialect pattern, TextManager manager)
 {
     return _factory(rep, pattern, manager);
 }
 public abstract ISwitchConditionEvaluator GetFor(string spelling, PatternDialect dialect, TextManager manager);
 public SwitchDecorator(TextManager manager, PatternDialect dialect)
 {
     _dialect = dialect;
     _manager = manager;
 }
 public IValueFormatter GetFor(string rep, PatternDialect pattern, TextManager manager)
 {
     return(_factory(rep, pattern, manager));
 }
Beispiel #12
0
 public PatternDecorator(TextManager manager, PatternDialect dialect)
 {
     _manager = manager;
     _dialect = dialect;
 }