he did say The above example is also an example of polymorhism, and doesn't need a language such as C++ that explicity supports it. In C the Draw() member would just be a function pointer.
At this moment, the post I'm commenting on is rated +3 informative. And it is 100% incorrect. IIS does not run in kernel space. It's just a normal Service.
Of course, alot of the action takes place in kernel space, since IIS uses IO completion ports and asynchronous IO.
Common, this post is just plain wrong If you say that a program uses the "Windowing system" that has to mean that the program is using the message loop. To use the message loop, you have to have a Window (it does not have to be visible)
I have written several servers in NT using the WIN32 api and I have never used the message loop.
You can use select for socket events, just like in UNIX (if you are careful and use the abstractions that are available SET_FD, CLR_FD etc.) but if you're writing a NT only app, WaitForMultipleObjects is the preferred way.
If you want to write a high performance server, you'll use async IO and IO completion ports.
You could also just do it the java way, and spawn a thread for every connections and use blocking sockets but that would not handle many connections well.
Check out 'Advanced Windows' by Jeffrey Richter for more info on Windows server programming.
sorry, you're wrong. From the c++ standard, page 97:
If the for-init-statement is a declaration, the scope of the name(s) declared extends to the end of the for-statement. [Example:
int i = 42;
int a[10];
for (int i = 0; i 10; i++)
a[i] = i;
int j = i;// j = 42
--end example]
Take a look at EVE
"EVE uses a special Stackless version of Python to implement game logic, both on the server and the client."
Matti Á.
he did say
The above example is also an example of polymorhism, and doesn't need a language such as C++ that explicity supports it. In C the Draw() member would just be a function pointer.
Of course, alot of the action takes place in kernel space, since IIS uses IO completion ports and asynchronous IO.
I have written several servers in NT using the WIN32 api and I have never used the message loop.
You can use select for socket events, just like in UNIX (if you are careful and use the abstractions that are available SET_FD, CLR_FD etc.) but if you're writing a NT only app, WaitForMultipleObjects is the preferred way. If you want to write a high performance server, you'll use async IO and IO completion ports. You could also just do it the java way, and spawn a thread for every connections and use blocking sockets but that would not handle many connections well.
Check out 'Advanced Windows' by Jeffrey Richter for more info on Windows server programming.
sorry, you're wrong. From the c++ standard, page 97: // j = 42
If the for-init-statement is a declaration, the scope of the name(s) declared extends to the end of the for-statement.
[Example:
int i = 42;
int a[10];
for (int i = 0; i 10; i++)
a[i] = i;
int j = i;
--end example]