我有以下语法规则:
pacman
: section section map section
;
我想为此规则编写一个 Java 操作,以不同方式处理三个不同section
的 s。三个不同实例的句柄是什么?
这是显示我想要的伪代码:
pacman
: section section map section
{
processFirstSection($section[0]);
if(checkSecondSection($section[1]))
{
//The if statement isn't important itself;
//the point is that I do completely different
//things with each section
handleThirdSection($section[2]);
}
}
;