java: public BeiderMorseFilterFactory(Map<String,String> args) {super(args);NameType nameType = NameType.valueOf(get(args, "nameType", NameType.GENERIC.toString()));RuleType ruleType = RuleType.valueOf(get(args, "ruleType", RuleType.APPROX.toString()));boolean concat = getBoolean(args, "concat", true);engine = new PhoneticEngine(nameType, ruleType, concat);Set<String> langs = getSet(args, "languageSet");languageSet = (null == langs || (1 == langs.size() && langs.contains("auto"))) ? null : LanguageSet.from(langs);if (!args.isEmpty()) {throw new IllegalArgumentException("Unknown parameters: " + args);}}
C#: public BeiderMorseFilterFactory(IDictionary<string, string> args): base(args){NameType nameType = (NameType)Enum.Parse(typeof(NameType), Get(args, "nameType", NameType.GENERIC.ToString()), true);RuleType ruleType = (RuleType)Enum.Parse(typeof(RuleType), Get(args, "ruleType", RuleType.APPROX.ToString()), true);bool concat = GetBoolean(args, "concat", true);engine = new PhoneticEngine(nameType, ruleType, concat);ISet<string> langs = GetSet(args, "languageSet");languageSet = (null == langs || (1 == langs.Count && langs.Contains("auto"))) ? null : LanguageSet.From(langs);if (!(args.Count == 0)){throw new ArgumentException("Unknown parameters: " + args);}}