Exemple #1
0
        public static MDTextFile ReadFile(string fileName, string encoding)
        {
            MDTextFile tf = new MDTextFile();

            tf.Read(fileName, encoding);
            return(tf);
        }
Exemple #2
0
        public static string GetFileEncoding(string fileName)
        {
            // Maybe this can be optimized later.
            MDTextFile file = MDTextFile.ReadFile(fileName);

            return(file.SourceEncoding);
        }
Exemple #3
0
        public static MDTextFile ReadFile(string path, Stream content)
        {
            MDTextFile tf = new MDTextFile();

            tf.name = path;
            tf.Read(content, null);
            return(tf);
        }