lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nightowl...@apache.org
Subject [34/50] [abbrv] lucenenet git commit: Lucene.Net.Facet.Taxonomy.Directory.DirectoryTaxonomyReader: changed CacheSize (setter only) > SetCacheSize(). Lucene.Net.Facet.Taxonomy.Directory.DirectoryTaxonomyWriter: changed CacheMissesUntilFill (setter only) >
Date Tue, 31 Jan 2017 17:56:07 GMT
Lucene.Net.Facet.Taxonomy.Directory.DirectoryTaxonomyReader: changed CacheSize (setter only)
> SetCacheSize(). Lucene.Net.Facet.Taxonomy.Directory.DirectoryTaxonomyWriter: changed
CacheMissesUntilFill (setter only) > SetCacheMissesUntilFill()


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

Branch: refs/heads/api-work
Commit: c68378fd64d8c31e4b84b9fdc713bc0e3e02b133
Parents: fc2eef3
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Tue Jan 31 16:30:51 2017 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Tue Jan 31 16:30:51 2017 +0700

----------------------------------------------------------------------
 .../Directory/DirectoryTaxonomyReader.cs        | 21 +++++++++-----------
 .../Directory/DirectoryTaxonomyWriter.cs        |  9 +++------
 2 files changed, 12 insertions(+), 18 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/c68378fd/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyReader.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyReader.cs b/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyReader.cs
index 88193e2..ee2eacd 100644
--- a/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyReader.cs
+++ b/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyReader.cs
@@ -376,26 +376,23 @@ namespace Lucene.Net.Facet.Taxonomy.Directory
         }
 
         /// <summary>
-        /// Setting <see cref="CacheSize"/> controls the maximum allowed size of each
of the caches
+        /// <see cref="SetCacheSize"/> controls the maximum allowed size of each of
the caches
         /// used by <see cref="GetPath(int)"/> and <see cref="GetOrdinal(FacetLabel)"/>.
         /// <P>
         /// Currently, if the given size is smaller than the current size of
         /// a cache, it will not shrink, and rather we be limited to its current
         /// size. </summary>
         /// <param name="value"> the new maximum cache size, in number of entries.
</param>
-        public virtual int CacheSize
+        public virtual void SetCacheSize(int size)
         {
-            set
+            EnsureOpen();
+            lock (categoryCache)
             {
-                EnsureOpen();
-                lock (categoryCache)
-                {
-                    categoryCache.Limit = value;
-                }
-                lock (ordinalCache)
-                {
-                    ordinalCache.Limit = value;
-                }
+                categoryCache.Limit = size;
+            }
+            lock (ordinalCache)
+            {
+                ordinalCache.Limit = size;
             }
         }
 

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/c68378fd/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyWriter.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyWriter.cs b/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyWriter.cs
index 94b323e..1c8e21d 100644
--- a/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyWriter.cs
+++ b/src/Lucene.Net.Facet/Taxonomy/Directory/DirectoryTaxonomyWriter.cs
@@ -757,13 +757,10 @@ namespace Lucene.Net.Facet.Taxonomy.Directory
         /// taxonomy writer has been created.
         /// </para>
         /// </summary>
-        public virtual int CacheMissesUntilFill
+        public virtual void SetCacheMissesUntilFill(int i)
         {
-            set
-            {
-                EnsureOpen();
-                cacheMissesUntilFill = value;
-            }
+            EnsureOpen();
+            cacheMissesUntilFill = i;
         }
 
         // we need to guarantee that if several threads call this concurrently, only


Mime
View raw message