diff options
author | lbsa71 | 2008-11-25 11:46:15 +0000 |
---|---|---|
committer | lbsa71 | 2008-11-25 11:46:15 +0000 |
commit | dbe64197aecfad98ef04ceffc451f01dd2cab50f (patch) | |
tree | 4fd818abe8f01125c6ddb0dbb76b96c986dddd98 /OpenSim/Grid/UserServer | |
parent | * Adding the incoming url as Param[2] in the XmlRpcRequest (diff) | |
download | opensim-SC_OLD-dbe64197aecfad98ef04ceffc451f01dd2cab50f.zip opensim-SC_OLD-dbe64197aecfad98ef04ceffc451f01dd2cab50f.tar.gz opensim-SC_OLD-dbe64197aecfad98ef04ceffc451f01dd2cab50f.tar.bz2 opensim-SC_OLD-dbe64197aecfad98ef04ceffc451f01dd2cab50f.tar.xz |
* Adding some virtual hooks and making some privaets protected for great justice.
Diffstat (limited to 'OpenSim/Grid/UserServer')
-rw-r--r-- | OpenSim/Grid/UserServer/Main.cs | 24 | ||||
-rw-r--r-- | OpenSim/Grid/UserServer/UserLoginService.cs | 2 | ||||
-rw-r--r-- | OpenSim/Grid/UserServer/UserManager.cs | 2 |
3 files changed, 20 insertions, 8 deletions
diff --git a/OpenSim/Grid/UserServer/Main.cs b/OpenSim/Grid/UserServer/Main.cs index 4e397aa..464ea77 100644 --- a/OpenSim/Grid/UserServer/Main.cs +++ b/OpenSim/Grid/UserServer/Main.cs | |||
@@ -50,7 +50,7 @@ namespace OpenSim.Grid.UserServer | |||
50 | { | 50 | { |
51 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 51 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
52 | 52 | ||
53 | private UserConfig Cfg; | 53 | protected UserConfig Cfg; |
54 | 54 | ||
55 | public UserManager m_userManager; | 55 | public UserManager m_userManager; |
56 | public UserLoginService m_loginService; | 56 | public UserLoginService m_loginService; |
@@ -72,13 +72,13 @@ namespace OpenSim.Grid.UserServer | |||
72 | userserver.Work(); | 72 | userserver.Work(); |
73 | } | 73 | } |
74 | 74 | ||
75 | private OpenUser_Main() | 75 | protected OpenUser_Main() |
76 | { | 76 | { |
77 | m_console = new ConsoleBase("User", this); | 77 | m_console = new ConsoleBase("User", this); |
78 | MainConsole.Instance = m_console; | 78 | MainConsole.Instance = m_console; |
79 | } | 79 | } |
80 | 80 | ||
81 | private void Work() | 81 | public void Work() |
82 | { | 82 | { |
83 | m_console.Notice("Enter help for a list of commands\n"); | 83 | m_console.Notice("Enter help for a list of commands\n"); |
84 | 84 | ||
@@ -95,15 +95,16 @@ namespace OpenSim.Grid.UserServer | |||
95 | m_stats = StatsManager.StartCollectingUserStats(); | 95 | m_stats = StatsManager.StartCollectingUserStats(); |
96 | 96 | ||
97 | m_log.Info("[REGION]: Establishing data connection"); | 97 | m_log.Info("[REGION]: Establishing data connection"); |
98 | m_userManager = new UserManager(); | 98 | |
99 | StartupUserManager(); | ||
100 | |||
99 | m_userManager.AddPlugin(Cfg.DatabaseProvider, Cfg.DatabaseConnect); | 101 | m_userManager.AddPlugin(Cfg.DatabaseProvider, Cfg.DatabaseConnect); |
100 | 102 | ||
101 | m_gridInfoService = new GridInfoService(); | 103 | m_gridInfoService = new GridInfoService(); |
102 | 104 | ||
103 | m_interServiceInventoryService = new OGS1InterServiceInventoryService(Cfg.InventoryUrl); | 105 | m_interServiceInventoryService = new OGS1InterServiceInventoryService(Cfg.InventoryUrl); |
104 | 106 | ||
105 | m_loginService = new UserLoginService( | 107 | StartupLoginService(); |
106 | m_userManager, m_interServiceInventoryService, new LibraryRootFolder(), Cfg, Cfg.DefaultStartupMsg); | ||
107 | 108 | ||
108 | m_messagesService = new MessageServersConnector(); | 109 | m_messagesService = new MessageServersConnector(); |
109 | 110 | ||
@@ -122,6 +123,17 @@ namespace OpenSim.Grid.UserServer | |||
122 | m_httpServer.Start(); | 123 | m_httpServer.Start(); |
123 | } | 124 | } |
124 | 125 | ||
126 | protected virtual void StartupUserManager() | ||
127 | { | ||
128 | m_userManager = new UserManager(); | ||
129 | } | ||
130 | |||
131 | protected virtual void StartupLoginService() | ||
132 | { | ||
133 | m_loginService = new UserLoginService( | ||
134 | m_userManager, m_interServiceInventoryService, new LibraryRootFolder(), Cfg, Cfg.DefaultStartupMsg); | ||
135 | } | ||
136 | |||
125 | protected void AddHttpHandlers() | 137 | protected void AddHttpHandlers() |
126 | { | 138 | { |
127 | m_httpServer.AddXmlRPCHandler("login_to_simulator", m_loginService.XmlRpcLoginMethod); | 139 | m_httpServer.AddXmlRPCHandler("login_to_simulator", m_loginService.XmlRpcLoginMethod); |
diff --git a/OpenSim/Grid/UserServer/UserLoginService.cs b/OpenSim/Grid/UserServer/UserLoginService.cs index 1a69760..82d5af5 100644 --- a/OpenSim/Grid/UserServer/UserLoginService.cs +++ b/OpenSim/Grid/UserServer/UserLoginService.cs | |||
@@ -46,7 +46,7 @@ namespace OpenSim.Grid.UserServer | |||
46 | 46 | ||
47 | public class UserLoginService : LoginService | 47 | public class UserLoginService : LoginService |
48 | { | 48 | { |
49 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 49 | protected static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
50 | 50 | ||
51 | protected IInterServiceInventoryServices m_inventoryService; | 51 | protected IInterServiceInventoryServices m_inventoryService; |
52 | 52 | ||
diff --git a/OpenSim/Grid/UserServer/UserManager.cs b/OpenSim/Grid/UserServer/UserManager.cs index f8f9f39..76f83b7 100644 --- a/OpenSim/Grid/UserServer/UserManager.cs +++ b/OpenSim/Grid/UserServer/UserManager.cs | |||
@@ -42,7 +42,7 @@ namespace OpenSim.Grid.UserServer | |||
42 | 42 | ||
43 | public class UserManager : UserManagerBase | 43 | public class UserManager : UserManagerBase |
44 | { | 44 | { |
45 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 45 | protected static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
46 | 46 | ||
47 | public event logOffUser OnLogOffUser; | 47 | public event logOffUser OnLogOffUser; |
48 | private logOffUser handlerLogOffUser; | 48 | private logOffUser handlerLogOffUser; |