use of org.whole.lang.environment.model.Name in project whole by wholeplatform.
the class ExecuteSampleModelRunnable method addMissingVariables.
protected void addMissingVariables(IEntity contextModel, MissingVariableException e) {
String[] varNames = e.getVariableNames();
EnvironmentEntityFactory ef = EnvironmentEntityFactory.instance;
for (String varName : varNames) {
Name var = ef.createName(varName);
IEntity find = Matcher.find(var, contextModel, false);
if (find == null)
contextModel.wAdd(ef.createBinding(var, CommonsEntityAdapterFactory.createResolver(EnvironmentEntityDescriptorEnum.Value)));
}
}
Aggregations