package instantiation;

import java.util.Map;

import org.apache.ojb.broker.accesslayer.RowReaderDefaultImpl;
import org.apache.ojb.broker.metadata.ClassDescriptor;

/**
 * @author tal
 */
public class RowReaderImpl extends RowReaderDefaultImpl {
	/**
	 * Constructor for RowReaderCustomizedImpl.
	 */
	public RowReaderImpl() {
		super();
	}

	/**
	 * Replace original implementation with one that calls a factory to
	 * instantiate the object.
	 * 
	 * @see org.apache.ojb.broker.accesslayer.RowReaderDefaultImpl#buildWithReflection(ClassDescriptor, Map)
	 */
	protected Object buildWithReflection(ClassDescriptor cld, Map row) {
		return InstantiationFactory.getInstance().getInstantiation().createObject(cld, row);
	}
}
