private ObjectType getFieldTypeOfProjAttrib(ExecutionContext context, CompiledValue cv) throws TypeMismatchException, AmbiguousNameException { // Identify the RuntimeIterator for the compiled value ObjectType retType = TypeUtils.OBJECT_TYPE; try { RuntimeIterator rit = context.findRuntimeIterator(cv); List pathOnItr = cv.getPathOnIterator(rit, context); if (pathOnItr != null) { String path[] = (String[]) pathOnItr.toArray(new String[pathOnItr.size()]); ObjectType ot[] = PathUtils.calculateTypesAlongPath(context, rit.getElementType(), path); retType = ot[ot.length - 1]; } } catch (NameNotFoundException ignore) { // Unable to determine the type Of attribute.It will default to // ObjectType } return retType; }
RuntimeIterator rIter = context.findRuntimeIterator(expr); List currentIters = context.getCurrentIterators(); for (int i = 0; i < currentIters.size(); ++i) {