cc_tools_qt
Common Environment for Protocol Analysis.
Loading...
Searching...
No Matches
include
cc_tools_qt
ToolsDataInfo.h
1
//
2
// Copyright 2014 - 2026 (C). Alex Robenko. All rights reserved.
3
//
4
// SPDX-License-Identifier: GPL-3.0-or-later
5
//
6
7
// This file is free software: you can redistribute it and/or modify
8
// it under the terms of the GNU General Public License as published by
9
// the Free Software Foundation, either version 3 of the License, or
10
// (at your option) any later version.
11
//
12
// This program is distributed in the hope that it will be useful,
13
// but WITHOUT ANY WARRANTY; without even the implied warranty of
14
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
// GNU General Public License for more details.
16
//
17
// You should have received a copy of the GNU General Public License
18
// along with this program. If not, see <http://www.gnu.org/licenses/>.
19
20
#pragma once
21
22
#include "cc_tools_qt/ToolsApi.h"
23
#include "
cc_tools_qt/version.h
"
24
25
#include <QtCore/QVariant>
26
#include <QtCore/QVariantMap>
27
28
#include <chrono>
29
#include <memory>
30
#include <string>
31
#include <vector>
32
33
namespace
cc_tools_qt
34
{
35
38
struct
CC_TOOLS_API
ToolsDataInfo
39
{
41
using
TimestampClock
= std::chrono::high_resolution_clock;
42
44
using
Timestamp
= std::chrono::time_point<TimestampClock>;
45
47
using
DataSeq
= std::vector<std::uint8_t>;
48
50
using
PropertiesMap
= QVariantMap;
51
52
ToolsDataInfo
();
53
Timestamp
m_timestamp
;
54
DataSeq
m_data
;
55
PropertiesMap
m_extraProperties
;
56
};
57
59
using
ToolsDataInfoPtr
= std::shared_ptr<ToolsDataInfo>;
60
62
CC_TOOLS_API
ToolsDataInfoPtr
makeDataInfo
();
63
66
CC_TOOLS_API
ToolsDataInfoPtr
makeDataInfoTimed
();
67
68
}
// namespace cc_tools_qt
69
70
Q_DECLARE_METATYPE(
cc_tools_qt::ToolsDataInfoPtr
);
71
cc_tools_qt
Main namespace for all classes / functions of the shared library.
cc_tools_qt::makeDataInfoTimed
CC_TOOLS_API ToolsDataInfoPtr makeDataInfoTimed()
Dynamically allocate ToolsDataInfo and return in in ToolsDataInfoPtr;.
Definition
ToolsDataInfo.cpp:53
cc_tools_qt::ToolsDataInfoPtr
std::shared_ptr< ToolsDataInfo > ToolsDataInfoPtr
Pointer to ToolsDataInfo.
Definition
ToolsDataInfo.h:59
cc_tools_qt::makeDataInfo
CC_TOOLS_API ToolsDataInfoPtr makeDataInfo()
Dynamically allocate ToolsDataInfo and return in in ToolsDataInfoPtr;.
Definition
ToolsDataInfo.cpp:48
cc_tools_qt::ToolsDataInfo
Information about incomming or outdoing data.
Definition
ToolsDataInfo.h:39
cc_tools_qt::ToolsDataInfo::m_extraProperties
PropertiesMap m_extraProperties
Extra properties that can be used by other componets.
Definition
ToolsDataInfo.h:55
cc_tools_qt::ToolsDataInfo::PropertiesMap
QVariantMap PropertiesMap
Type of extra properties storage.
Definition
ToolsDataInfo.h:50
cc_tools_qt::ToolsDataInfo::m_data
DataSeq m_data
Actual raw data.
Definition
ToolsDataInfo.h:54
cc_tools_qt::ToolsDataInfo::m_timestamp
Timestamp m_timestamp
Timestamp when data has been received / sent.
Definition
ToolsDataInfo.h:53
cc_tools_qt::ToolsDataInfo::TimestampClock
std::chrono::high_resolution_clock TimestampClock
Type of clock used for timestamping.
Definition
ToolsDataInfo.h:41
cc_tools_qt::ToolsDataInfo::Timestamp
std::chrono::time_point< TimestampClock > Timestamp
Type of timestamps.
Definition
ToolsDataInfo.h:44
cc_tools_qt::ToolsDataInfo::DataSeq
std::vector< std::uint8_t > DataSeq
Type of raw data sequence.
Definition
ToolsDataInfo.h:47
version.h
Generated by
1.9.8