Package com.browseengine.bobo.facets.data

Examples of com.browseengine.bobo.facets.data.FacetDataCache


 
 
  public double getFacetSelectivity(BoboIndexReader reader)
  {
    double selectivity = 0;
    FacetDataCache dataCache = _facetHandler.getFacetData(reader);
    int accumFreq=0;
    for(String val : _vals)
    {
      int[] range = FacetRangeFilter.parse(dataCache,val);
      if (range != null)
View Full Code Here


  @Override
  public BoboDocScorer getDocScorer(BoboIndexReader reader,
      FacetTermScoringFunctionFactory scoringFunctionFactory,
      Map<String, Float> boostMap) {
    FacetDataCache dataCache = getFacetData(reader);
    float[] boostList = BoboDocScorer.buildBoostList(dataCache.valArray, boostMap);
    return new RangeBoboDocScorer(dataCache,scoringFunctionFactory,boostList);
 
View Full Code Here

  }
 
  public double getFacetSelectivity(BoboIndexReader reader)
  {
    double selectivity = 0;
    FacetDataCache dataCache = _facetHandler.getFacetData(reader);
    int idx = dataCache.valArray.indexOf(_value);
    if(idx<0)
    {
      return 0.0;
    }
View Full Code Here

  }

  @Override
  public RandomAccessDocIdSet getRandomAccessDocIdSet(BoboIndexReader reader) throws IOException
  {
    FacetDataCache dataCache = _facetHandler.getFacetData(reader);
    int index = dataCache.valArray.indexOf(_value);
    if (index < 0)
    {
      return EmptyDocIdSet.getInstance();
    }
View Full Code Here

  }
  
  public double getFacetSelectivity(BoboIndexReader reader)
  {
    double selectivity = 0;
    FacetDataCache dataCache = _facetHandler.getFacetData(reader);
    int[] range = parse(dataCache,_rangeString);
    if (range != null)
    {
      int accumFreq=0;
      for(int idx=range[0]; idx<=range[1]; ++idx)
View Full Code Here

  }
 
  @Override
  public RandomAccessDocIdSet getRandomAccessDocIdSet(final BoboIndexReader reader) throws IOException
  {     
  final FacetDataCache dataCache = _facetHandler.getFacetData(reader);

    final int[] range = parse(dataCache,_rangeString);
    if (range == null) return null;
   
    if (range[0]>range[1]){
View Full Code Here

      RandomAccessDocIdSet innerDocSet = _facetFilter.getRandomAccessDocIdSet(reader);
      if (innerDocSet==EmptyDocIdSet.getInstance()){
        return innerDocSet;
      }
     
    FacetDataCache dataCache = _facetDataCacheBuilder.build(reader);
    int totalCount = reader.maxDoc();
    TermValueList valArray = dataCache.valArray;
    int freqCount = 0;
   
   
View Full Code Here

    this(name,indexFieldName,null);
  }
 
  @Override
  public int getNumItems(BoboIndexReader reader, int id) {
    FacetDataCache data = getFacetData(reader);
    if (data==null) return 0;
    return data.getNumItems(id);
  }
View Full Code Here

    return new FacetDataCache.FacetDocComparatorSource(this);
  }

  @Override
  public String[] getFieldValues(BoboIndexReader reader,int id) {
    FacetDataCache dataCache = getFacetData(reader);
    if (dataCache!=null){
      return new String[]{dataCache.valArray.get(dataCache.orderArray.get(id))};
    }
    return new String[0];
  }
View Full Code Here

    return new String[0];
  }

  @Override
  public Object[] getRawFieldValues(BoboIndexReader reader,int id){
    FacetDataCache dataCache = getFacetData(reader);
    if (dataCache!=null){
      return new Object[]{dataCache.valArray.getRawValue(dataCache.orderArray.get(id))};
    }
    return new String[0];
  }
View Full Code Here

TOP

Related Classes of com.browseengine.bobo.facets.data.FacetDataCache

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.