A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
time-series-adaptor.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2013 University of Washington
3
*
4
* This program is free software; you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License version 2 as
6
* published by the Free Software Foundation;
7
*
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU General Public License for more details.
12
*
13
* You should have received a copy of the GNU General Public License
14
* along with this program; if not, write to the Free Software
15
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16
*
17
* Author: Mitch Watrous (watrous@u.washington.edu)
18
*/
19
20
#ifndef TIME_SERIES_ADAPTOR_H
21
#define TIME_SERIES_ADAPTOR_H
22
23
#include "ns3/data-collection-object.h"
24
#include "ns3/object.h"
25
#include "ns3/traced-value.h"
26
#include "ns3/type-id.h"
27
28
namespace
ns3
29
{
30
48
class
TimeSeriesAdaptor
:
public
DataCollectionObject
49
{
50
public
:
55
static
TypeId
GetTypeId
();
56
57
TimeSeriesAdaptor
();
58
~TimeSeriesAdaptor
()
override
;
59
69
void
TraceSinkDouble
(
double
oldData,
double
newData);
70
80
void
TraceSinkBoolean
(
bool
oldData,
bool
newData);
81
91
void
TraceSinkUinteger8
(uint8_t oldData, uint8_t newData);
92
102
void
TraceSinkUinteger16
(uint16_t oldData, uint16_t newData);
103
113
void
TraceSinkUinteger32
(uint32_t oldData, uint32_t newData);
114
121
typedef
void (*
OutputTracedCallback
)(
const
double
now,
const
double
data
);
122
123
private
:
124
TracedCallback<double, double>
m_output
;
125
};
126
127
}
// namespace ns3
128
129
#endif
// TIME_SERIES_ADAPTOR_H
ns3::DataCollectionObject
Base class for data collection framework objects.
Definition:
data-collection-object.h:39
ns3::TimeSeriesAdaptor
Takes probed values of different types and outputs the current time plus the value with both converte...
Definition:
time-series-adaptor.h:49
ns3::TimeSeriesAdaptor::TimeSeriesAdaptor
TimeSeriesAdaptor()
Definition:
time-series-adaptor.cc:52
ns3::TimeSeriesAdaptor::TraceSinkUinteger8
void TraceSinkUinteger8(uint8_t oldData, uint8_t newData)
Trace sink for receiving data from uint8_t valued trace sources.
Definition:
time-series-adaptor.cc:88
ns3::TimeSeriesAdaptor::TraceSinkDouble
void TraceSinkDouble(double oldData, double newData)
Trace sink for receiving data from double valued trace sources.
Definition:
time-series-adaptor.cc:63
ns3::TimeSeriesAdaptor::m_output
TracedCallback< double, double > m_output
output trace
Definition:
time-series-adaptor.h:124
ns3::TimeSeriesAdaptor::TraceSinkBoolean
void TraceSinkBoolean(bool oldData, bool newData)
Trace sink for receiving data from bool valued trace sources.
Definition:
time-series-adaptor.cc:79
ns3::TimeSeriesAdaptor::~TimeSeriesAdaptor
~TimeSeriesAdaptor() override
Definition:
time-series-adaptor.cc:57
ns3::TimeSeriesAdaptor::OutputTracedCallback
void(* OutputTracedCallback)(const double now, const double data)
TracedCallback signature for output trace.
Definition:
time-series-adaptor.h:121
ns3::TimeSeriesAdaptor::TraceSinkUinteger32
void TraceSinkUinteger32(uint32_t oldData, uint32_t newData)
Trace sink for receiving data from uint32_t valued trace sources.
Definition:
time-series-adaptor.cc:106
ns3::TimeSeriesAdaptor::TraceSinkUinteger16
void TraceSinkUinteger16(uint16_t oldData, uint16_t newData)
Trace sink for receiving data from uint16_t valued trace sources.
Definition:
time-series-adaptor.cc:97
ns3::TimeSeriesAdaptor::GetTypeId
static TypeId GetTypeId()
Get the type ID.
Definition:
time-series-adaptor.cc:38
ns3::TracedCallback< double, double >
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:60
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
data
uint8_t data[writeSize]
Definition:
socket-bound-tcp-static-routing.cc:52
src
stats
model
time-series-adaptor.h
Generated on Fri Mar 31 2023 13:30:51 for ns-3 by
1.9.1