summaryrefslogtreecommitdiff
path: root/support/nlatexdb/nlatexdb/LatexCharReplace.cs
diff options
context:
space:
mode:
Diffstat (limited to 'support/nlatexdb/nlatexdb/LatexCharReplace.cs')
-rw-r--r--support/nlatexdb/nlatexdb/LatexCharReplace.cs61
1 files changed, 61 insertions, 0 deletions
diff --git a/support/nlatexdb/nlatexdb/LatexCharReplace.cs b/support/nlatexdb/nlatexdb/LatexCharReplace.cs
new file mode 100644
index 0000000000..3554f559b7
--- /dev/null
+++ b/support/nlatexdb/nlatexdb/LatexCharReplace.cs
@@ -0,0 +1,61 @@
+
+using System;
+using System.Configuration;
+
+namespace nlatexdb
+{
+
+ [ConfigurationCollection( typeof( LatexCharReplaceElement ) )]
+ public class LatexCharReplaceCollection : ConfigurationElementCollection
+ {
+ protected override ConfigurationElement CreateNewElement()
+ {
+ return new LatexCharReplaceElement();
+ }
+
+ protected override object GetElementKey( ConfigurationElement element )
+ {
+ return ( (LatexCharReplaceElement)( element ) ).Char;
+ }
+
+ public LatexCharReplaceElement this[int idx ]
+ {
+ get
+ {
+ return (LatexCharReplaceElement) BaseGet(idx);
+ }
+ }
+ }
+
+ public class LatexCharReplaceElement : ConfigurationElement
+ {
+ [ConfigurationProperty("char", DefaultValue="", IsKey=true, IsRequired=true)]
+ public string Char
+ {
+ get
+ {
+ return ((string) (base["char"]));
+ }
+ set
+ {
+ base["char"] = value;
+ }
+ }
+
+ [ConfigurationProperty( "replace", DefaultValue = "", IsKey = false, IsRequired = true )]
+ public string Replace
+ {
+ get
+ {
+ return ( (string)( base[ "replace" ] ) );
+ }
+ set
+ {
+ base[ "replace" ] = value;
+ }
+ }
+
+ }
+
+
+}