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

org.whitesource.agent.via.api.VulnerabilityTrace Maven / Gradle / Ivy

package org.whitesource.agent.via.api;

import java.io.Serializable;
import java.util.LinkedList;
import java.util.List;
import java.util.Objects;

/**
 * Vulnerability sorted trace record, according to it's code invocations
 *
 * @author artiom.petrov
 */
public class VulnerabilityTrace implements Serializable {

    /* --- Static members --- */

    private static final long serialVersionUID = 8254336454781349191L;

    /* --- Members --- */

    private List codeInvocations;

    /* --- Constructor --- */

    public VulnerabilityTrace() {
        codeInvocations = new LinkedList<>();
    }

    /* --- Overridden methods --- */

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof VulnerabilityTrace)) return false;
        VulnerabilityTrace that = (VulnerabilityTrace) o;
        return Objects.equals(codeInvocations, that.codeInvocations);
    }

    @Override
    public int hashCode() {
        return Objects.hash(codeInvocations);
    }

    /* --- Getters / Setters --- */

    public List getCodeInvocations() {
        return codeInvocations;
    }

    public void setCodeInvocations(List codeInvocations) {
        this.codeInvocations = codeInvocations;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy