AvalonStudio.TextEditor.Utils.CharRope.InsertText C# (CSharp) Method

InsertText() public static method

Inserts text into this rope. Runs in O(lg N + M).
newElements is null. index or length is outside the valid range.
public static InsertText ( this rope, int index, string text ) : void
rope this
index int
text string
return void
		public static void InsertText(this Rope<char> rope, int index, string text)
		{
			if (rope == null)
				throw new ArgumentNullException("rope");
			rope.InsertRange(index, text.ToCharArray(), 0, text.Length);
			/*if (index < 0 || index > rope.Length) {
				throw new ArgumentOutOfRangeException("index", index, "0 <= index <= " + rope.Length.ToString(CultureInfo.InvariantCulture));
			}
			if (text == null)
				throw new ArgumentNullException("text");
			if (text.Length == 0)
				return;
			rope.root = rope.root.Insert(index, text);
			rope.OnChanged();*/
		}