Tabnine Logo
OContextualRecordId.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
com.orientechnologies.orient.core.id.OContextualRecordId
constructor

Best Java code snippets using com.orientechnologies.orient.core.id.OContextualRecordId.<init> (Showing top 2 results out of 315)

origin: orientechnologies/orientdb-lucene

@Override
public OIdentifiable next() {
 if (localIndex == array.length) {
  localIndex = 0;
  fetchMoreResult();
 }
 final ScoreDoc score = array[localIndex++];
 Document ret = null;
 OContextualRecordId res = null;
 try {
  ret = queryContext.searcher.doc(score.doc);
  String rId = ret.get(OLuceneIndexManagerAbstract.RID);
  res = new OContextualRecordId(rId);
  manager.onRecordAddedToResultSet(queryContext, res, ret, score);
 } catch (IOException e) {
  e.printStackTrace();
 }
 index++;
 return res;
}
origin: com.orientechnologies/orientdb-lucene

private OContextualRecordId toRecordId(Document doc, ScoreDoc score) {
 String rId = doc.get(OLuceneIndexEngineAbstract.RID);
 OContextualRecordId res = new OContextualRecordId(rId);
 IndexReader indexReader = queryContext.getSearcher().getIndexReader();
 try {
  for (String field : highlighted) {
   String text = doc.get(field);
   TokenStream tokenStream = TokenSources.getAnyTokenStream(indexReader, score.doc, field, doc, engine.indexAnalyzer());
   TextFragment[] frag = highlighter.getBestTextFragments(tokenStream, text, true, maxNumFragments);
   queryContext.addHighlightFragment(field, frag);
  }
  engine.onRecordAddedToResultSet(queryContext, res, doc, score);
  return res;
 } catch (IOException | InvalidTokenOffsetsException e) {
  throw OException.wrapException(new OLuceneIndexException("error while highlighting"), e);
 }
}
com.orientechnologies.orient.core.idOContextualRecordId<init>

Popular methods of OContextualRecordId

  • getContext
  • setContext

Popular in Java

  • Reading from database using SQL prepared statement
  • setScale (BigDecimal)
  • setContentView (Activity)
  • requestLocationUpdates (LocationManager)
  • ArrayList (java.util)
    ArrayList is an implementation of List, backed by an array. All optional operations including adding
  • Collection (java.util)
    Collection is the root of the collection hierarchy. It defines operations on data collections and t
  • ImageIO (javax.imageio)
  • JTable (javax.swing)
  • IOUtils (org.apache.commons.io)
    General IO stream manipulation utilities. This class provides static utility methods for input/outpu
  • Reflections (org.reflections)
    Reflections one-stop-shop objectReflections scans your classpath, indexes the metadata, allows you t
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now