lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nightowl...@apache.org
Subject [04/38] lucenenet git commit: API: Lucene.Net.Index.SegmentInfos: Renamed Files() > GetFiles() (consistency)
Date Thu, 22 Jun 2017 05:25:05 GMT
API: Lucene.Net.Index.SegmentInfos: Renamed Files() > GetFiles() (consistency)


Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/169598cd
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/169598cd
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/169598cd

Branch: refs/heads/master
Commit: 169598cd7ed9337247e202a43d0cdc5711fa129d
Parents: 2109722
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Sat Jun 17 12:58:08 2017 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Sat Jun 17 12:58:08 2017 +0700

----------------------------------------------------------------------
 src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs | 2 +-
 src/Lucene.Net/Index/IndexFileDeleter.cs                   | 8 ++++----
 src/Lucene.Net/Index/IndexWriter.cs                        | 8 ++++----
 src/Lucene.Net/Index/SegmentInfos.cs                       | 2 +-
 src/Lucene.Net/Index/StandardDirectoryReader.cs            | 2 +-
 5 files changed, 11 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/169598cd/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs b/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs
index cfcce58..c87714a 100644
--- a/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs
+++ b/src/Lucene.Net.TestFramework/Store/MockDirectoryWrapper.cs
@@ -1008,7 +1008,7 @@ namespace Lucene.Net.Store
 
                                         try
                                         {
-                                            ISet<string> ghosts = new HashSet<string>(sis.Files(m_input,
false));
+                                            ISet<string> ghosts = new HashSet<string>(sis.GetFiles(m_input,
false));
                                             foreach (string s in ghosts)
                                             {
                                                 if (endSet.Contains(s) && !startSet.Contains(s))

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/169598cd/src/Lucene.Net/Index/IndexFileDeleter.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net/Index/IndexFileDeleter.cs b/src/Lucene.Net/Index/IndexFileDeleter.cs
index fd1d414..76c3d9a 100644
--- a/src/Lucene.Net/Index/IndexFileDeleter.cs
+++ b/src/Lucene.Net/Index/IndexFileDeleter.cs
@@ -577,7 +577,7 @@ namespace Lucene.Net.Index
                 lastFiles.Clear();
 
                 // Save files so we can decr on next checkpoint/commit:
-                lastFiles.AddRange(segmentInfos.Files(directory, false));
+                lastFiles.AddRange(segmentInfos.GetFiles(directory, false));
             }
             if (infoStream.IsEnabled("IFD"))
             {
@@ -591,7 +591,7 @@ namespace Lucene.Net.Index
             Debug.Assert(IsLocked);
             // If this is a commit point, also incRef the
             // segments_N file:
-            foreach (string fileName in segmentInfos.Files(directory, isCommit))
+            foreach (string fileName in segmentInfos.GetFiles(directory, isCommit))
             {
                 IncRef(fileName);
             }
@@ -652,7 +652,7 @@ namespace Lucene.Net.Index
         internal void DecRef(SegmentInfos segmentInfos)
         {
             Debug.Assert(IsLocked);
-            foreach (string file in segmentInfos.Files(directory, false))
+            foreach (string file in segmentInfos.GetFiles(directory, false))
             {
                 DecRef(file);
             }
@@ -825,7 +825,7 @@ namespace Lucene.Net.Index
                 userData = segmentInfos.UserData;
                 segmentsFileName = segmentInfos.GetSegmentsFileName();
                 generation = segmentInfos.Generation;
-                files = segmentInfos.Files(directory, true);
+                files = segmentInfos.GetFiles(directory, true);
                 segmentCount = segmentInfos.Count;
             }
 

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/169598cd/src/Lucene.Net/Index/IndexWriter.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net/Index/IndexWriter.cs b/src/Lucene.Net/Index/IndexWriter.cs
index 0f7d3dc..5ad4af8 100644
--- a/src/Lucene.Net/Index/IndexWriter.cs
+++ b/src/Lucene.Net/Index/IndexWriter.cs
@@ -1975,7 +1975,7 @@ namespace Lucene.Net.Index
             {
                 lock (this)
                 {
-                    return segmentInfos.Files(directory, true);
+                    return segmentInfos.GetFiles(directory, true);
                 }
             }
         }
@@ -3599,7 +3599,7 @@ namespace Lucene.Net.Index
                                 // we are trying to sync all referenced files, a
                                 // merge completes which would otherwise have
                                 // removed the files we are now syncing.
-                                filesToCommit = toCommit.Files(directory, false);
+                                filesToCommit = toCommit.GetFiles(directory, false);
                                 deleter.IncRef(filesToCommit);
                             }
                             success = true;
@@ -5409,7 +5409,7 @@ namespace Lucene.Net.Index
         // called only from assert
         private bool FilesExist(SegmentInfos toSync)
         {
-            ICollection<string> files = toSync.Files(directory, false);
+            ICollection<string> files = toSync.GetFiles(directory, false);
             foreach (string fileName in files)
             {
                 Debug.Assert(SlowFileExists(directory, fileName), "file " + fileName + "
does not exist; files=" + Arrays.ToString(directory.ListAll()));
@@ -5529,7 +5529,7 @@ namespace Lucene.Net.Index
                     ICollection<string> filesToSync;
                     try
                     {
-                        filesToSync = toSync.Files(directory, false);
+                        filesToSync = toSync.GetFiles(directory, false);
                         directory.Sync(filesToSync);
                         success = true;
                     }

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/169598cd/src/Lucene.Net/Index/SegmentInfos.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net/Index/SegmentInfos.cs b/src/Lucene.Net/Index/SegmentInfos.cs
index 51f866a..f330d11 100644
--- a/src/Lucene.Net/Index/SegmentInfos.cs
+++ b/src/Lucene.Net/Index/SegmentInfos.cs
@@ -1157,7 +1157,7 @@ namespace Lucene.Net.Index
         /// The returned collection is recomputed on each
         /// invocation.
         /// </summary>
-        public ICollection<string> Files(Directory dir, bool includeSegmentsFile) //
LUCENENET TODO: API Rename GetFiles()
+        public ICollection<string> GetFiles(Directory dir, bool includeSegmentsFile)
         {
             var files = new HashSet<string>();
             if (includeSegmentsFile)

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/169598cd/src/Lucene.Net/Index/StandardDirectoryReader.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net/Index/StandardDirectoryReader.cs b/src/Lucene.Net/Index/StandardDirectoryReader.cs
index 303d2ca..2484c68 100644
--- a/src/Lucene.Net/Index/StandardDirectoryReader.cs
+++ b/src/Lucene.Net/Index/StandardDirectoryReader.cs
@@ -525,7 +525,7 @@ namespace Lucene.Net.Index
                 segmentsFileName = infos.GetSegmentsFileName();
                 this.dir = dir;
                 userData = infos.UserData;
-                files = infos.Files(dir, true);
+                files = infos.GetFiles(dir, true);
                 generation = infos.Generation;
                 segmentCount = infos.Count;
             }


Mime
View raw message