return new OSwitch(_context.getOProcess(), _context.getCurrent());
}
public void compile(OActivity output, Activity src) {
OSwitch oswitch = (OSwitch) output;
SwitchActivity switchDef = (SwitchActivity)src;
for (SwitchActivity.Case ccase : switchDef.getCases()) {
OSwitch.OCase ocase = new OSwitch.OCase(_context.getOProcess());
ocase.activity = _context.compile(ccase.getActivity());
ocase.expression = (ccase.getCondition() == null ? _context.constantExpr(true) : _context.compileExpr(ccase.getCondition()));
oswitch.addCase(ocase);
}