Re: [GNE]Help!
Brought to you by:
gillius
From: Gillius <gi...@ma...> - 2002-03-27 05:46:43
|
Sorry for the very long response time. I just got my new computer back up, though. Have you read the beginners guide yet? There is a ServerConnectionListener class which listens on a port for ClientConnections to connect. Then when this happens a ServerConnection is created, and the first time you see it is in your onNewConn handler. OurConnectionListener is derived from ServerConnectionListener, so it is just a class representing the socket listen() is called on, and when something comes in, it accept()s and the newly spawned socket becomes the ServerConnection which is subclasses in the examples as OurServer. exhello and exsynchello are examples that show the minimum code to set up a fully-functional framework and initiate a connection. There is a bit of overhead, but once you get that framework in, it should be very easy to expand onto that. Gillius On 20 Mar 2002 at 20:39, Varlock wrote: > Hello. > > I just signed up over here from your suggestion on the [AGP] list. I > don't really want to bother getting the new pthreads working with it or > anything like that - it seems to work just fine as it is with the older > version, but I would really love some help understanding how GNE works. > Mainly, these points. > I understand the concept of a packet, and I really like your packet > structure. I've already made a new packet type and I think I've got that > under control. Unfortunately, I don't really get the rest of it. I've looked > through some of the example programs and I don't know what the difference > between a ConnectionListener and a Server and/or Client are. Why do the > examples define an OurConnectionListener, and what does it do? > Grr. I'm having trouble coming up with specific examples here for some > reason. If you assume all I really understand are the packets, is there > something I could read which would help me get what I need to do to write a > simple application? I'm mostly getting confused by the example programs. For > example, let's start of with how do I > > a.) create a server (ie. the classes required) > b.) create a client > > Thanks. I'm sure I'll have a lot more questions as I get to understand > this stuff. I believe I have a good grasp of the concepts of networking, you > probably don't have to go into a lot of theory. I just need to understand > how your code relates to that theory so I can get on to the good stuff. > Thanks again. > > - Trevor > > > _______________________________________________ > Gnelib-users mailing list > Gne...@li... > https://lists.sourceforge.net/lists/listinfo/gnelib-users |