Exemple #1
0
            public CommitPoint(IndexFileDeleter enclosingInstance, ICollection <CommitPoint> commitsToDelete, Directory directory, SegmentInfos segmentInfos)
            {
                InitBlock(enclosingInstance);
                this.directory       = directory;
                this.commitsToDelete = commitsToDelete;
                userData             = segmentInfos.UserData;
                segmentsFileName     = segmentInfos.GetCurrentSegmentFileName();
                version     = segmentInfos.Version;
                generation  = segmentInfos.Generation;
                files       = segmentInfos.Files(directory, true);
                gen         = segmentInfos.Generation;
                isOptimized = segmentInfos.Count == 1 && !segmentInfos.Info(0).HasDeletions();

                System.Diagnostics.Debug.Assert(!segmentInfos.HasExternalSegments(directory));
            }
Exemple #2
0
 private void InitBlock(IndexFileDeleter enclosingInstance)
 {
     this.enclosingInstance = enclosingInstance;
 }