X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=PPI%2FRateFilter.cc;h=953bba715975805878a41b1e4d7adf036a4628ad;hb=5443435c4c2b6e4386c5334b5b8358273f2bae93;hp=00e45681514d5b43a192d44ba52847c96c79738a;hpb=aed52b6070e9f7d95efad9de84a41e5ea7413255;p=senf.git diff --git a/PPI/RateFilter.cc b/PPI/RateFilter.cc index 00e4568..953bba7 100644 --- a/PPI/RateFilter.cc +++ b/PPI/RateFilter.cc @@ -1,6 +1,8 @@ +// $Id$ +// // Copyright (C) 2007 -// Fraunhofer Institute for Open Communication Systems (FOKUS) -// Competence Center NETwork research (NET), St. Augustin, GERMANY +// Fraunhofer Institute for Open Communication Systems (FOKUS) +// Competence Center NETwork research (NET), St. Augustin, GERMANY // Stefan Bund // // This program is free software; you can redistribute it and/or modify @@ -19,21 +21,23 @@ // 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. /** \file - \brief ppitest non-inline non-template implementation */ + \brief RateFilter non-inline non-template implementation */ #include "RateFilter.hh" +//#include "RateFilter.ih" -#define prefix_ -// //////////////////////////////////////////////////////////////////////// -// RateFilter +// Custom includes +//#include "RateFilter.mpp" +#define prefix_ +///////////////////////////////cc.p//////////////////////////////////////// senf::ppi::module::RateFilter::RateFilter(senf::ClockService::clock_type interval) - : timer(interval) + : timer_(interval) { - route(input,timer); - route(timer,output); - registerEvent(timer, &RateFilter::timeout); + route(input, timer_); + route(timer_, output); + registerEvent(timer_, &RateFilter::timeout); } void senf::ppi::module::RateFilter::timeout() @@ -41,10 +45,29 @@ void senf::ppi::module::RateFilter::timeout() output(input()); } +senf::ClockService::clock_type senf::ppi::module::RateFilter::interval() + const +{ + return timer_.interval().first; +} -/* this should be what should happen. but _this_ most likely won't work -void senf::ppi::module::RateFilter::changeInterval(senf::ClockService::clock_type interval) +void senf::ppi::module::RateFilter::interval(senf::ClockService::clock_type interval) { - //timer = ppi::IntervalTimer(interval); + timer_.interval(interval); } -*/ \ No newline at end of file + + +///////////////////////////////cc.e//////////////////////////////////////// +#undef prefix_ +//#include "RateFilter.mpp" + + +// Local Variables: +// mode: c++ +// fill-column: 100 +// comment-column: 40 +// c-file-style: "senf" +// indent-tabs-mode: nil +// ispell-local-dictionary: "american" +// compile-command: "scons -u test" +// End: