• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4 
5 #ifndef SANDBOX_LINUX_BPF_DSL_BPF_DSL_FORWARD_H_
6 #define SANDBOX_LINUX_BPF_DSL_BPF_DSL_FORWARD_H_
7 
8 #include <memory>
9 
10 #include "sandbox/sandbox_export.h"
11 
12 namespace sandbox {
13 namespace bpf_dsl {
14 
15 // The bpf_dsl_forward.h header provides forward declarations for the
16 // types defined in bpf_dsl.h. It's intended for use in user headers
17 // that need to reference bpf_dsl types, but don't require definitions.
18 
19 namespace internal {
20 class ResultExprImpl;
21 class BoolExprImpl;
22 }
23 
24 using ResultExpr = std::shared_ptr<const internal::ResultExprImpl>;
25 using BoolExpr = std::shared_ptr<const internal::BoolExprImpl>;
26 
27 template <typename T>
28 class Arg;
29 
30 class Elser;
31 
32 template <typename T>
33 class Caser;
34 
35 }  // namespace bpf_dsl
36 }  // namespace sandbox
37 
38 namespace std {
39 extern template class SANDBOX_EXPORT
40     shared_ptr<const sandbox::bpf_dsl::internal::BoolExprImpl>;
41 extern template class SANDBOX_EXPORT
42     shared_ptr<const sandbox::bpf_dsl::internal::ResultExprImpl>;
43 }  // namespace std
44 
45 #endif  // SANDBOX_LINUX_BPF_DSL_BPF_DSL_FORWARD_H_
46