Fix: file-descriptor: missing include guards
[lttng-tools.git] / src / bin / lttng-sessiond / stream-class.cpp
1 /*
2 * Copyright (C) 2022 Jérémie Galarneau <jeremie.galarneau@efficios.com>
3 *
4 * SPDX-License-Identifier: GPL-2.0-only
5 *
6 */
7
8 #include "stream-class.hpp"
9 #include "trace-class.hpp"
10
11 namespace lst = lttng::sessiond::trace;
12
13 lttng::sessiond::trace::stream_class::stream_class(
14 unsigned int in_id,
15 enum header_type in_header_type,
16 nonstd::optional<std::string> in_default_clock_class_name) :
17 id{ in_id },
18 header_type_{ in_header_type },
19 default_clock_class_name{ std::move(in_default_clock_class_name) }
20 {
21 }
22
23 void lst::stream_class::accept(trace_class_visitor& visitor) const
24 {
25 visitor.visit(*this);
26 _accept_on_event_classes(visitor);
27 }
28
29 const lttng::sessiond::trace::type *lst::stream_class::packet_context() const
30 {
31 return _packet_context.get();
32 }
33
34 const lttng::sessiond::trace::type *lst::stream_class::event_header() const
35 {
36 return _event_header.get();
37 }
38
39 const lttng::sessiond::trace::type *lst::stream_class::event_context() const
40 {
41 return _event_context.get();
42 }
This page took 0.034324 seconds and 4 git commands to generate.