AttachmentFileInfoMapperImpl.java

package com.wilzwert.myjobs.infrastructure.mapper;

import com.wilzwert.myjobs.core.domain.model.AttachmentFileInfo;
import com.wilzwert.myjobs.infrastructure.api.rest.dto.ProtectedFileResponse;
import javax.annotation.processing.Generated;
import org.springframework.stereotype.Component;

@Generated(
    value = "org.mapstruct.ap.MappingProcessor",
    date = "2025-06-18T09:42:43+0000",
    comments = "version: 1.6.2, compiler: javac, environment: Java 21.0.7 (Eclipse Adoptium)"
)
@Component
public class AttachmentFileInfoMapperImpl implements AttachmentFileInfoMapper {

    @Override
    public ProtectedFileResponse toResponse(AttachmentFileInfo attachmentFileInfo) {
        if ( attachmentFileInfo == null ) {
            return null;
        }

        ProtectedFileResponse protectedFileResponse = new ProtectedFileResponse();

        protectedFileResponse.setFileId( attachmentFileInfo.fileId() );
        protectedFileResponse.setUrl( attachmentFileInfo.url() );

        return protectedFileResponse;
    }
}