import org.scannotation.AnnotationDB;
import java.io.IOException;
import java.util.Map;
public class ScannotationExample {
public static void main(String[] args) throws IOException {
AnnotationDB db = new AnnotationDB();
Map<String, Map<String, Object>> index = db.getAnnotationIndex();
for (Map.Entry<String, Map<String, Object>> entry : index.entrySet()) {
String className = entry.getKey();
Map<String, Object> classAnnotations = entry.getValue();
System.out.println("Class: " + className);
for (Map.Entry<String, Object> annotationEntry : classAnnotations.entrySet()) {
String annotationName = annotationEntry.getKey();
Object annotationData = annotationEntry.getValue();
System.out.println(" Annotation: " + annotationName);
System.out.println(" Data: " + annotationData);
}
}
}
}