summaryrefslogtreecommitdiff
path: root/src/core/formats.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/formats.h')
-rw-r--r--src/core/formats.h20
1 files changed, 16 insertions, 4 deletions
diff --git a/src/core/formats.h b/src/core/formats.h
index 8857217..76b57d0 100644
--- a/src/core/formats.h
+++ b/src/core/formats.h
@@ -34,15 +34,27 @@
+/* Conclusion d'une opération de reconnaissance */
+typedef enum _FormatMatchStatus
+{
+ FMS_MATCHED, /* Correspondance établie */
+ FMS_FORWARDED, /* Sous-formats détectés */
+ FMS_UNKNOWN, /* Aucun format reconnu */
+
+ FMS_COUNT
+
+} FormatMatchStatus;
+
+
/* Indication à propos du support d'un format */
-typedef const char * (* format_match_fc) (GBinContent *, GExeFormat *);
+typedef FormatMatchStatus (* format_match_fc) (GBinContent *, GExeFormat *, void *, char **);
/* Méthode de chargement d'un format */
typedef GBinFormat * (* format_load_fc) (GBinContent *, GExeFormat *);
/* Enregistre un détection de format(s) binaire(s). */
-bool register_format_matcher(format_match_fc);
+bool register_format_matcher(format_match_fc, void *);
/* Enregistre un format de contenu binaire donné. */
bool register_format_loader(const char *, const char *, format_load_fc);
@@ -57,11 +69,11 @@ void unload_formats_definitions(void);
const char *get_binary_format_name(const char *);
/* Identifie un format binaire par son contenu. */
-const char *find_matching_format(GBinContent *, GExeFormat *);
+FormatMatchStatus find_matching_format(GBinContent *, GExeFormat *, char **);
/* Charge le format binaire correspondant à un type. */
GBinFormat *load_new_named_format(const char *, GBinContent *, GExeFormat *);
-#endif /* _ANALYSIS_DB_COLLECTION_H */
+#endif /* _CORE_FORMATS_H */