A Discrete-Event Network Simulator
API
time-series-adaptor.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2013 University of Washington
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Author: Mitch Watrous (watrous@u.washington.edu)
19  */
20 
21 #ifndef TIME_SERIES_ADAPTOR_H
22 #define TIME_SERIES_ADAPTOR_H
23 
24 #include "ns3/data-collection-object.h"
25 #include "ns3/object.h"
26 #include "ns3/type-id.h"
27 #include "ns3/traced-value.h"
28 
29 namespace ns3 {
30 
49 {
50 public:
55  static TypeId GetTypeId (void);
56 
58  virtual ~TimeSeriesAdaptor ();
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:
125 };
126 
127 } // namespace ns3
128 
129 #endif // TIME_SERIES_ADAPTOR_H
Base class for data collection framework objects.
Takes probed values of different types and outputs the current time plus the value with both converte...
uint8_t data[writeSize]
void TraceSinkUinteger32(uint32_t oldData, uint32_t newData)
Trace sink for receiving data from uint32_t valued trace sources.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
void TraceSinkUinteger8(uint8_t oldData, uint8_t newData)
Trace sink for receiving data from uint8_t valued trace sources.
void(* OutputTracedCallback)(const double now, const double data)
TracedCallback signature for output trace.
void TraceSinkUinteger16(uint16_t oldData, uint16_t newData)
Trace sink for receiving data from uint16_t valued trace sources.
void TraceSinkDouble(double oldData, double newData)
Trace sink for receiving data from double valued trace sources.
void TraceSinkBoolean(bool oldData, bool newData)
Trace sink for receiving data from bool valued trace sources.
TracedCallback< double, double > m_output
output trace
static TypeId GetTypeId(void)
Get the type ID.
a unique identifier for an interface.
Definition: type-id.h:58