Source: bandwidthmanager.h


Annotated List
Files
Globals
Hierarchy
Index
// ##########################################################################
// ####                                                                  ####
// ####                    Master Thesis Implementation                  ####
// ####  Management of Layered Variable Bitrate Multimedia Streams over  ####
// ####                  DiffServ with A Priori Knowledge                ####
// ####                                                                  ####
// #### ================================================================ ####
// ####                                                                  ####
// ####                                                                  ####
// #### Bandwidth Manager                                                ####
// ####                                                                  ####
// #### Version 1.00  --  October 10, 2000                               ####
// ####                                                                  ####
// #### Copyright (C) 2000 Thomas Dreibholz                              ####
// #### University of Bonn, Department of Computer Science IV            ####
// #### EMail: Dreibholz@bigfoot.com                                     ####
// #### WWW:   http://www.bigfoot.com/~dreibholz/diplom/index.html       ####
// ####                                                                  ####
// ##########################################################################


#ifndef BANDWIDTHMANAGERINTERFACE_H
#define BANDWIDTHMANAGERINTERFACE_H


#include "system.h"
#include "abstractqosdescription.h"
#include "timedthread.h"
#include "servicelevelagreement.h"
#include "streamdescription.h"


#include <multimap.h>
#include <algo.h>


namespace Coral {


/**
  * This is the bandwidth manager.
  *
  * @short   Bandwidth Manager
  * @author  Thomas Dreibholz (Dreibholz@bigfoot.com)
  * @version 1.0
*/
class BandwidthManager : public TimedThread
{
   // ====== Constructor/Destructor =========================================
   public:
   /**
     * Constructor.
     */
   BandwidthManager(ServiceLevelAgreement* sla);

   /**
     * Destructor.
     */
   ~BandwidthManager();


   // ====== Stream management ==============================================
   /**
     * Add stream to management.
     *
     * @param stream Stream to add.
     */
   void addStream(ManagedStreamInterface* stream);

   /**
     * Remove stream from management.
     *
     * @param stream Stream to remove.
     */
   void removeStream(ManagedStreamInterface* stream);

   /**
     * Update stream.
     *
     * @param stream Stream to be updated.
     */
   void updateStream(ManagedStreamInterface* stream);


   // ====== Events =========================================================
   /**
     * Interval has changed.
     *
     * @param stream Stream with changed interval.
     ??????????????????????????
     */
   bool intervalChangeEvent(ManagedStreamInterface* stream,
                            const card64            when);

   /**
     * Loss rate reception for given layer.
     *
     * @param stream Stream.
     * @param layer Layer.
     * @param lossRate Loss rate of the layer given.
     */
   void lossEvent(ManagedStreamInterface* stream,
                  const cardinal          layer,
                  const double            lossRate);


   // ====== Private data ===================================================
   private:
   void timerEvent();
   void doCompleteRemapping();

   multimap<ManagedStreamInterface*,StreamDescription*> StreamSet;
   ServiceLevelAgreement*                               SLA;
   bool Changed;
};


}


#endif

Generated by: viper@odin on Mon Oct 16 11:49:26 2000, using kdoc 2.0a36.