Quote:
Originally Posted by JanOonk
I succeeded in making a socketclient and a socketserver in Alice by using threads. I have put the server in a seperate thread and this works great. Except when you start and close the Alice project, you have to restart Alice to run your project again. I think this is because the port is in use by the thread because I didn't stop the thread before closing the project. I have to use a semaphore or flag or something so the thread nows when to stop.
|
Hello JanOonk,
I don't want to discourage you from stretching Alice 2.0 to its extreme limits. After all, that is how many advances in computer science have occurred over the years. However, just in case you are new to Alice and to this forum, I might mention that the primary audience for which Alice 2.0 is intended won't have a clue what you are talking about with regard to nonblocking Java servers, threads, socketclients, socketservers, semaphores, etc.
A few instructors who teach a programming course using Alice 2.0 may understand some of what you are talking about but even in the instructor category, that is probably a very limited audience.
Students who do understond those concepts should not be enrolled in a course that uses Alice 2.0 as a teaching vehicle. Rather, they should be enrolled in an Advanced Java course using Java3D or similar courses that use other teaching vehicles such as C++ or C#.
So, congratulations on your success is stretchng Alice 2.0 to its limits, but I suspect that you are talking to an almost empty auditorium.
Just the opinion of one person who is quite possibly totally incorrect and out of line.
Dick Baldwin