private final VariableRegistry _variableRegistry;
private final FormatterRegistry _formatterRegistry;
@SuppressWarnings("unchecked")
private Snitch(Configuration config) throws Exception {
AnnotationScanner annotationScanner;
List<String> packagesToScan = config.getPackagesToScan();
if (packagesToScan != null && !packagesToScan.isEmpty()) {
String[] packages = packagesToScan.toArray(new String[packagesToScan.size()]);
annotationScanner = new ClassPathAnnotationScanner(packages);
} else {