public static MDTextFile ReadFile(string fileName, string encoding) { MDTextFile tf = new MDTextFile(); tf.Read(fileName, encoding); return(tf); }
public static string GetFileEncoding(string fileName) { // Maybe this can be optimized later. MDTextFile file = MDTextFile.ReadFile(fileName); return(file.SourceEncoding); }
public static MDTextFile ReadFile(string path, Stream content) { MDTextFile tf = new MDTextFile(); tf.name = path; tf.Read(content, null); return(tf); }