title: how to identify a end of a sentence
body: <pre><code>String x=" i am going to the party at 6.00 in the evening. are you coming with me?";
  </code></pre>
  
  <p>if i have the above string, i need that to be broken to sentences by using sentence boundry punctuations(like . and ?)</p>
  
  <p>but it should not split the sentence at 6 because of having an pointer there. is there a way to identify what is the correct sentence boundry place in java? i have tried using stringTokenizer in java.util pakage but it always break the sentence whenever it finds a pointer. Can someone suggest me a method to do this correctly?</p>
  
  <p>This is the method which i have tried in tokenizing a text into sentences. </p>
  
  <pre><code>public static ArrayList&lt;String&gt; sentence_segmenter(String text) {
      ArrayList&lt;String&gt; Sentences = new ArrayList&lt;String&gt;();
  
      StringTokenizer st = new StringTokenizer(text, ".?!");
      while (st.hasMoreTokens()) {
  
          Sentences.add(st.nextToken());
      }
      return Sentences;
  }
  </code></pre>
  
  <p>also i have a method to segement sentences into phrases, but here also when the program found comma(,) it splits the text. but i dont need to split it when there is a number like 60,000 with a comma in the middle.  following is the method i am using to segment the phrases.</p>
  
  <pre><code>   public static ArrayList&lt;String&gt; phrasesSegmenter(String text) {
      ArrayList&lt;String&gt; phrases = new ArrayList&lt;String&gt;();
      StringTokenizer st = new StringTokenizer(text, ",");
      while (st.hasMoreTokens()) {
          phrases.add(st.nextToken());
      }
      return phrases;
  }
  </code></pre>