All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.codemodder.DefaultDependencyUpdateResult Maven / Gradle / Ivy

package io.codemodder;

import io.codemodder.codetf.CodeTFChangesetEntry;
import java.nio.file.Path;
import java.util.List;
import java.util.Objects;
import java.util.Set;

final class DefaultDependencyUpdateResult implements DependencyUpdateResult {

  private final List injectedDependencies;
  private final List skippedDependencies;
  private final List updatedChanges;
  private final Set erroredFiles;

  DefaultDependencyUpdateResult(
      final List injectedDependencies,
      final List skippedDependencies,
      final List updatedChanges,
      final Set erroredFiles) {
    this.injectedDependencies = Objects.requireNonNull(injectedDependencies);
    this.skippedDependencies = Objects.requireNonNull(skippedDependencies);
    this.updatedChanges = Objects.requireNonNull(updatedChanges);
    this.erroredFiles = Objects.requireNonNull(erroredFiles);
  }

  @Override
  public List injectedPackages() {
    return injectedDependencies;
  }

  @Override
  public List skippedPackages() {
    return skippedDependencies;
  }

  @Override
  public List packageChanges() {
    return updatedChanges;
  }

  @Override
  public Set erroredFiles() {
    return erroredFiles;
  }

  @Override
  public String toString() {
    return "DefaultDependencyUpdateResult{"
        + "injectedDependencies="
        + injectedDependencies
        + ", skippedDependencies="
        + skippedDependencies
        + ", updatedChanges="
        + updatedChanges
        + ", erroredFiles="
        + erroredFiles
        + '}';
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy