Annotation of /trunk/ModularRex/RexNetwork/RexLogin/RexLoginModule.cs
Parent Directory
|
Revision Log
Revision 5 - (view) (download)
| 1 : | afrisby | 3 | using System; |
| 2 : | afrisby | 5 | using System.Collections; |
| 3 : | afrisby | 3 | using System.Collections.Generic; |
| 4 : | using System.Text; | ||
| 5 : | using Nini.Config; | ||
| 6 : | afrisby | 5 | using OpenSim.Region.ClientStack; |
| 7 : | afrisby | 3 | using OpenSim.Region.Environment.Interfaces; |
| 8 : | using OpenSim.Region.Environment.Scenes; | ||
| 9 : | |||
| 10 : | namespace ModularRex.RexNetwork.RexLogin | ||
| 11 : | { | ||
| 12 : | class RexLoginModule : IRegionModule | ||
| 13 : | { | ||
| 14 : | private Scene m_firstScene; | ||
| 15 : | afrisby | 5 | private IClientNetworkServer m_udpserver; |
| 16 : | afrisby | 3 | |
| 17 : | public void Initialise(Scene scene, IConfigSource source) | ||
| 18 : | { | ||
| 19 : | afrisby | 5 | if (m_udpserver == null) |
| 20 : | m_udpserver = new RexUDPServer(); | ||
| 21 : | |||
| 22 : | m_udpserver.AddScene(scene); | ||
| 23 : | |||
| 24 : | afrisby | 3 | m_firstScene = scene; |
| 25 : | afrisby | 5 | scene.AddHTTPHandler("/rexlogin", OnLoginRequest); |
| 26 : | afrisby | 3 | } |
| 27 : | |||
| 28 : | afrisby | 5 | public Hashtable OnLoginRequest(Hashtable keysvals) |
| 29 : | { | ||
| 30 : | Hashtable reply = new Hashtable(); | ||
| 31 : | int statuscode = 200; | ||
| 32 : | |||
| 33 : | reply["str_response_string"] = "Test"; | ||
| 34 : | reply["int_response_code"] = statuscode; | ||
| 35 : | reply["content_type"] = "text/xml"; | ||
| 36 : | |||
| 37 : | return reply; | ||
| 38 : | } | ||
| 39 : | |||
| 40 : | |||
| 41 : | afrisby | 3 | public void PostInitialise() |
| 42 : | { | ||
| 43 : | } | ||
| 44 : | |||
| 45 : | public void Close() | ||
| 46 : | { | ||
| 47 : | |||
| 48 : | } | ||
| 49 : | |||
| 50 : | public string Name | ||
| 51 : | { | ||
| 52 : | get { return "RexLoginOverrider"; } | ||
| 53 : | } | ||
| 54 : | |||
| 55 : | public bool IsSharedModule | ||
| 56 : | { | ||
| 57 : | get { return true; } | ||
| 58 : | } | ||
| 59 : | } | ||
| 60 : | } |
| ViewVC Help | |
| Powered by ViewVC 1.0.0 |

