RTP Trace System
1.0
|
00001 // ########################################################################## 00002 // #### #### 00003 // #### Master Thesis Implementation #### 00004 // #### Management of Layered Variable Bitrate Multimedia Streams over #### 00005 // #### DiffServ with A Priori Knowledge #### 00006 // #### #### 00007 // #### ================================================================ #### 00008 // #### #### 00009 // #### #### 00010 // #### Stream Description #### 00011 // #### #### 00012 // #### Version 1.00 -- February 19, 2001 #### 00013 // #### #### 00014 // #### Copyright (C) 2000/2001 Thomas Dreibholz #### 00015 // #### University of Bonn, Department of Computer Science IV #### 00016 // #### EMail: dreibh@iem.uni-due.de #### 00017 // #### WWW: https://www.uni-due.de/~be0001/diplom/index.html #### 00018 // #### #### 00019 // ########################################################################## 00020 00021 00022 #ifndef STREAMDESCRIPTION_H 00023 #define STREAMDESCRIPTION_H 00024 00025 00026 #include "system.h" 00027 #include "servicelevelagreement.h" 00028 #include "trafficclassvalues.h" 00029 #include "managedstreaminterface.h" 00030 #include "abstractqosdescription.h" 00031 #include "sessiondescription.h" 00032 00033 00034 namespace Coral { 00035 00036 00045 class StreamDescription 00046 { 00047 // ====== Constructor/Destructor ========================================= 00048 public: 00052 StreamDescription(); 00053 00057 ~StreamDescription(); 00058 00059 00060 // ====== Initialization ================================================= 00072 void init(ManagedStreamInterface* stream, 00073 const ServiceLevelAgreement* sla, 00074 const cardinal maxPoints, 00075 const card64 bwThreshold, 00076 const double utThreshold, 00077 const double systemDelayTolerance, 00078 const bool unlayeredAllocation); 00079 00080 00081 // ====== Layer -> DiffServ class mapping and bandwidth allocation ======= 00096 bool tryAllocation(const ServiceLevelAgreement* sla, 00097 card64& totalAvailableBandwidth, 00098 card64* classAvailableBandwidthArray, 00099 ResourceUtilizationPoint& rup, 00100 const card64 bandwidthLimit = (card64)-1); 00101 00102 00103 // ====== Stream and session information ================================= 00107 ManagedStreamInterface* Interface; 00108 00112 AbstractQoSDescription* QoSDescription; 00113 00117 SessionDescription* Session; 00118 00122 card64 StreamID; 00123 00127 cardinal Layers; 00128 00129 00130 // ====== Resource/utilization list ====================================== 00134 static const cardinal MaxRUEntries = 256; 00135 00139 cardinal RUEntries; 00140 00144 ResourceUtilizationPoint RUList[MaxRUEntries]; 00145 00146 00147 // ====== Newly allocated bandwidths and classes ========================= 00151 cardinal NewLayerClassNumber[RTPConstants::RTPMaxQualityLayers]; 00152 00156 card64 NewLayerClassBandwidth[RTPConstants::RTPMaxQualityLayers]; 00157 00161 double NewCostPerSecond; 00162 00166 ResourceUtilizationPoint NewQuality; 00167 00171 double LastUtilization; 00172 00173 00174 // ====== Current allocated bandwidths and classes ======================= 00178 cardinal CurrentLayerClassNumber[RTPConstants::RTPMaxQualityLayers]; 00179 00183 card64 CurrentLayerClassBandwidth[RTPConstants::RTPMaxQualityLayers]; 00184 00188 double CurrentCostPerSecond; 00189 00193 ResourceUtilizationPoint CurrentQuality; 00194 00198 card64 ReservationTimeStamp; 00199 00200 00201 // ====== Statistics ===================================================== 00205 double TotalCost; 00206 00210 double TotalBandwidthUsage; 00211 00215 double TotalUtilization; 00216 00220 double TotalRuntime; 00221 00225 cardinal TotalReservationUpdates; 00226 00230 cardinal PartialRemappings; 00231 00235 cardinal CompleteRemappings; 00236 00242 cardinal Inits; 00243 00247 cardinal BufferFlushes; 00248 00252 card64 LastInitDuration; 00253 00254 00255 00256 // ====== Network quality ================================================ 00260 double ReportedLossRate[RTPConstants::RTPMaxQualityLayers]; 00261 00265 double ReportedJitter[RTPConstants::RTPMaxQualityLayers]; 00266 00270 double MeasuredTransferDelay[TrafficClassValues::MaxValues]; 00271 00272 00273 // ====== Miscellaneous data ============================================= 00277 InternetAddress RoundTripTimeDestination; 00278 00282 card64 NextInterval; 00283 00289 bool MaximumReached; 00290 00294 bool UnlayeredAllocation; 00295 00296 00297 // ====== Private methods ================================================ 00298 private: 00299 bool calculatePossibleLayerClassMappings( 00300 ResourceUtilizationPoint& rup, 00301 const ServiceLevelAgreement* sla, 00302 const AbstractQoSDescription* aqd); 00303 }; 00304 00305 00306 } 00307 00308 00309 #endif