提交 d19d31c4 编写于 作者: K kohsuke

i18n


git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@7060 71c3de6d-444a-0410-be80-ed276b4c234a
上级 3159e163
......@@ -36,9 +36,9 @@ abstract class BaseParser extends LLkParser {
rangeCheck(start, field);
rangeCheck(end, field);
if (step <= 0)
error("step must be positive, but found " + step);
error(Messages.BaseParser_MustBePositive(step));
if (start>end)
error("You mean "+end+'-'+start+'?');
error(Messages.BaseParser_StartEndReversed(end,start));
long bits = 0;
for (int i = start; i <= end; i += step) {
......@@ -53,8 +53,7 @@ abstract class BaseParser extends LLkParser {
protected void rangeCheck(int value, int field) throws ANTLRException {
if( value<LOWER_BOUNDS[field] || UPPER_BOUNDS[field]<value ) {
error(value +" is an invalid value. Must be within "+
LOWER_BOUNDS[field]+" and "+UPPER_BOUNDS[field]);
error(Messages.BaseParser_OutOfRange(value,LOWER_BOUNDS[field],UPPER_BOUNDS[field]));
}
}
......
......@@ -37,7 +37,7 @@ public final class CronTabList {
try {
r.add(new CronTab(line,lineNumber));
} catch (ANTLRException e) {
throw new ANTLRException("Invalid input: \""+line+"\": "+e.toString(),e);
throw new ANTLRException(Messages.CronTabList_InvalidInput(line,e.toString()),e);
}
}
return new CronTabList(r);
......
BaseParser.StartEndReversed=You mean {0}-{1}?
BaseParser.MustBePositive=step must be positive, but found {0}
BaseParser.OutOfRange={0} is an invalid value. Must be within {1} and {2}
CronTabList.InvalidInput=Invalid input: "{0}": {1}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册