00001 using System.Configuration; 00002 00003 namespace N2.Configuration 00004 { 00008 [ConfigurationCollection(typeof(PatternValueElement))] 00009 public class PatternValueCollection : ConfigurationElementCollection 00010 { 00011 public PatternValueCollection() 00012 { 00013 BaseAdd(new PatternValueElement("smallA", "[åáàâã@]", "a", true)); 00014 BaseAdd(new PatternValueElement("capitalA", "[ÅÁÀÂÃ]", "a", true)); 00015 BaseAdd(new PatternValueElement("smallAE", "[æä]", "ae", true)); 00016 BaseAdd(new PatternValueElement("capitalAE", "[ÆÄ]", "Ae", true)); 00017 BaseAdd(new PatternValueElement("smallE", "[éè]", "e", true)); 00018 BaseAdd(new PatternValueElement("capitalE", "[ÉÈ]", "E", true)); 00019 BaseAdd(new PatternValueElement("smallI", "[íì]", "i", true)); 00020 BaseAdd(new PatternValueElement("capitalI", "[ÍÌ]", "I", true)); 00021 BaseAdd(new PatternValueElement("smallO", "[øóòôõ]", "o", true)); 00022 BaseAdd(new PatternValueElement("capitalO", "[ØÓÒÔÕ]", "O", true)); 00023 BaseAdd(new PatternValueElement("smallOE", "[ö]", "oe", true)); 00024 BaseAdd(new PatternValueElement("capitalOE", "[Ö]", "Oe", true)); 00025 BaseAdd(new PatternValueElement("smallU", "[úù]", "u", true)); 00026 BaseAdd(new PatternValueElement("capitalU", "[ÚÙ]", "U", true)); 00027 BaseAdd(new PatternValueElement("smallUE", "[ü]", "ue", true)); 00028 BaseAdd(new PatternValueElement("capitalUE", "[Ü]", "Ue", true)); 00029 BaseAdd(new PatternValueElement("germanSZ", "[ß]", "ss", true)); 00030 BaseAdd(new PatternValueElement("theRest", "[^. a-zA-Z0-9_-]", "", true)); 00031 } 00032 00033 protected override ConfigurationElement CreateNewElement() 00034 { 00035 return new PatternValueElement(); 00036 } 00037 00038 protected override object GetElementKey(ConfigurationElement element) 00039 { 00040 return ((PatternValueElement) element).Name; 00041 } 00042 } 00043 }