package com.qsoft.rs.sincoar.dominio.mapper;

import com.qsoft.rs.sincoar.dto.TcustpeoplePKDTO;
import com.qsoft.rs.sincoar.model.TcustpeoplePK;
import javax.annotation.processing.Generated;

@Generated(
    value = "org.mapstruct.ap.MappingProcessor",
    date = "2022-09-02T16:14:47-0500",
    comments = "version: 1.5.2.Final, compiler: javac, environment: Java 17.0.4 (Private Build)"
)
public class TcustpeoplePKMapperImpl implements TcustpeoplePKMapper {

    @Override
    public TcustpeoplePK getEntidad(TcustpeoplePKDTO tcustpeoplePK) {
        if ( tcustpeoplePK == null ) {
            return null;
        }

        TcustpeoplePK tcustpeoplePK1 = new TcustpeoplePK();

        if ( tcustpeoplePK.getPersoncode() != null ) {
            tcustpeoplePK1.setPersoncode( tcustpeoplePK.getPersoncode() );
        }
        tcustpeoplePK1.setDateto( tcustpeoplePK.getDateto() );

        return tcustpeoplePK1;
    }

    @Override
    public TcustpeoplePKDTO getDto(TcustpeoplePK tcustpeoplePK) {
        if ( tcustpeoplePK == null ) {
            return null;
        }

        TcustpeoplePKDTO tcustpeoplePKDTO = new TcustpeoplePKDTO();

        tcustpeoplePKDTO.setPersoncode( (int) tcustpeoplePK.getPersoncode() );
        tcustpeoplePKDTO.setDateto( tcustpeoplePK.getDateto() );

        return tcustpeoplePKDTO;
    }
}
