From ad04626737c164138d6d15d5e06eb20ff5b5f859 Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Mon, 6 Oct 2008 21:59:43 +0000 Subject: cleaning up OSHttpResponse: note that read access to extra header fields is GONE (HttpServer does not support that), you can read the "normal" HTTP headers available via properties, and you can add headers. also, it is now possible to set a timeout for KeepAlive (for those clients that pay attention to it). this also fixes the broken REST inventory/assets/appearance services, they should be working again. testcase for OSHttpResponse will follow. --- OpenSim/Framework/Servers/OSHttpRequest.cs | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'OpenSim/Framework/Servers/OSHttpRequest.cs') diff --git a/OpenSim/Framework/Servers/OSHttpRequest.cs b/OpenSim/Framework/Servers/OSHttpRequest.cs index c47fe10..4c7d7ce 100644 --- a/OpenSim/Framework/Servers/OSHttpRequest.cs +++ b/OpenSim/Framework/Servers/OSHttpRequest.cs @@ -42,9 +42,8 @@ namespace OpenSim.Framework.Servers { private static readonly ILog _log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); - protected HttpServer.IHttpRequest _request = null; - protected HttpServer.IHttpClientContext _context = null; - + protected IHttpRequest _request = null; + protected IHttpClientContext _context = null; public string[] AcceptTypes { @@ -137,8 +136,15 @@ namespace OpenSim.Framework.Servers } private string _userAgent; + internal IHttpRequest IHttpRequest + { + get { return _request; } + } - + internal IHttpClientContext IHttpClientContext + { + get { return _context; } + } /// /// Internal whiteboard for handlers to store temporary stuff @@ -151,11 +157,9 @@ namespace OpenSim.Framework.Servers private Dictionary _whiteboard = new Dictionary(); - public OSHttpRequest() - { - } + public OSHttpRequest() {} - public OSHttpRequest(HttpServer.IHttpClientContext context, HttpServer.IHttpRequest req) + public OSHttpRequest(IHttpClientContext context, IHttpRequest req) { _request = req; _context = context; -- cgit v1.1