// Should not happen if constructor is working.
throw new BpelEngineException("InternalError: reference to unknown external variable " + variable.extVar.externalVariableId);
}
Locator locator = new Locator(variable.extVar.externalVariableId,_pid,iid,reference);
Value newval = new Value(locator,val,null);
newval = evar._engine.writeValue(((OElementVarType) variable.type).elementType, newval);
return newval;
}