Examples of Pulsing41PostingsFormat


Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

  public void testSameCodecDifferentInstance() throws Exception {
    Codec codec = new Lucene46Codec() {
      @Override
      public PostingsFormat getPostingsFormatForField(String field) {
        if ("id".equals(field)) {
          return new Pulsing41PostingsFormat(1);
        } else if ("date".equals(field)) {
          return new Pulsing41PostingsFormat(1);
        } else {
          return super.getPostingsFormatForField(field);
        }
      }
    };
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

  public void testSameCodecDifferentParams() throws Exception {
    Codec codec = new Lucene46Codec() {
      @Override
      public PostingsFormat getPostingsFormatForField(String field) {
        if ("id".equals(field)) {
          return new Pulsing41PostingsFormat(1);
        } else if ("date".equals(field)) {
          return new Pulsing41PostingsFormat(2);
        } else {
          return super.getPostingsFormatForField(field);
        }
      }
    };
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

    add(avoidCodecs,
        new Lucene41PostingsFormat(minItemsPerBlock, maxItemsPerBlock),
        new DirectPostingsFormat(LuceneTestCase.rarely(random) ? 1 : (LuceneTestCase.rarely(random) ? Integer.MAX_VALUE : maxItemsPerBlock),
                                 LuceneTestCase.rarely(random) ? 1 : (LuceneTestCase.rarely(random) ? Integer.MAX_VALUE : lowFreqCutoff)),
        new Pulsing41PostingsFormat(1 + random.nextInt(20), minItemsPerBlock, maxItemsPerBlock),
        // add pulsing again with (usually) different parameters
        new Pulsing41PostingsFormat(1 + random.nextInt(20), minItemsPerBlock, maxItemsPerBlock),
        //TODO as a PostingsFormat which wraps others, we should allow TestBloomFilteredLucene41Postings to be constructed
        //with a choice of concrete PostingsFormats. Maybe useful to have a generic means of marking and dealing
        //with such "wrapper" classes?
        new TestBloomFilteredLucene41Postings(),               
        new MockSepPostingsFormat(),
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

    {
      Directory dir = newDirectory();
      IndexWriterConfig conf = newIndexWriterConfig(TEST_VERSION_CURRENT,
          new MockAnalyzer(random()));
      conf.setCodec(_TestUtil.alwaysPostingsFormat(new Pulsing41PostingsFormat(1 + random().nextInt(20))));
      IndexWriter w = new IndexWriter(dir, conf);
      try {
        w.addIndexes(toAdd);
        fail("no such codec");
      } catch (IllegalArgumentException ex) {
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

    {
      Directory dir = newDirectory();
      IndexWriterConfig conf = newIndexWriterConfig(TEST_VERSION_CURRENT,
          new MockAnalyzer(random()));
      conf.setCodec(_TestUtil.alwaysPostingsFormat(new Pulsing41PostingsFormat(1 + random().nextInt(20))));
      IndexWriter w = new IndexWriter(dir, conf);
      try {
        w.addIndexes(toAdd);
        fail("no such codec");
      } catch (IllegalArgumentException ex) {
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

        new FSTOrdPostingsFormat(),
        new FSTPulsing41PostingsFormat(1 + random.nextInt(20)),
        new FSTOrdPulsing41PostingsFormat(1 + random.nextInt(20)),
        new DirectPostingsFormat(LuceneTestCase.rarely(random) ? 1 : (LuceneTestCase.rarely(random) ? Integer.MAX_VALUE : maxItemsPerBlock),
                                 LuceneTestCase.rarely(random) ? 1 : (LuceneTestCase.rarely(random) ? Integer.MAX_VALUE : lowFreqCutoff)),
        new Pulsing41PostingsFormat(1 + random.nextInt(20), minItemsPerBlock, maxItemsPerBlock),
        // add pulsing again with (usually) different parameters
        new Pulsing41PostingsFormat(1 + random.nextInt(20), minItemsPerBlock, maxItemsPerBlock),
        //TODO as a PostingsFormat which wraps others, we should allow TestBloomFilteredLucene41Postings to be constructed
        //with a choice of concrete PostingsFormats. Maybe useful to have a generic means of marking and dealing
        //with such "wrapper" classes?
        new TestBloomFilteredLucene41Postings(),               
        new MockSepPostingsFormat(),
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

  public void testSameCodecDifferentInstance() throws Exception {
    Codec codec = new Lucene49Codec() {
      @Override
      public PostingsFormat getPostingsFormatForField(String field) {
        if ("id".equals(field)) {
          return new Pulsing41PostingsFormat(1);
        } else if ("date".equals(field)) {
          return new Pulsing41PostingsFormat(1);
        } else {
          return super.getPostingsFormatForField(field);
        }
      }
    };
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

  public void testSameCodecDifferentParams() throws Exception {
    Codec codec = new Lucene49Codec() {
      @Override
      public PostingsFormat getPostingsFormatForField(String field) {
        if ("id".equals(field)) {
          return new Pulsing41PostingsFormat(1);
        } else if ("date".equals(field)) {
          return new Pulsing41PostingsFormat(2);
        } else {
          return super.getPostingsFormatForField(field);
        }
      }
    };
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

        new FSTOrdPostingsFormat(),
        new FSTPulsing41PostingsFormat(1 + random.nextInt(20)),
        new FSTOrdPulsing41PostingsFormat(1 + random.nextInt(20)),
        new DirectPostingsFormat(LuceneTestCase.rarely(random) ? 1 : (LuceneTestCase.rarely(random) ? Integer.MAX_VALUE : maxItemsPerBlock),
                                 LuceneTestCase.rarely(random) ? 1 : (LuceneTestCase.rarely(random) ? Integer.MAX_VALUE : lowFreqCutoff)),
        new Pulsing41PostingsFormat(1 + random.nextInt(20), minItemsPerBlock, maxItemsPerBlock),
        // add pulsing again with (usually) different parameters
        new Pulsing41PostingsFormat(1 + random.nextInt(20), minItemsPerBlock, maxItemsPerBlock),
        //TODO as a PostingsFormat which wraps others, we should allow TestBloomFilteredLucene41Postings to be constructed
        //with a choice of concrete PostingsFormats. Maybe useful to have a generic means of marking and dealing
        //with such "wrapper" classes?
        new TestBloomFilteredLucene41Postings(),               
        new MockSepPostingsFormat(),
View Full Code Here

Examples of org.apache.lucene.codecs.pulsing.Pulsing41PostingsFormat

    {
      Directory dir = newDirectory();
      IndexWriterConfig conf = newIndexWriterConfig(TEST_VERSION_CURRENT,
          new MockAnalyzer(random()));
      conf.setCodec(TestUtil.alwaysPostingsFormat(new Pulsing41PostingsFormat(1 + random().nextInt(20))));
      IndexWriter w = new IndexWriter(dir, conf);
      try {
        w.addIndexes(toAdd);
        fail("no such codec");
      } catch (IllegalArgumentException ex) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.