X-Git-Url: https://git.efficios.com/?a=blobdiff_plain;f=include%2Fbabeltrace2%2Fbabeltrace.h;h=3f919cf30a6ea65f29caf4b5de8fa6ac30d485e1;hb=7704a0af9f2275321f8294df8c02f8a299b3134e;hp=290b47a0fbf9380857d6200701dffa583b7edd44;hpb=c0e90f239beea3a5beca6fd07bd5ca51e7976b31;p=babeltrace.git
diff --git a/include/babeltrace2/babeltrace.h b/include/babeltrace2/babeltrace.h
index 290b47a0..3f919cf3 100644
--- a/include/babeltrace2/babeltrace.h
+++ b/include/babeltrace2/babeltrace.h
@@ -1,10 +1,8 @@
-#ifndef BABELTRACE_BABELTRACE_H
-#define BABELTRACE_BABELTRACE_H
+#ifndef BABELTRACE2_BABELTRACE_H
+#define BABELTRACE2_BABELTRACE_H
/*
- * Babeltrace API
- *
- * Copyright 2010-2018 EfficiOS Inc.
+ * Copyright (c) 2010-2019 EfficiOS Inc. and Linux Foundation
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
@@ -25,104 +23,85 @@
* SOFTWARE.
*/
-/* Core API */
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
+/*
+ * Tell the specific headers that they are included from this header.
+ *
+ * Do NOT define `__BT_IN_BABELTRACE_H` in user code.
+ */
+#ifndef __BT_IN_BABELTRACE_H
+# define __BT_IN_BABELTRACE_H
+#endif
-/* Trace IR API */
-#include
+/* Internal: needed by some of the following included headers */
+#include
+
+/* Internal: needed by some of the following included headers */
+#ifdef __cplusplus
+# define __BT_UPCAST(_type, _p) static_cast<_type *>(static_cast(_p))
+# define __BT_UPCAST_CONST(_type, _p) static_cast(static_cast(_p))
+#else
+# define __BT_UPCAST(_type, _p) ((_type *) (_p))
+# define __BT_UPCAST_CONST(_type, _p) ((const _type *) (_p))
+#endif
+
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
#include
-#include
-#include
+#include
#include
-#include
#include
-#include
#include
-#include
-#include
+#include
#include
-#include
-#include
#include
-#include
#include
-#include
#include
-#include
#include
-#include
#include
+#include
+#include
+#include
+#include
-/* Plugin and plugin development API */
-#include
-#include
-#include
-
-/* Graph, component, and message API */
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
-#include
+/* Cancel private definitions */
+#undef __BT_FUNC_STATUS_AGAIN
+#undef __BT_FUNC_STATUS_END
+#undef __BT_FUNC_STATUS_ERROR
+#undef __BT_FUNC_STATUS_INTERRUPTED
+#undef __BT_FUNC_STATUS_UNKNOWN_OBJECT
+#undef __BT_FUNC_STATUS_MEMORY_ERROR
+#undef __BT_FUNC_STATUS_NOT_FOUND
+#undef __BT_FUNC_STATUS_OK
+#undef __BT_FUNC_STATUS_OVERFLOW_ERROR
+#undef __BT_FUNC_STATUS_USER_ERROR
+#undef __BT_IN_BABELTRACE_H
+#undef __BT_UPCAST
+#undef __BT_UPCAST_CONST
+#undef __BT_LOGGING_LEVEL_TRACE
+#undef __BT_LOGGING_LEVEL_DEBUG
+#undef __BT_LOGGING_LEVEL_INFO
+#undef __BT_LOGGING_LEVEL_WARNING
+#undef __BT_LOGGING_LEVEL_ERROR
+#undef __BT_LOGGING_LEVEL_FATAL
+#undef __BT_LOGGING_LEVEL_NONE
-#endif /* BABELTRACE_BABELTRACE_H */
+#endif /* BABELTRACE2_BABELTRACE_H */