Package dovetaildb.dbservice

Examples of dovetaildb.dbservice.BagEntry


    mapper.addRevsForTxn(0, new HashMap<String,Long>());
    b.setBagIndexFactory(new BagEntryFactory() {
      public BagEntry makeBagEntry(String bagName) {
        MemoryBlueSteelBagIndex bagIndex = new MemoryBlueSteelBagIndex();
        mapper.introduceBag(bagName, bagIndex);
        return new BagEntry(bagIndex);
      }
    });
    b.setTxnMapper(mapper);
    return new ScoringDbService(b);
  }
View Full Code Here


                PrefixCompressedBagIndex pcBagIndex = new PrefixCompressedBagIndex(bsBagIndex, table);
                bagIndex = pcBagIndex;
                bsBagIndex.setTermTableDepth(pcBagIndex.getNumCompressedBytes());
              }
            }
            return new BagEntry(bagIndex);
          }
        });
        FsTransactionMapper mapper = new FsTransactionMapper(subDbServiceHome, sync);
        b.setTxnMapper(mapper);
        // when creating a new BagIndexBridge, issue an empty commit to get a valid initial txn entry
View Full Code Here

    }
    TrivialBagIndex puts = new TrivialBagIndex();
    long revNum = puts.commitNewRev(buffer);
    BagIndexBridge bridge = new BagIndexBridge();
    bridge.setTxnMapper(new ProcessTransactionMapper());
    bridge.setBagEntry("",new BagEntry(puts, null, revNum));
    bridge.getTxnMapper().addRevsForTxn(0, Util.literalMap().p("",revNum));
    return bridge.query("", 0, query, options);
  }
View Full Code Here

  protected DbService createDbService() {
    BagIndexBridge b = new BagIndexBridge();
    b.setBagIndexFactory(new BagEntryFactory() {
      public BagEntry makeBagEntry(String bagName) {
        return new BagEntry(new TrivialBagIndex(), new DefaultTermEncoder(), 0);
      }
    });
    b.setTxnMapper(new ProcessTransactionMapper());
    return b;
  }
View Full Code Here

    }
    TrivialBagIndex puts = new TrivialBagIndex();
    long revNum = puts.commitNewRev(buffer);
    BagIndexBridge bridge = new BagIndexBridge();
    bridge.setTxnMapper(new ProcessTransactionMapper());
    bridge.setBagEntry("",new BagEntry(puts));
    HashMap<String,Long> revs = new HashMap<String,Long>();
    revs.put("", revNum);
    bridge.getTxnMapper().addRevsForTxn(0, revs);
    return bridge.query("", 0, query, options);
  }
View Full Code Here

    mapper.addRevsForTxn(0, new HashMap<String,Long>());
    b.setBagIndexFactory(new BagEntryFactory() {
      public BagEntry makeBagEntry(String bagName) {
        TrivialBagIndex bagIndex = new TrivialBagIndex();
        mapper.introduceBag(bagName, bagIndex);
        return new BagEntry(bagIndex);
      }
    });
    b.setTxnMapper(mapper);
    return b;
  }
View Full Code Here

TOP

Related Classes of dovetaildb.dbservice.BagEntry

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.