public class Clover2Registry extends Object implements InstrumentationTarget
| Modifier and Type | Class and Description |
|---|---|
static class |
Clover2Registry.InstrumentationInfo
provides high level information about an instrumentation "session", where a session is defined as
a call to
startInstr(), zero or more instrumentation events
(e.g InstrumentationSessionImpl.enterFile(java.lang.String, java.io.File, int, int, long, long, long) etc), then a call to InstrumentationSessionImpl.finishAndApply() |
| Constructor and Description |
|---|
Clover2Registry(File regFile,
RegAccessMode accessMode,
String name) |
Clover2Registry(File regFile,
String name)
creates a fresh registry with no elements in it
|
public Clover2Registry(File regFile, String name)
regFile - the file that this registry will be written to when store() is calledname - the project name to associate with this registrypublic Clover2Registry(File regFile, RegAccessMode accessMode, String name)
public Clover2Registry copyForBackgroundCoverageLoad()
public static Clover2Registry fromInitString(String initstring, String name) throws CloverException
CloverExceptionpublic static Clover2Registry fromFile(File registryFile) throws CloverException
CloverExceptionpublic static Clover2Registry fromFile(File registryFile, HasMetricsFilter filter, ProgressListener progressListener) throws CloverException
CloverExceptionpublic static Clover2Registry createOrLoad(File registryFile, String projectName) throws IOException, CloverException
IOExceptionCloverExceptionpublic RegFile saveAndOverwriteFile() throws IOException, CloverRegistryException
IOExceptionCloverRegistryExceptionprotected RegFile saveAndOverwriteFile(FullProjectInfo project, List<Clover2Registry.InstrumentationInfo> instrumentationHistory, ContextStore contexts, CoverageData coverageData) throws IOException, CloverRegistryException
IOExceptionCloverRegistryExceptionpublic RegFile saveAndAppendToFile() throws IOException, CloverRegistryException
IOExceptionCloverRegistryExceptionpublic UpdatableRegFile applyAndAppendToFile(UpdatableRegFile regFile, InstrumentationSessionImpl.Update update) throws IOException, CloverRegistryException
IOExceptionCloverRegistryExceptionpublic RegistryUpdate applyUpdate(long expectedVersion, InstrumentationSessionImpl.Update update) throws ConcurrentInstrumentationException
applyUpdate in interface InstrumentationTargetConcurrentInstrumentationException - if another instrumentation session update
was applied between the start and application of the supplied instrumentation session
update.public ProjectView.Filtered newProjectView(HasMetricsFilter.Invertable filter)
public InstrumentationSession startInstr() throws CloverException
CloverExceptionpublic InstrumentationSession startInstr(String encoding) throws CloverException
CloverExceptionpublic boolean fileExists()
public boolean isOutOfDate()
public File getRegistryFile()
public String getProjectName()
public void setProjectName(String name)
public long getVersion()
public long getFirstVersion()
public void setVersion(long version)
public ProjectView.Original getModel()
public boolean isReadOnly()
public void setCoverageData(CoverageData data)
public CoverageData getCoverageData()
public int getDataLength()
public FullProjectInfo getProject()
public List getInstrHistory()
public ContextStore getContextStore()
public void setContextStore(ContextStore contexts)
public String getInitstring()
public long getPastInstrTimestamp(int numPastInstrs)
public void resolve(Path sourcePath)
Copyright © 2024 OpenClover.org. All rights reserved.