# ProductAttributeHistoryRowMapper.java

    package com.mycim.server.spec.dao.mapper;

    import com.mycim.framework.jdbc.mapper.RowMapper;
    import com.mycim.valueobject.prp.ProductAttributeHistory;

    import java.sql.ResultSet;
    import java.sql.SQLException;

    public class ProductAttributeHistoryRowMapper implements RowMapper<ProductAttributeHistory> {

        private ProductAttributeHistory productAttributeHistory;

        @Override
        public ProductAttributeHistory mapRow(ResultSet rs, int rowNum) throws SQLException {
            productAttributeHistory = new ProductAttributeHistory();

            productAttributeHistory.setTransRrn(rs.getLong("TRANS_RRN"));
            productAttributeHistory.setTransId(rs.getString("TRANS_ID"));
            productAttributeHistory.setTransSequence(rs.getInt("TRANS_SEQUENCE"));
            productAttributeHistory.setTransTimestamp(rs.getTimestamp("TRANS_TIMESTAMP"));
            productAttributeHistory.setTransPerformedBy(rs.getString("TRANS_PERFORMED_BY"));

            productAttributeHistory.setProductRrn(rs.getLong("PRODUCT_RRN"));
            productAttributeHistory.setProductId(rs.getString("PRODUCT_ID"));
            productAttributeHistory.setProductVersion(rs.getInt("PRODUCT_VERSION"));

            productAttributeHistory.setProcessRrn(rs.getLong("PROCESS_RRN"));
            productAttributeHistory.setProcessId(rs.getString("PROCESS_ID"));
            productAttributeHistory.setProcessVersion(rs.getInt("PROCESS_VERSION"));

            productAttributeHistory.setRouteRrn(rs.getLong("ROUTE_RRN"));
            productAttributeHistory.setRouteId(rs.getString("ROUTE_ID"));
            productAttributeHistory.setRouteVersion(rs.getInt("ROUTE_VERSION"));
            productAttributeHistory.setRouteSeq(rs.getString("ROUTE_SEQ"));

            productAttributeHistory.setOperationRrn(rs.getLong("OPERATION_RRN"));
            productAttributeHistory.setOperationId(rs.getString("OPERATION_ID"));
            productAttributeHistory.setOperationSeq(rs.getString("OPERATION_SEQ"));

            productAttributeHistory.setFlowSeq(rs.getString("FLOW_SEQ"));

            productAttributeHistory.setAttributeNameRrn(rs.getLong("ATTRIBUTE_NAME_RRN"));
            productAttributeHistory.setAttributeName(rs.getString("ATTRIBUTE_NAME"));
            productAttributeHistory.setAttributeValueRrn(rs.getLong("ATTRIBUTE_VALUE_RRN"));
            productAttributeHistory.setAttributeValue(rs.getString("ATTRIBUTE_VALUE"));

            productAttributeHistory.setStatus(rs.getString("STATUS"));
            productAttributeHistory.setEffectiveTime(rs.getTimestamp("EFFECTIVE_TIME"));
            productAttributeHistory.setTerminatedTime(rs.getTimestamp("TERMINATED_TIME"));
            productAttributeHistory.setCreatedUser(rs.getString("CREATED_USER"));
            productAttributeHistory.setCreatedTime(rs.getTimestamp("CREATED_TIME"));
            productAttributeHistory.setUpdatedUser(rs.getString("UPDATED_USER"));
            productAttributeHistory.setUpdatedTime(rs.getTimestamp("UPDATED_TIME"));

            return productAttributeHistory;
        }

    }