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

hudson.plugins.git.GitChangeSetList Maven / Gradle / Ivy

package hudson.plugins.git;

import hudson.scm.ChangeLogSet;
import hudson.model.AbstractBuild;

import java.util.List;
import java.util.Collections;
import java.util.Iterator;

/**
 * List of changeset that went into a particular build.
 * @author Nigel Magnay
 */
public class GitChangeSetList extends ChangeLogSet {
    private final List changeSets;

    /*package*/ GitChangeSetList(AbstractBuild build, List logs) {
        super(build);
        Collections.reverse(logs);  // put new things first
        this.changeSets = Collections.unmodifiableList(logs);
        for (GitChangeSet log : logs)
            log.setParent(this);
    }

    public boolean isEmptySet() {
        return changeSets.isEmpty();
    }

    public Iterator iterator() {
        return changeSets.iterator();
    }

    public List getLogs() {
        return changeSets;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy