use of org.whole.lang.actions.model.ActionCall in project whole by wholeplatform.
the class SemanticsInterpreterVisitor method visit.
@Override
public void visit(StructuredVariable entity) {
ActionsEntityFactory aef = ActionsEntityFactory.instance;
QueriesEntityFactory qef = QueriesEntityFactory.instance;
ActionCall actionCall = aef.createActionCall(aef.createLabel("whole:org.whole.lang.semantics:SemanticsActions:1.0.0#toVariableFlatName"), qef.createVariableRefStep("variable").wGetAdapter(ActionsEntityDescriptorEnum.SelectedEntities));
getBindings().wDef("variable", entity);
IEntity varNameEntity = BehaviorUtils.evaluate(actionCall, 0, getOperation());
if (isSelectedFeature(SemanticsUtils.USE_IDENTIFIER_SEMANTICS))
setResult(varNameEntity);
else {
IEntity varValue = BindingUtils.wGet(getBindings(), varNameEntity.wStringValue());
if (varValue == null)
throw new MissingVariableException(entity.toString()).withSourceEntity(entity).withBindings(getBindings());
setResult(varValue);
}
}
use of org.whole.lang.actions.model.ActionCall in project whole by wholeplatform.
the class ActionCallPart method getModelSpecificChildren.
protected List<IEntity> getModelSpecificChildren() {
ActionCall entity = getModelEntity();
List<IEntity> list = new ArrayList<IEntity>(2);
list.add(entity.getName());
list.add(entity.getSelectedEntities());
return list;
}
Aggregations