Exemple #1
0
        private FixedSizeTreePage GetPageForUpdate(LowLevelTransaction lltx, long key, byte depth)
        {
            var buffer = GetBufferForKey(lltx, key, depth);

            if (buffer == null)
            {
                throw new NullReferenceException($"can't find a page for the key:{key.ToString()}");
            }

            var fixedPage = lltx.EnterWrite(buffer).AsFixed();

            if (fixedPage == null)
            {
                throw new NullReferenceException(nameof(fixedPage));
            }

            return(fixedPage);
        }