From: tho Date: Wed, 5 Jan 2011 14:54:24 +0000 (+0000) Subject: Packets/DefaultBundle: added EUI64Parser X-Git-Url: http://g0dil.de/git?p=senf.git;a=commitdiff_plain;h=e9816d699770dea77c989c97ef53bf2266ce7b6b Packets/DefaultBundle: added EUI64Parser git-svn-id: https://svn.berlios.de/svnroot/repos/senf/trunk@1755 270642c3-0616-0410-b53a-bc976706d245 --- diff --git a/senf/Packets/DefaultBundle/EUI64Parser.hh b/senf/Packets/DefaultBundle/EUI64Parser.hh new file mode 100644 index 0000000..be4be32 --- /dev/null +++ b/senf/Packets/DefaultBundle/EUI64Parser.hh @@ -0,0 +1,58 @@ +// $Id$ +// +// Copyright (C) 2010 +// Fraunhofer Institute for Open Communication Systems (FOKUS) +// Competence Center NETwork research (NET), St. Augustin, GERMANY +// Thorsten Horstmann +// +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; either version 2 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License +// along with this program; if not, write to the +// Free Software Foundation, Inc., +// 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +/** \file + \brief EUI64Parser public header */ + +#ifndef HH_SENF_Packets_DefaultBundle_EUI64Parser_ +#define HH_SENF_Packets_DefaultBundle_EUI64Parser_ 1 + +// Custom includes +#include +#include + +///////////////////////////////hh.p//////////////////////////////////////// +namespace senf { + + /** \brief Parse an EUI64 address + + The EUI64 address is returned by value as a 8-byte sequence + + \see EUI64 + */ + struct EUI64Parser + : public ValueParserBase + { + EUI64Parser(data_iterator i, state_type s) : Base(i,s) {} + + value_type value() const { return value_type::from_data(i()); } + void value(value_type const & v) { std::copy(v.begin(), v.end(), i()); } + + using Base::operator=; + }; + +} +//-///////////////////////////////////////////////////////////////////////////////////////////////// +//#include "EUI64Parser.cci" +//#include "EUI64Parser.ct" +//#include "EUI64Parser.cti" +#endif diff --git a/senf/Scheduler/TimerEventProxy.hh b/senf/Scheduler/TimerEventProxy.hh index 8e813b7..d1fb5ad 100644 --- a/senf/Scheduler/TimerEventProxy.hh +++ b/senf/Scheduler/TimerEventProxy.hh @@ -41,7 +41,7 @@ namespace scheduler { /** \brief Deadline timer proxy - The TimerEventProxy is meant to host long term deadline timers to reduce the load of the + The TimerEventProxy is meant to host long %term deadline timers to reduce the load of the Scheduler with a huge count of TimerEvent items. It registers deadline timer callbacks which will be called when the timer expires.