com.chutneytesting.design.api.campaign.dto.ScenarioExecutionReportCampaignMapper Maven / Gradle / Ivy
package com.chutneytesting.design.api.campaign.dto;
import static com.chutneytesting.tools.ui.ComposableIdUtils.fromFrontId;
import static com.chutneytesting.tools.ui.ComposableIdUtils.toFrontId;
import static java.util.Optional.of;
import com.chutneytesting.design.domain.campaign.ScenarioExecutionReportCampaign;
public class ScenarioExecutionReportCampaignMapper {
public static ScenarioExecutionReportOutlineDto toDto(ScenarioExecutionReportCampaign scenarioReport) {
return new ScenarioExecutionReportOutlineDto(
toFrontId(scenarioReport.scenarioId),
scenarioReport.scenarioName,
scenarioReport.execution
);
}
public static ScenarioExecutionReportCampaign fromDto(ScenarioExecutionReportOutlineDto dto) {
return new ScenarioExecutionReportCampaign(
fromFrontId(of(dto.getScenarioId())),
dto.getScenarioName(),
dto.getExecution()
);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy