if (transformer instanceof PullTransformer) {
// For intermediate node, set data type to null
result = ((PullTransformer)transformer).transform(result, context);
} else if (transformer instanceof PushTransformer) {
DataPipeTransformer dataPipeFactory = (i < size - 1) ? (DataPipeTransformer)path.get(++i) : null;
DataPipe dataPipe = dataPipeFactory == null ? null : dataPipeFactory.newInstance();
((PushTransformer)transformer).transform(result, dataPipe.getSink(), context);
result = dataPipe.getResult();
}
i++;
}
return result;