Exemplo n.º 1
0
        public static string[] ReadAllLines(string path, Encoding encoding, out string newLine)
        {
            String    line;
            ArrayList lines = new ArrayList();

            using (LineStreamReader sr = new LineStreamReader(path, encoding)) {
                while ((line = sr.ReadLine()) != null)
                {
                    lines.Add(line);
                }

                newLine = sr.LineType;
            }

            return((String[])lines.ToArray(typeof(String)));
        }
Exemplo n.º 2
0
 protected LineStream(string path, char separator)
 {
     _separator = separator;
     _allLines  = LineStreamReader.ReadAllLines(path, EncodingService.DisplayEncoding, out _newLine).ToList();
     Init();
 }
Exemplo n.º 3
0
		public static string[] ReadAllLines(string path, Encoding encoding, out string newLine) {
			String line;
			ArrayList lines = new ArrayList();

			using (LineStreamReader sr = new LineStreamReader(path, encoding)) {
				while ((line = sr.ReadLine()) != null)
					lines.Add(line);

				newLine = sr.LineType;
			}

			return (String[])lines.ToArray(typeof(String));
		}