Esempio n. 1
0
        public T this[int index]
        {
            get
            {
                if (index < 0)
                {
                    throw new ArgumentOutOfRangeException();
                }
                var linkedRowPtr = _listHandle.Get((IntPtr)index);
                return((T)_realm.MakeObjectForRow(_targetMetadata, linkedRowPtr));
            }

            set
            {
                throw new NotImplementedException();
            }
        }
Esempio n. 2
0
        public T this[int index]
        {
            get
            {
                if (index < 0)
                {
                    throw new ArgumentOutOfRangeException();
                }

                var linkedObjectPtr = _listHandle.Get((IntPtr)index, _realm.SharedRealmHandle);
                return((T)_realm.MakeObject(_targetMetadata, linkedObjectPtr));
            }

            set
            {
                throw new NotSupportedException("Setting items directly is not supported.");
            }
        }