/// <summary> /// The get lines from source. /// </summary> /// <param name="sourceSource"> /// The source source. /// </param> /// <param name="sep"> /// The sep. /// </param> /// <returns> /// The System.String. /// </returns> public static string GetLinesFromSource(Source sourceSource, string sep) { return sourceSource.Lines.Aggregate(string.Empty, (current, line) => current + (line + sep)); }
/// <summary> /// The get lines from source. /// </summary> /// <param name="sourceSource"> /// The source source. /// </param> /// <param name="lineSep"> /// The line sep. /// </param> /// <param name="startLine"> /// The start line. /// </param> /// <param name="lenght"> /// The lenght. /// </param> /// <returns> /// The <see cref="string"/>. /// </returns> public static string GetLinesFromSource(Source sourceSource, string lineSep, int startLine, int lenght) { string data = string.Empty; for (int i = startLine; i < startLine + lenght; i++) { data += sourceSource.Lines[i] + lineSep; } return data; }