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.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/core/formats.h b/src/core/formats.h
index bc16f01..8857217 100644
--- a/src/core/formats.h
+++ b/src/core/formats.h
@@ -30,17 +30,22 @@
#include "../format/format.h"
+#include "../format/executable.h"
+
/* Indication à propos du support d'un format */
-typedef bool (* format_match_fc) (GBinContent *);
+typedef const char * (* format_match_fc) (GBinContent *, GExeFormat *);
/* Méthode de chargement d'un format */
-typedef GBinFormat * (* format_load_fc) (GBinContent *);
+typedef GBinFormat * (* format_load_fc) (GBinContent *, GExeFormat *);
+
+/* Enregistre un détection de format(s) binaire(s). */
+bool register_format_matcher(format_match_fc);
/* Enregistre un format de contenu binaire donné. */
-bool register_format_type(const char *, const char *, format_match_fc, format_load_fc);
+bool register_format_loader(const char *, const char *, format_load_fc);
/* Charge les définitions de formats "natifs". */
bool load_hard_coded_formats_definitions(void);
@@ -52,10 +57,10 @@ 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 *);
+const char *find_matching_format(GBinContent *, GExeFormat *);
/* Charge le format binaire correspondant à un type. */
-GBinFormat *load_new_named_format(const char *, GBinContent *);
+GBinFormat *load_new_named_format(const char *, GBinContent *, GExeFormat *);