Microsoft.Cci.CompositeSourceDocument.GetText C# (CSharp) Method

GetText() public method

Returns the source text of the document in string form. This call is expensive in time and space. Rather use CopyTo if at all possible.
public GetText ( ) : string
return string
    public override string GetText()
      //^^ ensures result.Length == this.Length;
    {
      StringBuilder sb = new StringBuilder();
      foreach (ISourceLocation fragment in this.GetFragments())
        sb.Append(fragment.Source);
      this.length = sb.Length;
      string result = sb.ToString();
      //^ assume result.Length == this.Length;
      return result;
    }