Re: WOApplication.createRequest 5.3 and 5.4
Re: WOApplication.createRequest 5.3 and 5.4
- Subject: Re: WOApplication.createRequest 5.3 and 5.4
- From: Andrew Lindesay <email@hidden>
- Date: Tue, 30 Oct 2007 13:04:09 +1300
Hello Anjo;
I suppose if one wanted to fiddle with the headers and then call
super this is not going to work is it?
cheers.
Actually, to be able to compile, you have to write:
public WORequest createRequest(String aMethod, String aURL, String
anHTTPVersion, NSDictionary someHeaders, NSData aContent,
NSDictionary someInfo) {
return _createRequest(aMethod, aURL, anHTTPVersion, new
NSDictionary(someHeaders, false), aContent, someInfo);
}
public WORequest createRequest(String aMethod, String aURL, String
anHTTPVersion, Map someHeaders, NSData aContent, NSDictionary
someInfo) {
return _createRequest(aMethod, aURL, anHTTPVersion, new
NSDictionary(someHeaders, false), aContent, someInfo);
}
protected WORequest _createRequest(String aMethod, String aURL,
String anHTTPVersion, NSDictionary someHeaders, NSData aContent,
NSDictionary someInfo) {
WORequest worequest = new ERXRequest(aMethod, aURL,
anHTTPVersion, someHeaders, aContent, someInfo);
return worequest;
}
...
Bla Wonder, bla:
public WORequest createRequest(String aMethod, String aURL,
String anHTTPVersion, NSDictionary someHeaders, NSData aContent,
NSDictionary someInfo) {
// Workaround for #3428067 (Apache Server Side Include module
will feed
// "INCLUDED" as the HTTP version, which causes a request object
not to be
// created by an excepion.
if (anHTTPVersion.startsWith("INCLUDED"))
anHTTPVersion = "HTTP/1.0";
WORequest worequest = new ERXRequest(aMethod, aURL,
anHTTPVersion, someHeaders, aContent, someInfo);
return worequest;
}
public WORequest createRequest(String aMethod, String aURL,
String anHTTPVersion, Map someHeaders, NSData aContent,
NSDictionary someInfo) {
return createRequest(aMethod, aURL, anHTTPVersion, new
NSDictionary(someHeaders, false), aContent, someInfo);
}
...
Has anybody else identified a 5.3 and 5.4 API compatible means of
overriding "WOApplication.createRequest(...)" ? I presume this
is not possible.
___
Andrew Lindesay
technology : www.lindesay.co.nz
business : www.silvereye.co.nz
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden