index = token.indexOf("/");
if (index > 0) {
each = Integer.parseInt(token.substring(index + 1));
if (each == 0) {
throw new DataParseException(Messages.getString("CrontabPart.NeverUseExpressions")); //$NON-NLS-1$
}
token = token.substring(0, index);
}
if (token.equals("*")) {
for (i = low; i < (bArray.length - offset); i += each) {
bArray[i + offset] = true;
}
return each == 1;
}
index = token.indexOf(",");
if (index > 0) {
StringTokenizer tokenizer = new StringTokenizer(token, ",");
while (tokenizer.hasMoreElements()) {
parseToken(tokenizer.nextToken());
}
return false;
}
index = token.indexOf("-");
if (index > 0) {
int start = Integer.parseInt(token.substring(0, index));
int end = Integer.parseInt(token.substring(index + 1));
/*
* if(bBeginInOne) {
* start--;
* end--;
* }
*/
for (int j = start; j <= end; j += each) {
bArray[j + offset] = true;
}
return false;
}
int iValue = Integer.parseInt(token);
/*
* if(bBeginInOne) {
* iValue--;
* }
*/
bArray[iValue + offset] = true;
return false;
}
catch (Exception e) {
throw new DataParseException(Messages.getString("CrontabPart.SomethingWasWrong") + token, e); //$NON-NLS-1$
}
}