public MessagePackByteArrayPacker(byte[] buffer, int startOffset, ByteBufferAllocator allocator, PackerCompatibilityOptions compatibilityOptions) : base(compatibilityOptions) { this._buffer = buffer ?? Binary.Empty; if (startOffset < 0) { throw new ArgumentOutOfRangeException("startOffset"); } if (startOffset > this._buffer.Length) { throw new ArgumentException("The startOffset is too large or the length of buffer is too small."); } this._initialOffset = startOffset; this._offset = startOffset; this._allocator = allocator; }
public MessagePackByteArrayPacker(byte[] buffer, ByteBufferAllocator allocator, PackerCompatibilityOptions compatibilityOptions) : this(buffer, 0, allocator, compatibilityOptions) { }