aQute.bnd.osgi.Analyzer.<init>()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(6.0k)|赞(0)|评价(0)|浏览(178)

本文整理了Java中aQute.bnd.osgi.Analyzer.<init>()方法的一些代码示例,展示了Analyzer.<init>()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Analyzer.<init>()方法的具体详情如下:
包路径:aQute.bnd.osgi.Analyzer
类名称:Analyzer
方法名:<init>

Analyzer.<init>介绍

暂无

代码示例

代码示例来源:origin: stackoverflow.com

new Analyzer() {
  public TokenStream tokenStream(String fieldName,
      Reader reader) {

代码示例来源:origin: stackoverflow.com

this.analyzer = new Analyzer({
   url: Dolby.checkDDPlus() ? 
     'http://example.com/samples_Dolby.mp4' :
     'http://example.com/samples_Dolby.mp3',
   // ...
 });

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
 @Override
 protected TokenStreamComponents createComponents(String fieldName, Reader reader) {
  Tokenizer source = new LetterTokenizer(Version.LUCENE_44, reader);
  TokenStream filter = new LowercaseFilter(Version.LUCENE_44, source);
  return new TokenStreamComponents(source, filter);
 }
};

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib

/**
 * @see aQute.bnd.service.diff.Differ#tree(aQute.bnd.osgi.Jar)
 */
@Override
public Tree tree(Jar newer) throws Exception {
  try (Analyzer anewer = new Analyzer(newer)) {
    return tree(anewer);
  }
}

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
 @Override
 protected TokenStreamComponents createComponents(String fieldName, Reader reader) {
  Tokenizer source = new FooTokenizer(reader);
  TokenStream filter = new FooFilter(source);
  filter = new BarFilter(filter);
  return new TokenStreamComponents(source, filter);
 }
};

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd

/**
 * @see aQute.bnd.service.diff.Differ#tree(aQute.bnd.osgi.Jar)
 */
@Override
public Tree tree(Jar newer) throws Exception {
  try (Analyzer anewer = new Analyzer(newer)) {
    return tree(anewer);
  }
}

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
  @Override
  protected TokenStreamComponents createComponents(final String fieldName) {
    Tokenizer source = new WhitespaceTokenizer();
    TokenStream filter = new LowerCaseAnalyzer(source);
    return new TokenStreamComponents(source, filter);
  }
}

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
 @Override
 protected TokenStreamComponents createComponents(String fieldName, Reader reader) {
  Tokenizer source = new NGramTokenizer(reader, 12, 12);
  TokenStream filter = new LowercaseFilter(source);
  return new TokenStreamComponents(source, filter);
 }
};

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
  @Override
  protected TokenStreamComponents createComponents(String fieldName) {
    Tokenizer tokenizer = new StandardTokenizer();
    TokenStream stream = new DoubleMetaphoneFilter(tokenizer, 6, false);
    return new TokenStreamComponents(tokenizer, stream);
  }
};

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
 @Override
 protected TokenStreamComponents createComponents(String fieldName, Reader reader) {
  Tokenizer source = new FooTokenizer(reader); //ex. StandardAnalyzer
  TokenStream filter = new FooFilter(source); //ex. StandardFilter, LowercaseFilter, StopFilter, etc.
  filter = new BarFilter(filter);
  filter = new LengthFilter(true, filter, 3, Integer.MAX_VALUE);
  return new TokenStreamComponents(source, filter);
 }
};

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
   @Override
   protected Analyzer.TokenStreamComponents createComponents(String fieldName, Reader reader) {
     final Tokenizer source = new StandardTokenizer(reader);
     TokenStream result = new LowerCaseFilter(source);
     result = new StopFilter(result, PortugueseAnalyzer.getDefaultStopSet());
     result = new BrazilianStemFilter(result);
     return new TokenStreamComponents(source, result);
   }
 };

代码示例来源:origin: stackoverflow.com

public static void main (String... args) throws Exception {
  Analyzer a = new Analyzer();

  ClassPool pool = ClassPool.getDefault();
  CtClass cc = pool.get("test.Foo");
  for (CtMethod cm : cc.getDeclaredMethods()) {
    Frame[] frames = a.analyze(cm);
    for (Frame f : frames) {
      System.out.println(f);
    }
  }
}

代码示例来源:origin: stackoverflow.com

Analyzer analyzer = new Analyzer() {
 @Override
 protected TokenStreamComponents createComponents(String fieldName, Reader reader) {
  Tokenizer source = new FooTokenizer(reader);
  TokenStream filter = new FooFilter(source);
  //etc...

  WordnetSynonymParser parser = new WordnetSynonymParser(true, false, analyzer);
  parser.add(wordnetReader);
  filter = new SynonymFilter(filter, parser.build(), true);

  return new TokenStreamComponents(source, filter);
 }
};

代码示例来源:origin: reficio/p2-maven-plugin

private static Analyzer instantiateAnalyzer(ArtifactBundlerRequest request) throws Exception {
  Analyzer analyzer = new Analyzer();
  analyzer.setJar(getInputJarWithBlankManifest(request));
  return analyzer;
}

代码示例来源:origin: biz.aQute/bndlib

/**
 * @see aQute.bnd.service.diff.Differ#diff(aQute.lib.resource.Jar,
 *      aQute.lib.resource.Jar)
 */
public Tree tree(Jar newer) throws Exception {
  Analyzer anewer = new Analyzer();
  try {
    anewer.setJar(newer);
    return tree(anewer);
  }
  finally {
    anewer.setJar((Jar) null);
    anewer.close();
  }
}

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bndlib

public Verifier(Jar jar) throws Exception {
  this.analyzer = new Analyzer(this);
  this.analyzer.use(this);
  addClose(analyzer);
  this.analyzer.setJar(jar);
  this.manifest = this.analyzer.calcManifest();
  this.main = Domain.domain(manifest);
  this.dot = jar;
  getInfo(analyzer);
}

代码示例来源:origin: biz.aQute/bndlib

public Verifier(Jar jar) throws Exception {
  this.analyzer = new Analyzer(this);
  this.analyzer.use(this);
  addClose(analyzer);
  this.analyzer.setJar(jar);
  this.manifest = this.analyzer.calcManifest();
  this.main = Domain.domain(manifest);
  this.dot = jar;
  getInfo(analyzer);
}

代码示例来源:origin: biz.aQute.bnd/bndlib

public Verifier(Jar jar) throws Exception {
  this.analyzer = new Analyzer(this);
  this.analyzer.use(this);
  addClose(analyzer);
  this.analyzer.setJar(jar);
  this.manifest = this.analyzer.calcManifest();
  this.main = Domain.domain(manifest);
  this.dot = jar;
  getInfo(analyzer);
}

代码示例来源:origin: biz.aQute.bnd/biz.aQute.bnd

public Verifier(Jar jar) throws Exception {
  this.analyzer = new Analyzer(this);
  this.analyzer.use(this);
  addClose(analyzer);
  this.analyzer.setJar(jar);
  this.manifest = this.analyzer.calcManifest();
  this.main = Domain.domain(manifest);
  this.dot = jar;
  getInfo(analyzer);
}

代码示例来源:origin: biz.aQute.bnd/bnd

public Verifier(Jar jar) throws Exception {
  this.analyzer = new Analyzer(this);
  this.analyzer.use(this);
  addClose(analyzer);
  this.analyzer.setJar(jar);
  this.manifest = this.analyzer.calcManifest();
  this.main = Domain.domain(manifest);
  this.dot = jar;
  getInfo(analyzer);
}

相关文章

Analyzer类方法