/// <summary> /// Append the specified count of characters from the given buffer at the given start index. /// </summary> /// <param name="nameof(value)">The buffer to append.</param> /// <param name="nameof(startIndex)">The index in the input buffer to start appending from.</param> /// <param name="nameof(count)">The count of characters to copy from the buffer.</param> /// <exception cref="ArgumentNullException">Thrown if <paramref name="nameof(value)"/> is null.</exception> /// <exception cref="ArgumentOutOfRangeException"> /// Thrown if <paramref name="startIndex"/> or <paramref name="nameof(count)"/> are outside the range /// of <paramref name="value"/> characters. /// </exception> public unsafe void Append(StringBuffer value, ulong startIndex, ulong count) { if (count == 0) { return; } if (value == null) { throw new ArgumentNullException(nameof(value)); } value.CopyTo( bufferIndex: startIndex, destination: this, destinationIndex: this.Length, count: count); }
/// <summary> /// Append the specified count of characters from the given buffer at the given start index. /// </summary> /// <param name="nameof(value)">The buffer to append.</param> /// <param name="nameof(startIndex)">The index in the input buffer to start appending from.</param> /// <param name="nameof(count)">The count of characters to copy from the buffer.</param> /// <exception cref="ArgumentNullException">Thrown if <paramref name="nameof(value)"/> is null.</exception> /// <exception cref="ArgumentOutOfRangeException"> /// Thrown if <paramref name="startIndex"/> or <paramref name="nameof(count)"/> are outside the range /// of <paramref name="value"/> characters. /// </exception> public unsafe void Append(StringBuffer value, ulong startIndex, ulong count) { if (count == 0) return; if (value == null) throw new ArgumentNullException(nameof(value)); value.CopyTo( bufferIndex: startIndex, destination: this, destinationIndex: this.Length, count: count); }