public string GetLine(int line) { var startIndex = Indices[line]; if (Indices.Count > line + 1) { // Exclude a new line return Code.Substring(startIndex, Indices[line + 1] - 1 - startIndex); } return Code.Substring(startIndex); }
public void GetLine(string code, int lineNumber) { var structuredCode = new StructuredCode(code); structuredCode.GetLine(lineNumber); }