summaryrefslogtreecommitdiff
path: root/src/analysis/db/item-int.h
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2014-08-18 21:55:24 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2014-08-18 21:55:24 (GMT)
commita0a7b6c1e05c78ae433f353d15e3366107b67d03 (patch)
treebca0b187778cf016c6131bfc982b08c67a38442b /src/analysis/db/item-int.h
parent161c0f8ab227af5033b1b6456607b9b9c3bc60df (diff)
Inserted storages and collections into loaded binaries (first steps).
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@389 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src/analysis/db/item-int.h')
-rw-r--r--src/analysis/db/item-int.h68
1 files changed, 68 insertions, 0 deletions
diff --git a/src/analysis/db/item-int.h b/src/analysis/db/item-int.h
new file mode 100644
index 0000000..b6d8f9c
--- /dev/null
+++ b/src/analysis/db/item-int.h
@@ -0,0 +1,68 @@
+
+/* Chrysalide - Outil d'analyse de fichiers binaires
+ * item-int.h - prototypes et définitions internes pour les bases d'éléments de collection
+ *
+ * Copyright (C) 2014 Cyrille Bagard
+ *
+ * This file is part of Chrysalide.
+ *
+ * OpenIDA is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * OpenIDA is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with Foobar. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+
+#ifndef _ANALYSIS_DB_ITEM_INT_H
+#define _ANALYSIS_DB_ITEM_INT_H
+
+
+#include "item.h"
+
+
+#include <stdint.h>
+
+
+
+/* Importe la définition d'une base d'éléments pour collection. */
+typedef bool (* recv_db_item_fc) (GDbItem *, int, int);
+
+/* Exporte la définition d'une base d'éléments pour collection. */
+typedef bool (* send_db_item_fc) (const GDbItem *, int, int);
+
+
+/* Base d'un élément pour collection générique (instance) */
+struct _GDbItem
+{
+ GObject parent; /* A laisser en premier */
+
+ uint64_t created; /* Date de création */
+ uint64_t modified; /* Date de modification */
+
+ bool is_volatile; /* Pas besoin de sauvegarde ? */
+
+};
+
+/* Base d'un élément pour collection générique (classe) */
+struct _GDbItemClass
+{
+ GObjectClass parent; /* A laisser en premier */
+
+ GCompareFunc cmp; /* Comparaison entre éléments */
+
+ recv_db_item_fc recv; /* Réception depuis le réseau */
+ send_db_item_fc send; /* Emission depuis le réseau */
+
+};
+
+
+
+#endif /* _ANALYSIS_DB_ITEM_INT_H */