Re: info about HandlerCall::call_read()
Cliff Frey <[email protected]>
| Newsgroups | gmane.network.routing.click |
|---|---|
| Message-ID | <CAFtVOqkx5ibnUbLKsPn31g2ZU8CKMomcV8mAb-EXUqUDWZ77Mw@mail.gmail.com> |
You can look at the HandlerCall interface if you really want to use read-handlers. Often in cases like this, it is easier to actually pass a pointer from one element to another through the config. ARPQuerier can do this with ARPTable, or etherswitch/spantree.cc does this as well. Search for ElementCastArg in the source. Cliff On Tue, Oct 11, 2011 at 7:54 AM, Xavier Salip <[email protected]> wrote: > Hi list, > > I have created an element called WC. > In a configuration .click file i have a bank of 5 WC elements (WC1, > WC2...WC5), each one of them with a read handler called "energy". > I would like to create a control element CONTROL which reads the handler > "energy" on the desired WC and make some calculations with it. > I'm trying with this function to call the handler, but i don't manage to > find how to use it in a correct way: > > String <http://www.read.cs.ucla.edu/click/doxygen/class_string.html > >HandlerCall::call_read > ( Element <http://www.read.cs.ucla.edu/click/doxygen/class_element.html> * > *e*, > > const String <http://www.read.cs.ucla.edu/click/doxygen/class_string.html > >& > *hname*, > > ErrorHandler< > http://www.read.cs.ucla.edu/click/doxygen/class_error_handler.html>* > *errh* = 0 > ) > > Any ideas or suggestions? > > Thanks! > _______________________________________________ > click mailing list > [email protected] > https://amsterdam.lcs.mit.edu/mailman/listinfo/click >