| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--gnu.regexp.REMatchEnumeration
An REMatchEnumeration enumerates regular expression matches over a
 given input text.  You obtain a reference to an enumeration using
 the getMatchEnumeration() methods on an instance of
 RE. 
 
 REMatchEnumeration does lazy computation; that is, it will not
 search for a match until it needs to.  If you'd rather just get all
 the matches at once in a big array, use the
 getAllMatches() methods on RE.  However, using an
 enumeration can help speed performance when the entire text does
 not need to be searched immediately.
 
 
 The enumerated type is especially useful when searching on a Reader
 or InputStream, because the InputStream read position cannot be
 guaranteed after calling getMatch() (see the
 description of that method for an explanation of why).  Enumeration
 also saves a lot of overhead required when calling
 getMatch() multiple times.
| Method Summary | |
|  boolean | hasMoreElements()Returns true if there are more matches in the input text. | 
|  boolean | hasMoreMatches()Returns true if there are more matches in the input text. | 
|  boolean | hasMoreMatches(java.lang.StringBuffer buffer)Returns true if there are more matches in the input text. | 
|  java.lang.Object | nextElement()Returns the next match in the input text. | 
|  REMatch | nextMatch()Returns the next match in the input text. | 
| Methods inherited from class java.lang.Object | 
| equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Method Detail | 
public boolean hasMoreElements()
hasMoreElements in interface java.util.Enumerationpublic boolean hasMoreMatches()
public boolean hasMoreMatches(java.lang.StringBuffer buffer)
public java.lang.Object nextElement()
                             throws java.util.NoSuchElementException
nextElement in interface java.util.Enumeration
public REMatch nextMatch()
                  throws java.util.NoSuchElementException
| 
 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||