Tabnine Logo
Word.getStartOffset
Code IndexAdd Tabnine to your IDE (free)

How to use
getStartOffset
method
in
com.chenlb.mmseg4j.Word

Best Java code snippets using com.chenlb.mmseg4j.Word.getStartOffset (Showing top 13 results out of 315)

origin: looly/hutool

@Override
public int getStartOffset() {
  return this.word.getStartOffset();
}
 
origin: looly/hutool

@Override
public int getStartOffset() {
  return this.word.getStartOffset();
}
 
origin: cn.hutool/hutool-all

@Override
public int getStartOffset() {
  return this.word.getStartOffset();
}
 
origin: medcl/elasticsearch-analysis-mmseg

public int getEndOffset() {
  return getStartOffset() + getLength();
}
public int getDegree() {
origin: com.chenlb.mmseg4j/mmseg4j-core

public int getEndOffset() {
  return getStartOffset() + getLength();
}
public int getDegree() {
origin: chenlb/mmseg4j-core

public int getEndOffset() {
  return getStartOffset() + getLength();
}
public int getDegree() {
origin: medcl/elasticsearch-analysis-mmseg

char[] chs = word.getSen();
int offset = word.getWordOffset(), n = 0, wordEnd = word.getWordOffset()+word.getLength();
int senStartOffset = word.getStartOffset() - offset;	//sen 在文件中的位置
int end = -1;	//上一次找到的位置
for(; offset<wordEnd-1; offset++) {
origin: chenlb/mmseg4j-core

char[] chs = word.getSen();
int offset = word.getWordOffset(), n = 0, wordEnd = word.getWordOffset()+word.getLength();
int senStartOffset = word.getStartOffset() - offset;	//sen 在文件中的位置
int end = -1;	//上一次找到的位置
for(; offset<wordEnd-1; offset++) {
origin: com.chenlb.mmseg4j/mmseg4j-core

char[] chs = word.getSen();
int offset = word.getWordOffset(), n = 0, wordEnd = word.getWordOffset()+word.getLength();
int senStartOffset = word.getStartOffset() - offset;	//sen 在文件中的位置
int end = -1;	//上一次找到的位置
for(; offset<wordEnd-1; offset++) {
origin: medcl/elasticsearch-analysis-mmseg

  @Override
  public final boolean incrementToken() throws IOException {
    clearAttributes();
    Word word = mmSeg.get().next();
    if(word != null) {
      //lucene 3.0
      //termAtt.setTermBuffer(word.getSen(), word.getWordOffset(), word.getLength());
      //lucene 3.1
      termAtt.copyBuffer(word.getSen(), word.getWordOffset(), word.getLength());
      offsetAtt.setOffset(word.getStartOffset(), word.getEndOffset());
      typeAtt.setType(word.getType());
      return true;
    } else {
      end();
      return false;
    }
  }
}
origin: com.chenlb.mmseg4j/mmseg4j-solr

  @Override
  public final boolean incrementToken() throws IOException {
    clearAttributes();
    Word word = mmSeg.next();
    if(word != null) {
      termAtt.copyBuffer(word.getSen(), word.getWordOffset(), word.getLength());
      offsetAtt.setOffset(word.getStartOffset(), word.getEndOffset());
      typeAtt.setType(word.getType());
      return true;
    } else {
      return false;
    }
  }
}
origin: chenlb/mmseg4j-solr

  @Override
  public final boolean incrementToken() throws IOException {
    clearAttributes();
    Word word = mmSeg.next();
    if(word != null) {
      termAtt.copyBuffer(word.getSen(), word.getWordOffset(), word.getLength());
      offsetAtt.setOffset(word.getStartOffset(), word.getEndOffset());
      typeAtt.setType(word.getType());
      return true;
    } else {
      return false;
    }
  }
}
origin: org.tinygroup/org.tinygroup.mmseg4j

@Override
public final boolean incrementToken() throws IOException {
  clearAttributes();
  Word word = mmSeg.next();
  if (word != null) {
    //lucene 3.0
    //termAtt.setTermBuffer(word.getSen(), word.getWordOffset(), word.getLength());
    //lucene 3.1
    termAtt.copyBuffer(word.getSen(), word.getWordOffset(), word.getLength());
    offsetAtt.setOffset(word.getStartOffset(), word.getEndOffset());
    typeAtt.setType(word.getType());
    return true;
  } else {
    end();
    return false;
  }
}
com.chenlb.mmseg4jWordgetStartOffset

Javadoc

此 word 在整个文本中的偏移位置

Popular methods of Word

  • getString
  • getEndOffset
  • getLength
  • getSen
  • getWordOffset
    词在 char[] sen 的偏移位置
  • getType
  • <init>
  • getDegree
  • setDegree

Popular in Java

  • Updating database using SQL prepared statement
  • putExtra (Intent)
  • getExternalFilesDir (Context)
  • compareTo (BigDecimal)
  • HttpServer (com.sun.net.httpserver)
    This class implements a simple HTTP server. A HttpServer is bound to an IP address and port number a
  • GridBagLayout (java.awt)
    The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • TreeMap (java.util)
    Walk the nodes of the tree left-to-right or right-to-left. Note that in descending iterations, next
  • AtomicInteger (java.util.concurrent.atomic)
    An int value that may be updated atomically. See the java.util.concurrent.atomic package specificati
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • Top plugins for WebStorm
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