Utils.h

Go to the documentation of this file.
00001 //
00002 // (C) 2005 Vojtech Janota
00003 //
00004 // This library is free software, you can redistribute it
00005 // and/or modify
00006 // it under  the terms of the GNU Lesser General Public License
00007 // as published by the Free Software Foundation;
00008 // either version 2 of the License, or any later version.
00009 // The library is distributed in the hope that it will be useful,
00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
00012 // See the GNU Lesser General Public License for more details.
00013 //
00014 
00015 #ifndef __INET_UTILS_H
00016 #define __INET_UTILS_H
00017 
00018 #include <vector>
00019 #include <omnetpp.h>
00020 #include "IntServ.h"
00021 
00025 void removeDuplicates(std::vector<int>& vec);
00026 
00030 bool find(std::vector<int>& vec, int value);
00031 
00035 bool find(const IPAddressVector& vec, IPAddress addr); // use TEMPLATE
00036 
00040 void append(std::vector<int>& dest, const std::vector<int>& src);
00041 
00045 int find(const EroVector& ERO, IPAddress node);
00046 
00050 cModule *getPayloadOwner(cPacket *msg);
00051 
00052 //void prepend(EroVector& dest, const EroVector& src, bool reverse);
00053 
00054 
00055 #endif