-
Notifications
You must be signed in to change notification settings - Fork 15
API
The two main classes of the flacoco API are Flacoco and FlacocoAPI.
This class serves as the main entry point of flacoco. Currently, it supports two output formats:
The default mode returns a mapping between a string representation of a source code line (e.g. fr/spoonlabs/FLtest1/Calculator@-@14, where fr.spoonlabs.FLtest1.Calculator is the fully-qualified class name and 14 is the line number), and a suspiciousness score.
Flacoco flacoco = new Flacoco();
Map<String, Double> resultDefault = flacoco.runDefault();The Spoon mode returns a mapping between a CtStatement. More information on how source code lines are mapped to CtStatements can be found under SpoonConverter.
Flacoco flacoco = new Flacoco();
Map<CtStatement, Double> resultSpoon = flacoco.runSpoon();This class serves as the configuration manager of the flacoco API. Through it, you can set all the options that will be used during the execution of flacoco. A comprehensive list of options will be provided soon in this page.