From f7e6b1927f00631b1a2bf59e597ea4640dbddb31 Mon Sep 17 00:00:00 2001 From: Anthony Liguori Date: Wed, 11 Nov 2009 10:37:39 -0600 Subject: Add a QBool type Signed-off-by: Anthony Liguori --- qbool.h | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 qbool.h (limited to 'qbool.h') diff --git a/qbool.h b/qbool.h new file mode 100644 index 0000000..fe66fcd --- /dev/null +++ b/qbool.h @@ -0,0 +1,29 @@ +/* + * QBool Module + * + * Copyright IBM, Corp. 2009 + * + * Authors: + * Anthony Liguori + * + * This work is licensed under the terms of the GNU LGPL, version 2.1 or later. + * See the COPYING.LIB file in the top-level directory. + * + */ + +#ifndef QBOOL_H +#define QBOOL_H + +#include +#include "qobject.h" + +typedef struct QBool { + QObject_HEAD; + int value; +} QBool; + +QBool *qbool_from_int(int value); +int qbool_get_int(const QBool *qb); +QBool *qobject_to_qbool(const QObject *obj); + +#endif /* QBOOL_H */ -- cgit v1.1