Class Dependency
java.lang.Object
com.vaadin.appsec.backend.model.dto.Dependency
- All Implemented Interfaces:
Serializable
DTO for a dependency instance, used in the UI.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDependency(@NotNull Ecosystem ecosystem, String group, @NotNull String name, @NotNull String version) Instantiates a new Dependency dto. -
Method Summary
Modifier and TypeMethodDescriptionbooleanGets CVSS string.Gets the dependency ecosystem.getGroup()Gets group.getName()Gets name.Gets num of vulnerabilities.Gets parent dependency's BOM reference (purl).Gets risk score.Gets severity level.Gets version.inthashCode()booleanShows if a npm dependency is a dev dependency.voidsetCvssString(String cvssString) Sets CVSS string.voidsetDevDependency(boolean devDependency) Sets the npm dev dependency.voidsetEcosystem(Ecosystem ecosystem) Sets the dependency ecosystem.voidSets group.voidSets name.voidsetNumOfVulnerabilities(Integer numOfVulnerabilities) Sets num of vulnerabilities.voidsetParentBomRef(String parentBomRef) Sets parent dependency's BOM reference (purl).voidsetRiskScore(Double riskScore) Sets risk score.voidsetSeverityLevel(SeverityLevel severityLevel) Sets severity level.voidsetVersion(String version) Sets version.toString()
-
Constructor Details
-
Method Details
-
getEcosystem
Gets the dependency ecosystem.- Returns:
- the ecosystem
-
setEcosystem
Sets the dependency ecosystem.- Parameters:
ecosystem- the ecosystem
-
getGroup
Gets group.- Returns:
- the group
-
setGroup
Sets group.- Parameters:
group- the group
-
getName
Gets name.- Returns:
- the name
-
setName
Sets name.- Parameters:
name- the name
-
getVersion
Gets version.- Returns:
- the version
-
setVersion
Sets version.- Parameters:
version- the version
-
getParentBomRef
Gets parent dependency's BOM reference (purl).- Returns:
- the parent dependency's BOM reference (purl)
-
setParentBomRef
Sets parent dependency's BOM reference (purl).- Parameters:
parentBomRef- the parent dependency's BOM reference (purl)
-
getNumOfVulnerabilities
Gets num of vulnerabilities.- Returns:
- the num of vulnerabilities
-
setNumOfVulnerabilities
Sets num of vulnerabilities.- Parameters:
numOfVulnerabilities- the num of vulnerabilities
-
getSeverityLevel
Gets severity level.- Returns:
- the severity level
-
setSeverityLevel
Sets severity level.- Parameters:
severityLevel- the severity level
-
getRiskScore
Gets risk score.- Returns:
- the risk score
-
setRiskScore
Sets risk score.- Parameters:
riskScore- the risk score
-
getCvssString
Gets CVSS string.- Returns:
- the CVSS string
-
setCvssString
Sets CVSS string.- Parameters:
cvssString- the CVSS string
-
isDevDependency
public boolean isDevDependency()Shows if a npm dependency is a dev dependency. For the Maven dependencies this is always false.- Returns:
- true if the npm dependency is a dev dependency, otherwise false
-
setDevDependency
public void setDevDependency(boolean devDependency) Sets the npm dev dependency. For the Maven dependencies this should be set to false.- Parameters:
devDependency- the npm dev dependency
-
equals
-
hashCode
public int hashCode() -
toString
-