Example #1
0
        public unsafe TManaged this[int index]
        {
            get
            {
                if (index < 0 || index >= Count)
                {
                    throw new ArgumentOutOfRangeException(nameof(index), "Index out of range");
                }

                sbyte *pData = Handle.elts;

                return(_marshaller.Read(new IntPtr(pData + _marshaller.ItemSize * index), _pool));
            }
        }