Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

wvstreamex6.cc

Go to the documentation of this file.
00001 #include <wvstream.h>
00002 
00003 void mycallback(WvStream &s, void *userdata)
00004 {
00005     WvStream *outstream = (WvStream *)userdata;
00006     
00007     char *str = s.getline(0);
00008     if (str)
00009         outstream->print("You said: %s\n", str);
00010 }
00011 
00012 int main()
00013 {
00014     wvcon->setcallback(mycallback, wvcon);
00015 
00016     while (wvcon->isok())
00017     {
00018         if (wvcon->select(-1))
00019             wvcon->callback();
00020     }
00021 }

Generated on Sun Aug 25 02:29:34 2002 for WvStreams by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002