Package com.aliasi.chunk

Examples of com.aliasi.chunk.Chunking


   * is likely dropped)
   * @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

Related Classes of com.aliasi.chunk.Chunking

Copyright © 2018 www.massapicom. 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.