Class NvdApiProcessor
- java.lang.Object
-
- org.owasp.dependencycheck.data.update.nvd.api.NvdApiProcessor
-
- All Implemented Interfaces:
java.util.concurrent.Callable<NvdApiProcessor>
public class NvdApiProcessor extends java.lang.Object implements java.util.concurrent.Callable<NvdApiProcessor>
Stores a collection of NVD CVE Data from the NVD API into the database.- Author:
- Jeremy Long
-
-
Constructor Summary
Constructors Constructor Description NvdApiProcessor(CveDB cveDB, java.io.File jsonFile)Create a new processor to put the NVD data into the database.NvdApiProcessor(CveDB cveDB, java.io.File jsonFile, long startTime)Create a new processor to put the NVD data into the database.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NvdApiProcessorcall()longgetDurationMillis()Calculates how long the update process took.
-
-
-
Constructor Detail
-
NvdApiProcessor
public NvdApiProcessor(CveDB cveDB, java.io.File jsonFile, long startTime)
Create a new processor to put the NVD data into the database.- Parameters:
cveDB- a reference to the database.jsonFile- the JSON data file to inject.startTime- the start time of the update process.
-
NvdApiProcessor
public NvdApiProcessor(CveDB cveDB, java.io.File jsonFile)
Create a new processor to put the NVD data into the database.- Parameters:
cveDB- a reference to the databasejsonFile- the JSON data file to inject.
-
-
Method Detail
-
call
public NvdApiProcessor call() throws java.lang.Exception
- Specified by:
callin interfacejava.util.concurrent.Callable<NvdApiProcessor>- Throws:
java.lang.Exception
-
getDurationMillis
public long getDurationMillis()
Calculates how long the update process took.- Returns:
- the number of milliseconds that the update process took
-
-