Examples of chunkSet()


Examples of com.aliasi.chunk.Chunking.chunkSet()

   * @return a List of Strings corresponding to sentences in the input
   * string
   */
  private static List<String> getSentences(String input, int start, int stop) {
    Chunking chunking = CHUNKER.chunk(input.toCharArray(), start, stop);
    Set<Chunk> sentences = chunking.chunkSet();
    String slice = chunking.charSequence().toString();
   
    List<String> result = new ArrayList<String>(sentences.size());
    for(Chunk c: sentences) {
      result.add(slice.substring(c.start(), c.end()));
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.