Search in sources :

Example 11 with CompletionStatus

use of org.jboss.pnc.spi.coordinator.CompletionStatus in project pnc by project-ncl.

the class RepositoryManagerResultMapper method toDTO.

public RepositoryManagerResultRest toDTO(RepositoryManagerResult entity) {
    List<Artifact> builtArtifacts = entity.getBuiltArtifacts().stream().map(artifact -> artifactMapper.toDTO(artifact)).collect(Collectors.toList());
    List<Artifact> dependencies = entity.getDependencies().stream().map(artifact -> artifactMapper.toDTO(artifact)).collect(Collectors.toList());
    String buildContentId = entity.getBuildContentId();
    String log = entity.getLog();
    CompletionStatus completionStatus = entity.getCompletionStatus();
    return new RepositoryManagerResultRest(builtArtifacts, dependencies, buildContentId, log, completionStatus);
}
Also used : Inject(javax.inject.Inject) GenericRepositoryManagerResult(org.jboss.pnc.bpm.model.RepositoryManagerResultRest.GenericRepositoryManagerResult) List(java.util.List) RepositoryManagerResult(org.jboss.pnc.spi.repositorymanager.RepositoryManagerResult) RepositoryManagerResultRest(org.jboss.pnc.bpm.model.RepositoryManagerResultRest) CompletionStatus(org.jboss.pnc.spi.coordinator.CompletionStatus) ApplicationScoped(javax.enterprise.context.ApplicationScoped) Artifact(org.jboss.pnc.dto.Artifact) ArtifactMapper(org.jboss.pnc.mapper.api.ArtifactMapper) Collectors(java.util.stream.Collectors) RepositoryManagerResultRest(org.jboss.pnc.bpm.model.RepositoryManagerResultRest) CompletionStatus(org.jboss.pnc.spi.coordinator.CompletionStatus) Artifact(org.jboss.pnc.dto.Artifact)

Aggregations

CompletionStatus (org.jboss.pnc.spi.coordinator.CompletionStatus)11 RepositoryManagerResult (org.jboss.pnc.spi.repositorymanager.RepositoryManagerResult)6 ProcessException (org.jboss.pnc.spi.coordinator.ProcessException)5 EnvironmentDriverResult (org.jboss.pnc.spi.environment.EnvironmentDriverResult)4 List (java.util.List)3 RepositoryManagerResultRest (org.jboss.pnc.bpm.model.RepositoryManagerResultRest)3 BuildRecord (org.jboss.pnc.model.BuildRecord)3 Collectors (java.util.stream.Collectors)2 ApplicationScoped (javax.enterprise.context.ApplicationScoped)2 Inject (javax.inject.Inject)2 BuildCoordinationException (org.jboss.pnc.coordinator.BuildCoordinationException)2 BuildStatus (org.jboss.pnc.enums.BuildStatus)2 BuildResult (org.jboss.pnc.spi.BuildResult)2 BuildDriverResult (org.jboss.pnc.spi.builddriver.BuildDriverResult)2 BuildExecutionConfiguration (org.jboss.pnc.spi.executor.BuildExecutionConfiguration)2 ExecutorException (org.jboss.pnc.spi.executor.exceptions.ExecutorException)2 RepourResult (org.jboss.pnc.spi.repour.RepourResult)2 MalformedPackageURLException (com.github.packageurl.MalformedPackageURLException)1 PackageURL (com.github.packageurl.PackageURL)1 PackageURLBuilder (com.github.packageurl.PackageURLBuilder)1