public class HostedSuppressionsDataSource extends java.lang.Object implements CachedWebDataSource
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DEFAULT_SUPPRESSIONS_URL
The default URL to the Hosted Suppressions file.
|
Constructor and Description |
---|
HostedSuppressionsDataSource() |
Modifier and Type | Method and Description |
---|---|
boolean |
purge(Engine engine)
Deletes any locally cached data.
|
protected boolean |
shouldUpdate(java.io.File repo)
Determines if the we should update the Hosted Suppressions file.
|
boolean |
update(Engine engine)
Downloads the current Hosted suppressions file.
|
public static final java.lang.String DEFAULT_SUPPRESSIONS_URL
public boolean update(Engine engine) throws UpdateException
update
in interface CachedWebDataSource
engine
- a reference to the ODC EngineUpdateException
- thrown if the update encountered fatal errorsprotected boolean shouldUpdate(java.io.File repo) throws java.lang.NumberFormatException
repo
- the Hosted Suppressions file.true
if an update to the Hosted Suppressions file
should be performed; otherwise false
java.lang.NumberFormatException
- thrown if an invalid value is contained in
the database propertiespublic boolean purge(Engine engine)
CachedWebDataSource
purge
in interface CachedWebDataSource
engine
- a reference to the dependency-check enginetrue
if the purge was successful; otherwise
false
Copyright© 2012-21 Jeremy Long. All Rights Reserved.