ArrayList<Template> candidates = wg.specializeTemplates(itpl);
if(candidates.size() == 0)
return this.setPlanError(planexe,
"No Specialized templates after planning");
ArrayList<Template> bts = new ArrayList<Template>();
<BUG>for(Template t : candidates)

bts.addAll(wg.selectInputDataObjects(t));
if(bts.size() == 0)</BUG>
return this.setPlanError(planexe,

ArrayList<Template> candidates = wg.specializeTemplates(itpl);
if(candidates.size() == 0)
return this.setPlanError(planexe,
"No Specialized templates after planning");
ArrayList<Template> bts = new ArrayList<Template>();
for(Template t : candidates) {
ArrayList<VariableBindingsList> bindings = wg.selectInputDataObjects(t);
for(VariableBindingsList binding : bindings)
bts.add(wg.bindTemplate(t, binding));
}
if(bts.size() == 0)
return this.setPlanError(planexe,
