2 * SPDX-License-Identifier: MIT
4 * Copyright (C) 2010-2019 EfficiOS Inc. and Linux Foundation
7 #ifndef BABELTRACE2_GRAPH_PRIVATE_QUERY_EXECUTOR_H
8 #define BABELTRACE2_GRAPH_PRIVATE_QUERY_EXECUTOR_H
10 #ifndef __BT_IN_BABELTRACE_H
11 # error "Please include <babeltrace2/babeltrace.h> instead."
14 #include <babeltrace2/types.h>
21 @defgroup api-priv-qexec Private query executor
22 @ingroup api-comp-cls-dev
25 Private view of a \bt_qexec for a \bt_comp_cls
26 \ref api-comp-cls-dev-meth-query "query method".
28 A <strong><em>private query executor</em></strong> is a private view,
29 from within a \bt_comp_cls
30 \ref api-comp-cls-dev-meth-query "query method", of a
33 A query method receives a private query executor as its
34 \bt_p{query_executor} parameter.
36 As of \bt_name_version_min_maj, this module only offers the
37 bt_private_query_executor_as_query_executor_const() function to
38 \ref api-fund-c-typing "upcast" a private query executor to a
39 \c const query executor. You need this to get the query executor's
40 \ref api-qexec-prop-log-lvl "logging level".
49 @typedef struct bt_private_query_executor bt_private_query_executor;
52 Private query executor.
64 \ref api-fund-c-typing "Upcasts" the private query executor
65 \bt_p{query_executor} to the public #bt_query_executor type.
67 @param[in] query_executor
69 Private query executor to upcast.
75 \bt_p{query_executor} as a public query executor.
78 const bt_query_executor
*
79 bt_private_query_executor_as_query_executor_const(
80 bt_private_query_executor
*query_executor
)
82 return __BT_UPCAST_CONST(bt_query_executor
, query_executor
);
93 #endif /* BABELTRACE2_GRAPH_PRIVATE_QUERY_EXECUTOR_H */