diff options
author | MW | 2007-12-05 19:02:57 +0000 |
---|---|---|
committer | MW | 2007-12-05 19:02:57 +0000 |
commit | d2736437d42758ddefee4e50e23c465e514077be (patch) | |
tree | 35d9ece58c1c9d63d28015a60964a5103eb1a343 /OpenSim/Framework/Servers/RestObjectPoster.cs | |
parent | From Justin Casey (IBM) (diff) | |
download | opensim-SC_OLD-d2736437d42758ddefee4e50e23c465e514077be.zip opensim-SC_OLD-d2736437d42758ddefee4e50e23c465e514077be.tar.gz opensim-SC_OLD-d2736437d42758ddefee4e50e23c465e514077be.tar.bz2 opensim-SC_OLD-d2736437d42758ddefee4e50e23c465e514077be.tar.xz |
Some refactoring of the RestObjectPoster (and related classes).
Diffstat (limited to 'OpenSim/Framework/Servers/RestObjectPoster.cs')
-rw-r--r-- | OpenSim/Framework/Servers/RestObjectPoster.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/OpenSim/Framework/Servers/RestObjectPoster.cs b/OpenSim/Framework/Servers/RestObjectPoster.cs index 9bcfcca..991b1d5 100644 --- a/OpenSim/Framework/Servers/RestObjectPoster.cs +++ b/OpenSim/Framework/Servers/RestObjectPoster.cs | |||
@@ -11,10 +11,15 @@ namespace OpenSim.Framework.Servers | |||
11 | { | 11 | { |
12 | public static void BeginPostObject<TRequest>(string requestUrl, TRequest obj) | 12 | public static void BeginPostObject<TRequest>(string requestUrl, TRequest obj) |
13 | { | 13 | { |
14 | BeginPostObject("POST", requestUrl, obj); | ||
15 | } | ||
16 | |||
17 | public static void BeginPostObject<TRequest>(string verb, string requestUrl, TRequest obj) | ||
18 | { | ||
14 | Type type = typeof(TRequest); | 19 | Type type = typeof(TRequest); |
15 | 20 | ||
16 | WebRequest request = WebRequest.Create(requestUrl); | 21 | WebRequest request = WebRequest.Create(requestUrl); |
17 | request.Method = "POST"; | 22 | request.Method = verb; |
18 | request.ContentType = "text/xml"; | 23 | request.ContentType = "text/xml"; |
19 | 24 | ||
20 | MemoryStream buffer = new MemoryStream(); | 25 | MemoryStream buffer = new MemoryStream(); |