com.arextest.config.mapper.DynamicClassMapperImpl Maven / Gradle / Ivy
package com.arextest.config.mapper;
import com.arextest.config.model.dao.config.DynamicClassCollection;
import com.arextest.config.model.dto.record.DynamicClassConfiguration;
import javax.annotation.Generated;
@Generated(
value = "org.mapstruct.ap.MappingProcessor",
date = "2024-09-19T06:47:37+0000",
comments = "version: 1.2.0.Final, compiler: javac, environment: Java 11.0.24 (Eclipse Adoptium)"
)
public class DynamicClassMapperImpl implements DynamicClassMapper {
@Override
public DynamicClassConfiguration dtoFromDao(DynamicClassCollection dao) {
if ( dao == null ) {
return null;
}
DynamicClassConfiguration dynamicClassConfiguration = new DynamicClassConfiguration();
dynamicClassConfiguration.setId( dao.getId() );
dynamicClassConfiguration.setAppId( dao.getAppId() );
dynamicClassConfiguration.setFullClassName( dao.getFullClassName() );
dynamicClassConfiguration.setMethodName( dao.getMethodName() );
dynamicClassConfiguration.setParameterTypes( dao.getParameterTypes() );
dynamicClassConfiguration.setConfigType( dao.getConfigType() );
dynamicClassConfiguration.setKeyFormula( dao.getKeyFormula() );
dynamicClassConfiguration.setModifiedTime( dao.getDataChangeUpdateTime() == null ? null : new java.sql.Timestamp(dao.getDataChangeUpdateTime()) );
return dynamicClassConfiguration;
}
@Override
public DynamicClassCollection daoFromDto(DynamicClassConfiguration dto) {
if ( dto == null ) {
return null;
}
DynamicClassCollection dynamicClassCollection = new DynamicClassCollection();
dynamicClassCollection.setAppId( dto.getAppId() );
dynamicClassCollection.setFullClassName( dto.getFullClassName() );
dynamicClassCollection.setMethodName( dto.getMethodName() );
dynamicClassCollection.setParameterTypes( dto.getParameterTypes() );
dynamicClassCollection.setConfigType( dto.getConfigType() );
dynamicClassCollection.setKeyFormula( dto.getKeyFormula() );
dynamicClassCollection.setId( null );
dynamicClassCollection.setDataChangeCreateTime( System.currentTimeMillis() );
dynamicClassCollection.setDataChangeUpdateTime( System.currentTimeMillis() );
return dynamicClassCollection;
}
}