1 |
/* Pattern.java -- Compiled regular expression ready to be applied. |
/* Pattern.java -- Compiled regular expression ready to be applied. |
2 |
Copyright (C) 2002, 2004 Free Software Foundation, Inc. |
Copyright (C) 2002, 2004, 2005 Free Software Foundation, Inc. |
3 |
|
|
4 |
This file is part of GNU Classpath. |
This file is part of GNU Classpath. |
5 |
|
|
188 |
int count = 0; |
int count = 0; |
189 |
int start = 0; |
int start = 0; |
190 |
int end; |
int end; |
191 |
boolean matched; |
boolean matched = matcher.find(); |
192 |
|
|
193 |
while (matched = matcher.find() && (limit <= 0 || count < limit - 1)) |
while (matched && (limit <= 0 || count < limit - 1)) |
194 |
{ |
{ |
195 |
++count; |
++count; |
196 |
end = matcher.start(); |
end = matcher.start(); |
208 |
list.add(text); |
list.add(text); |
209 |
} |
} |
210 |
start = matcher.end(); |
start = matcher.end(); |
211 |
|
matched = matcher.find(); |
212 |
} |
} |
213 |
|
|
214 |
// We matched nothing. |
// We matched nothing. |