com.browseengine.bobo.facets.data
Class FacetDataCache<T>

java.lang.Object
  extended by com.browseengine.bobo.facets.data.FacetDataCache<T>
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
MultiValueFacetDataCache

public class FacetDataCache<T>
extends Object
implements Serializable

See Also:
Serialized Form

Nested Class Summary
static class FacetDataCache.FacetDocComparatorSource
           
 
Field Summary
 int[] freqs
           
 int[] maxIDs
           
 int[] minIDs
           
 BigSegmentedArray orderArray
           
 TermValueList<T> valArray
           
 
Constructor Summary
FacetDataCache()
           
FacetDataCache(BigSegmentedArray orderArray, TermValueList<T> valArray, int[] freqs, int[] minIDs, int[] maxIDs, FacetHandler.TermCountSize termCountSize)
           
 
Method Summary
static
<T> int[]
convert(FacetDataCache<T> dataCache, T[] vals)
          Same as convert(FacetDataCache dataCache,String[] vals) except that the values are supplied in raw form so that we can take advantage of the type information to find index faster.
 void load(String fieldName, org.apache.lucene.index.IndexReader reader, TermListFactory<T> listFactory)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

orderArray

public BigSegmentedArray orderArray

valArray

public TermValueList<T> valArray

freqs

public int[] freqs

minIDs

public int[] minIDs

maxIDs

public int[] maxIDs
Constructor Detail

FacetDataCache

public FacetDataCache(BigSegmentedArray orderArray,
                      TermValueList<T> valArray,
                      int[] freqs,
                      int[] minIDs,
                      int[] maxIDs,
                      FacetHandler.TermCountSize termCountSize)

FacetDataCache

public FacetDataCache()
Method Detail

load

public void load(String fieldName,
                 org.apache.lucene.index.IndexReader reader,
                 TermListFactory<T> listFactory)
          throws IOException
Throws:
IOException

convert

public static <T> int[] convert(FacetDataCache<T> dataCache,
                                T[] vals)
Same as convert(FacetDataCache dataCache,String[] vals) except that the values are supplied in raw form so that we can take advantage of the type information to find index faster.

Type Parameters:
T -
Parameters:
dataCache -
vals -
Returns:
the array of order indices of the values.


Copyright © 2011. All Rights Reserved.