Class IndexEntry
java.lang.Object
org.owasp.dependencycheck.data.cpe.IndexEntry
- All Implemented Interfaces:
Serializable
A CPE entry containing the name, vendor, product, and version.
- Author:
- Jeremy Long
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanintGet the value of documentId.Get the value of product.floatGet the value of searchScore.Get the value of vendor.inthashCode()voidParses a name attribute value, from the cpe.xml, into its corresponding parts: vendor, product.voidsetDocumentId(int documentId) Set the value of documentId.voidsetProduct(String product) Set the value of product.voidsetSearchScore(float searchScore) Set the value of searchScore.voidSet the value of vendor.toString()Standard implementation of toString showing vendor and product.
-
Constructor Details
-
IndexEntry
public IndexEntry()
-
-
Method Details
-
getDocumentId
public int getDocumentId()Get the value of documentId.- Returns:
- the value of documentId
-
setDocumentId
public void setDocumentId(int documentId) Set the value of documentId.- Parameters:
documentId- new value of documentId
-
getVendor
-
setVendor
Set the value of vendor.- Parameters:
vendor- new value of vendor
-
getProduct
-
setProduct
Set the value of product.- Parameters:
product- new value of product
-
getSearchScore
public float getSearchScore()Get the value of searchScore.- Returns:
- the value of searchScore
-
setSearchScore
public void setSearchScore(float searchScore) Set the value of searchScore.- Parameters:
searchScore- new value of searchScore
-
parseName
Parses a name attribute value, from the cpe.xml, into its corresponding parts: vendor, product.
Example:
nbsp;nbsp;nbsp;cpe:/a:apache:struts:1.1:rc2Results in:
- Vendor: apache
- Product: struts
If it is necessary to parse the CPE into more parts (i.e. to include version and revision) then you should use the `cpe-parser`.
- Parameters:
cpeName- the CPE name
-
hashCode
-
equals
-
toString
-