package com.eactive.eai.rms.onl.manage.rule.layouttype;

import org.mapstruct.BeanMapping;
import org.mapstruct.InheritInverseConfiguration;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.MappingTarget;
import org.mapstruct.NullValuePropertyMappingStrategy;
import org.mapstruct.ReportingPolicy;

import com.eactive.eai.data.entity.onl.transformer.layout.LayoutTypeEntity;
import com.eactive.eai.data.mapper.GenericMapper;

@Mapper(componentModel = "spring", unmappedTargetPolicy = ReportingPolicy.IGNORE)
public interface LayoutTypeManMapper extends GenericMapper<LayoutTypeUI, LayoutTypeEntity> {
	

	@Override
	@Mapping(source = "loutptrnname", target = "loutPtrnName")
	@Mapping(source = "loutptrndesc", target = "loutPtrnDesc")
	@Mapping(source = "msgloutcretnclsname", target = "msgLoutCretnClsName")
	LayoutTypeUI toVo(LayoutTypeEntity entity);

	@Override
	@InheritInverseConfiguration
	LayoutTypeEntity toEntity(LayoutTypeUI vo);

	@InheritInverseConfiguration
	@BeanMapping(nullValuePropertyMappingStrategy = NullValuePropertyMappingStrategy.IGNORE)
	void updateToEntity(LayoutTypeUI vo, @MappingTarget LayoutTypeEntity entity);
}
