public class CloverDatabase extends Object
Constructor and Description |
---|
CloverDatabase(Clover2Registry registry) |
CloverDatabase(File regFile,
boolean readOnly,
String name,
ContextSet contextFilter,
CoverageDataSpec spec)
Constructs a new database with an empty registry
|
CloverDatabase(String initstring) |
CloverDatabase(String initstring,
HasMetricsFilter includeFilter,
String name) |
CloverDatabase(String initstring,
HasMetricsFilter includeFilter,
String name,
String filterSpec) |
CloverDatabase(String initstring,
HasMetricsFilter includeFilter,
String name,
String filterSpec,
ProgressListener progressListener)
create a new instance
|
public CloverDatabase(String initstring) throws CloverException
CloverException
public CloverDatabase(String initstring, HasMetricsFilter includeFilter, String name) throws CloverException
CloverException
public CloverDatabase(String initstring, HasMetricsFilter includeFilter, String name, String filterSpec) throws CloverException
CloverException
public CloverDatabase(String initstring, HasMetricsFilter includeFilter, String name, String filterSpec, ProgressListener progressListener) throws CloverException
initstring
- the location of the database to loadincludeFilter
- a filter that is applied to the loading of the registry. It controls what elements are visible to the databasename
- an alternative name for the modelfilterSpec
- the filter to use when excluding metricsprogressListener
- progress listenerCloverException
- if something goes wrong.public CloverDatabase(File regFile, boolean readOnly, String name, ContextSet contextFilter, CoverageDataSpec spec)
public CloverDatabase(Clover2Registry registry)
public CloverDatabase copyForBackgroundCoverageDataLoad()
public CoverageData loadCoverageData() throws CloverException
CloverException
public CoverageData loadCoverageData(CoverageDataSpec spec) throws CloverException
CloverException
public CoverageData loadCoverageData(CoverageDataSpec spec, ProgressListener progressListener) throws CloverException
CloverException
public String getInitstring()
public String getName()
public FullProjectInfo getModel(CodeType codeType)
public FullProjectInfo getTestOnlyModel()
public FullProjectInfo getAppOnlyModel()
public FullProjectInfo getFullModel()
public boolean isOutOfDate()
public boolean isRegistryOutOfDate()
public boolean isCoverageOutOfDate()
public boolean isRecordingInProgress()
public static boolean isRecordingInProgress(File pathToRegistry)
public void resolve(Path sourcePath)
public ContextSet getContextSet(String spec)
public Set<TestCaseInfo> getTestHits(CoverageDataRange range)
CoverageDataProvider
public Map<TestCaseInfo,BitSet> mapTestsAndCoverageForFile(FullFileInfo fileInfo)
public Clover2Registry getRegistry()
public ContextStore getContextStore()
public CoverageData getCoverageData()
public TestCaseInfo getTestCase(int id)
public boolean hasCoverage()
public long getRecordingTimestamp()
public static CloverDatabase loadWithCoverage(String initString, CoverageDataSpec spec) throws CloverException
CloverException
public static void merge(List<CloverDatabaseSpec> dbspecs, String initString) throws CloverException, IOException
CloverException
IOException
public static void merge(List<CloverDatabaseSpec> dbspecs, String initString, ProgressListener listener) throws CloverException, IOException
CloverException
IOException
public static void merge(List<CloverDatabaseSpec> dbspecs, String initString, boolean update, Interval updateSpan, ProgressListener listener) throws CloverException, IOException
dbspecs
- list of databases to mergeinitString
- destination database. If this exists and update is set to true, will be mergedupdate
- if true, merge any existing database at initStringupdateSpan
- if update is true, the span to use when merging any existing databaselistener
- gets progress callbacksCloverException
IOException
Copyright © 2023 OpenClover.org. All rights reserved.