protected final Object iterate(final Object pvSourceObject, final Object pvNewTargetObject, final Iterator<?> pvIterator, final IConverterExtension pvConverter) {
		int pos = 0;
		
		// cycle detection for Collections
		if (getWithCycleDetection() && cycleDetector.cycleDetection(pvSourceObject)) {
			throw new ConversionException("Detected cycle in Collection.");
		}

		Iterator<?> iter = pvIterator;
		while (iter.hasNext()) {
			Object lvIteratorObject = iter.next();
			Object lvKeyValue[] = doTransformIteratorObject2KeyValuePair(lvIteratorObject);
			
			if (ClassPropertyFilterHelper.isPropertyToFiltering(classPropertyFilterHandler, pvSourceObject.getClass(), lvKeyValue[0])  == false) {
				ConversionContext lvContext = fireBeforeConvertRecursion( (pos + 1), lvKeyValue[0], lvKeyValue[1]);
				if (!lvContext.cancelConvert) {
					lvKeyValue = doConvert(pvSourceObject, pvNewTargetObject, lvContext.key, lvContext.value, pvConverter);
					Object lvValue = lvKeyValue[1];
//					if (lvValue != null && lvValue.toString() != null && lvValue.toString().startsWith(UniqueIdGenerator.UNIQUE_ID_PROPERTY)) {
//						String lvKey = lvValue.toString().substring(UniqueIdGenerator.UNIQUE_ID_PROPERTY.length());
//						Object o = pvConverter.getObjectByUniqueId(lvKey);
//						if (o != null) {
//							lvKeyValue[1] = o;						
//						}
//					}
				}
				
				lvContext = fireAfterConvertRecursion(lvContext, lvKeyValue[0], lvKeyValue[1]);
				if ((!lvContext.cancelConvert) &&
					 ((lvKeyValue[1] != null || getIgnoreNullValues() == false) || (lvKeyValue[0] != null && lvKeyValue[0].equals(Util.getKeyWordClass())))) {
						this.doAddObject(pvSourceObject, pvNewTargetObject, lvKeyValue[0], lvKeyValue[1], pos);
				}
			}
			pos++;
		}
		return pvNewTargetObject;
	}
protected final Object iterate ( final Object pvSourceObject , final Object pvNewTargetObject , final Iterator < ? > pvIterator , final IConverterExtension pvConverter ) { int pos = 0 ; if ( getWithCycleDetection ( ) && cycleDetector . cycleDetection ( pvSourceObject ) ) { throw new ConversionException ( "Detected cycle in Collection." ) ; } Iterator < ? > iter = pvIterator ; while ( iter . hasNext ( ) ) { Object lvIteratorObject = iter . next ( ) ; Object lvKeyValue [ ] = doTransformIteratorObject2KeyValuePair ( lvIteratorObject ) ; if ( ClassPropertyFilterHelper . isPropertyToFiltering ( classPropertyFilterHandler , pvSourceObject . getClass ( ) , lvKeyValue [ 0 ] ) == false ) { ConversionContext lvContext = fireBeforeConvertRecursion ( ( pos + 1 ) , lvKeyValue [ 0 ] , lvKeyValue [ 1 ] ) ; if ( ! lvContext . cancelConvert ) { lvKeyValue = doConvert ( pvSourceObject , pvNewTargetObject , lvContext . key , lvContext . value , pvConverter ) ; Object lvValue = lvKeyValue [ 1 ] ; } lvContext = fireAfterConvertRecursion ( lvContext , lvKeyValue [ 0 ] , lvKeyValue [ 1 ] ) ; if ( ( ! lvContext . cancelConvert ) && ( ( lvKeyValue [ 1 ] != null || getIgnoreNullValues ( ) == false ) || ( lvKeyValue [ 0 ] != null && lvKeyValue [ 0 ] . equals ( Util . getKeyWordClass ( ) ) ) ) ) { this . doAddObject ( pvSourceObject , pvNewTargetObject , lvKeyValue [ 0 ] , lvKeyValue [ 1 ] , pos ) ; } } pos ++ ; } return pvNewTargetObject ; }
This is the main iterate method. This method has a counter of recursion and handle the event before and after conversion.
This method is calling from the convert-method.
The order of calling methods is:
<ol>
<li>doTransformIteratorObject2KeyValuePair
<li>doConvert
<li>doAddObject
</ol>

@param pvSourceObject The old Collection, Array or Map, where object (from iterator) ought to read.
@param pvNewTargetObject The new Collection, Array, Map or Bean, where object (from iterator) ought to added.
@param pvIterator The iterator him self.
@param pvConverter Instance of Converter, for recursive execution.
@return The new Collection, Array or Map, where all object (from iterator) has added.