[wx-dev] wxHTTP rewrite?

Falk Tristram ftristram at gmx.de
Fri May 2 11:41:41 PDT 2008


>  Personally I still think that the best way to rewrite wxHTTP would be to
> just provide wrappers around libcurl under Unix and WinInet functions
> under
> Win32.
I will have a deeper look into the libcurl, but still some functionality is there also missing.

> FT> To short things up, wxHTTP is not beautiful :
>  We agree here.
So can I do what I like ? :D
Who is responsible for that part of code ?
If noone, I could help out ...

>  Yes, definitely. wxHTTP (and also wxFTP) is in sore need of update. 
> ..., i.e. wrap the existing code in wx-friendly (and presumably more or 
> less current wxHTTP-compatible) API

Of course. There is no need to be backward-compatible to anything ...
so we just could drop HTTP 0.9/1.0 ...
HTTP 1.1 is sufficient!


> 1. As mentioned above, we should preserve (maybe not perfect but still)
>    compatibility with the existing wxHTTP to avoid breaking code using it.

Ok, considering it. Thanks for reminding me ...

> 2. One of the most important things to decide is whether we're going to
>    provide asynchronous API or just synchronous functions. 

I think the most progressive implemenation would be creating (http)_events.

no_apache_clone = new wxHttpServer ( int port, ... )

for servers:2
no_apache_clone->AddRequestHandler ( "/virtual_path", event_id );
no_apache_clone->AddDefaultRequestHandler ( "*", defaultevent_id );

for clients:
no_apache_clone->AddResponseHandler ( event_id );

These events will contain the complete httpmessage.


Greetz 
Falk








-- 
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! 
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer


More information about the wx-dev mailing list