diff options
author | Diva Canto | 2010-03-05 21:36:45 -0800 |
---|---|---|
committer | Diva Canto | 2010-03-05 21:36:45 -0800 |
commit | 5171464ac199f958a9a8a11664958260a88e863d (patch) | |
tree | 97f70afe241e8761d496d5f54acb5e5eae8d7495 /OpenSim | |
parent | refactor: Move DetachSingleAttachmentToInv to region module (diff) | |
download | opensim-SC_OLD-5171464ac199f958a9a8a11664958260a88e863d.zip opensim-SC_OLD-5171464ac199f958a9a8a11664958260a88e863d.tar.gz opensim-SC_OLD-5171464ac199f958a9a8a11664958260a88e863d.tar.bz2 opensim-SC_OLD-5171464ac199f958a9a8a11664958260a88e863d.tar.xz |
Justin, I must have been dyslexic when I wrote UserGridService as the name for it. GridUserService makes more sense; it's the user of the grid, "grid user". I changed it everywhere.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Data/IGridUserData.cs (renamed from OpenSim/Data/IUserGridData.cs) | 8 | ||||
-rw-r--r-- | OpenSim/Data/MySQL/MySQLGridUserData.cs (renamed from OpenSim/Data/MySQL/MySQLUserGridData.cs) | 10 | ||||
-rw-r--r-- | OpenSim/Region/CoreModules/ServiceConnectorsOut/GridUser/LocalGridUserServiceConnector.cs (renamed from OpenSim/Region/CoreModules/ServiceConnectorsOut/UserGrid/LocalUserGridServiceConnector.cs) | 32 | ||||
-rw-r--r-- | OpenSim/Services/Connectors/GridUser/GridUserServiceConnector.cs (renamed from OpenSim/Services/Connectors/UserGrid/UserGridServiceConnector.cs) | 4 | ||||
-rw-r--r-- | OpenSim/Services/Interfaces/IGridUserService.cs (renamed from OpenSim/Services/Interfaces/IUserGridService.cs) | 12 | ||||
-rw-r--r-- | OpenSim/Services/UserAccountService/GridUserService.cs (renamed from OpenSim/Services/UserAccountService/UserGridService.cs) | 16 | ||||
-rw-r--r-- | OpenSim/Services/UserAccountService/GridUserServiceBase.cs (renamed from OpenSim/Services/UserAccountService/UserGridServiceBase.cs) | 14 |
7 files changed, 48 insertions, 48 deletions
diff --git a/OpenSim/Data/IUserGridData.cs b/OpenSim/Data/IGridUserData.cs index 6f7467e..abd2cef 100644 --- a/OpenSim/Data/IUserGridData.cs +++ b/OpenSim/Data/IGridUserData.cs | |||
@@ -33,7 +33,7 @@ using OpenSim.Framework; | |||
33 | namespace OpenSim.Data | 33 | namespace OpenSim.Data |
34 | { | 34 | { |
35 | // This MUST be a ref type! | 35 | // This MUST be a ref type! |
36 | public class UserGridData | 36 | public class GridUserData |
37 | { | 37 | { |
38 | public string UserID; | 38 | public string UserID; |
39 | public Dictionary<string, string> Data; | 39 | public Dictionary<string, string> Data; |
@@ -42,9 +42,9 @@ namespace OpenSim.Data | |||
42 | /// <summary> | 42 | /// <summary> |
43 | /// An interface for connecting to the user grid datastore | 43 | /// An interface for connecting to the user grid datastore |
44 | /// </summary> | 44 | /// </summary> |
45 | public interface IUserGridData | 45 | public interface IGridUserData |
46 | { | 46 | { |
47 | UserGridData GetUserGridData(string userID); | 47 | GridUserData GetGridUserData(string userID); |
48 | bool StoreUserGridData(UserGridData data); | 48 | bool StoreGridUserData(GridUserData data); |
49 | } | 49 | } |
50 | } \ No newline at end of file | 50 | } \ No newline at end of file |
diff --git a/OpenSim/Data/MySQL/MySQLUserGridData.cs b/OpenSim/Data/MySQL/MySQLGridUserData.cs index 7209b18..15834d2 100644 --- a/OpenSim/Data/MySQL/MySQLUserGridData.cs +++ b/OpenSim/Data/MySQL/MySQLGridUserData.cs | |||
@@ -40,15 +40,15 @@ namespace OpenSim.Data.MySQL | |||
40 | /// <summary> | 40 | /// <summary> |
41 | /// A MySQL Interface for user grid data | 41 | /// A MySQL Interface for user grid data |
42 | /// </summary> | 42 | /// </summary> |
43 | public class MySQLUserGridData : MySQLGenericTableHandler<UserGridData>, IUserGridData | 43 | public class MySQLGridUserData : MySQLGenericTableHandler<GridUserData>, IGridUserData |
44 | { | 44 | { |
45 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 45 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
46 | 46 | ||
47 | public MySQLUserGridData(string connectionString, string realm) : base(connectionString, realm, "UserGrid") {} | 47 | public MySQLGridUserData(string connectionString, string realm) : base(connectionString, realm, "UserGrid") {} |
48 | 48 | ||
49 | public UserGridData GetUserGridData(string userID) | 49 | public GridUserData GetGridUserData(string userID) |
50 | { | 50 | { |
51 | UserGridData[] ret = Get("UserID", userID); | 51 | GridUserData[] ret = Get("UserID", userID); |
52 | 52 | ||
53 | if (ret.Length == 0) | 53 | if (ret.Length == 0) |
54 | return null; | 54 | return null; |
@@ -56,7 +56,7 @@ namespace OpenSim.Data.MySQL | |||
56 | return ret[0]; | 56 | return ret[0]; |
57 | } | 57 | } |
58 | 58 | ||
59 | public bool StoreUserGridData(UserGridData data) | 59 | public bool StoreGridUserData(GridUserData data) |
60 | { | 60 | { |
61 | return Store(data); | 61 | return Store(data); |
62 | } | 62 | } |
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserGrid/LocalUserGridServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/GridUser/LocalGridUserServiceConnector.cs index f4309fe..d5fae23 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/UserGrid/LocalUserGridServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/GridUser/LocalGridUserServiceConnector.cs | |||
@@ -37,13 +37,13 @@ using OpenSim.Services.Interfaces; | |||
37 | 37 | ||
38 | using OpenMetaverse; | 38 | using OpenMetaverse; |
39 | 39 | ||
40 | namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserGrid | 40 | namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.GridUser |
41 | { | 41 | { |
42 | public class LocalUserGridServicesConnector : ISharedRegionModule, IUserGridService | 42 | public class LocalGridUserServicesConnector : ISharedRegionModule, IGridUserService |
43 | { | 43 | { |
44 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 44 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
45 | 45 | ||
46 | private IUserGridService m_service; | 46 | private IGridUserService m_service; |
47 | 47 | ||
48 | private bool m_Enabled = false; | 48 | private bool m_Enabled = false; |
49 | 49 | ||
@@ -54,7 +54,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserGrid | |||
54 | 54 | ||
55 | public string Name | 55 | public string Name |
56 | { | 56 | { |
57 | get { return "LocalUserGridServicesConnector"; } | 57 | get { return "LocalGridUserServicesConnector"; } |
58 | } | 58 | } |
59 | 59 | ||
60 | public void Initialise(IConfigSource source) | 60 | public void Initialise(IConfigSource source) |
@@ -62,13 +62,13 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserGrid | |||
62 | IConfig moduleConfig = source.Configs["Modules"]; | 62 | IConfig moduleConfig = source.Configs["Modules"]; |
63 | if (moduleConfig != null) | 63 | if (moduleConfig != null) |
64 | { | 64 | { |
65 | string name = moduleConfig.GetString("UserGridServices", ""); | 65 | string name = moduleConfig.GetString("GridUserServices", ""); |
66 | if (name == Name) | 66 | if (name == Name) |
67 | { | 67 | { |
68 | IConfig userConfig = source.Configs["UserGridService"]; | 68 | IConfig userConfig = source.Configs["GridUserService"]; |
69 | if (userConfig == null) | 69 | if (userConfig == null) |
70 | { | 70 | { |
71 | m_log.Error("[LOCAL USER GRID SERVICE CONNECTOR]: UserGridService missing from ini files"); | 71 | m_log.Error("[LOCAL GRID USER SERVICE CONNECTOR]: GridUserService missing from ini files"); |
72 | return; | 72 | return; |
73 | } | 73 | } |
74 | 74 | ||
@@ -76,20 +76,20 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserGrid | |||
76 | 76 | ||
77 | if (serviceDll == String.Empty) | 77 | if (serviceDll == String.Empty) |
78 | { | 78 | { |
79 | m_log.Error("[LOCAL USER GRID SERVICE CONNECTOR]: No LocalServiceModule named in section UserGridService"); | 79 | m_log.Error("[LOCAL GRID USER SERVICE CONNECTOR]: No LocalServiceModule named in section GridUserService"); |
80 | return; | 80 | return; |
81 | } | 81 | } |
82 | 82 | ||
83 | Object[] args = new Object[] { source }; | 83 | Object[] args = new Object[] { source }; |
84 | m_service = ServerUtils.LoadPlugin<IUserGridService>(serviceDll, args); | 84 | m_service = ServerUtils.LoadPlugin<IGridUserService>(serviceDll, args); |
85 | 85 | ||
86 | if (m_service == null) | 86 | if (m_service == null) |
87 | { | 87 | { |
88 | m_log.Error("[LOCAL USER GRID SERVICE CONNECTOR]: Can't load UserGrid service"); | 88 | m_log.Error("[LOCAL GRID USER SERVICE CONNECTOR]: Can't load GridUser service"); |
89 | return; | 89 | return; |
90 | } | 90 | } |
91 | m_Enabled = true; | 91 | m_Enabled = true; |
92 | m_log.Info("[LOCAL USER GRID SERVICE CONNECTOR]: Local UserGrid connector enabled"); | 92 | m_log.Info("[LOCAL GRID USER SERVICE CONNECTOR]: Local GridUser connector enabled"); |
93 | } | 93 | } |
94 | } | 94 | } |
95 | } | 95 | } |
@@ -111,7 +111,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserGrid | |||
111 | if (!m_Enabled) | 111 | if (!m_Enabled) |
112 | return; | 112 | return; |
113 | 113 | ||
114 | scene.RegisterModuleInterface<IUserGridService>(m_service); | 114 | scene.RegisterModuleInterface<IGridUserService>(m_service); |
115 | } | 115 | } |
116 | 116 | ||
117 | public void RemoveRegion(Scene scene) | 117 | public void RemoveRegion(Scene scene) |
@@ -126,14 +126,14 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.UserGrid | |||
126 | return; | 126 | return; |
127 | } | 127 | } |
128 | 128 | ||
129 | public UserGridInfo GetUserGridInfo(string userID) | 129 | public GridUserInfo GetGridUserInfo(string userID) |
130 | { | 130 | { |
131 | return m_service.GetUserGridInfo(userID); | 131 | return m_service.GetGridUserInfo(userID); |
132 | } | 132 | } |
133 | 133 | ||
134 | public bool StoreUserGridInfo(UserGridInfo info) | 134 | public bool StoreGridUserInfo(GridUserInfo info) |
135 | { | 135 | { |
136 | return m_service.StoreUserGridInfo(info); | 136 | return m_service.StoreGridUserInfo(info); |
137 | } | 137 | } |
138 | } | 138 | } |
139 | } \ No newline at end of file | 139 | } \ No newline at end of file |
diff --git a/OpenSim/Services/Connectors/UserGrid/UserGridServiceConnector.cs b/OpenSim/Services/Connectors/GridUser/GridUserServiceConnector.cs index 3aa8940..ce88236 100644 --- a/OpenSim/Services/Connectors/UserGrid/UserGridServiceConnector.cs +++ b/OpenSim/Services/Connectors/GridUser/GridUserServiceConnector.cs | |||
@@ -29,9 +29,9 @@ using System; | |||
29 | 29 | ||
30 | namespace OpenSim.Services.Connectors | 30 | namespace OpenSim.Services.Connectors |
31 | { | 31 | { |
32 | public class UserGridServiceConnector | 32 | public class GridUserServiceConnector |
33 | { | 33 | { |
34 | public UserGridServiceConnector() | 34 | public GridUserServiceConnector() |
35 | { | 35 | { |
36 | } | 36 | } |
37 | } | 37 | } |
diff --git a/OpenSim/Services/Interfaces/IUserGridService.cs b/OpenSim/Services/Interfaces/IGridUserService.cs index 50134e0..a7c2c6f 100644 --- a/OpenSim/Services/Interfaces/IUserGridService.cs +++ b/OpenSim/Services/Interfaces/IGridUserService.cs | |||
@@ -34,16 +34,16 @@ namespace OpenSim.Services.Interfaces | |||
34 | /// <summary> | 34 | /// <summary> |
35 | /// Records user information specific to a grid but which is not part of a user's account. | 35 | /// Records user information specific to a grid but which is not part of a user's account. |
36 | /// </summary> | 36 | /// </summary> |
37 | public class UserGridInfo | 37 | public class GridUserInfo |
38 | { | 38 | { |
39 | public string UserID; | 39 | public string UserID; |
40 | public UUID HomeRegionID; | 40 | public UUID HomeRegionID; |
41 | public Vector3 HomePosition; | 41 | public Vector3 HomePosition; |
42 | public Vector3 HomeLookAt; | 42 | public Vector3 HomeLookAt; |
43 | 43 | ||
44 | public UserGridInfo() {} | 44 | public GridUserInfo() {} |
45 | 45 | ||
46 | public UserGridInfo(Dictionary<string, object> kvp) | 46 | public GridUserInfo(Dictionary<string, object> kvp) |
47 | { | 47 | { |
48 | if (kvp.ContainsKey("UserID")) | 48 | if (kvp.ContainsKey("UserID")) |
49 | UserID = kvp["UserID"].ToString(); | 49 | UserID = kvp["UserID"].ToString(); |
@@ -67,9 +67,9 @@ namespace OpenSim.Services.Interfaces | |||
67 | } | 67 | } |
68 | } | 68 | } |
69 | 69 | ||
70 | public interface IUserGridService | 70 | public interface IGridUserService |
71 | { | 71 | { |
72 | UserGridInfo GetUserGridInfo(string userID); | 72 | GridUserInfo GetGridUserInfo(string userID); |
73 | bool StoreUserGridInfo(UserGridInfo info); | 73 | bool StoreGridUserInfo(GridUserInfo info); |
74 | } | 74 | } |
75 | } \ No newline at end of file | 75 | } \ No newline at end of file |
diff --git a/OpenSim/Services/UserAccountService/UserGridService.cs b/OpenSim/Services/UserAccountService/GridUserService.cs index 2d28b33..36cce75 100644 --- a/OpenSim/Services/UserAccountService/UserGridService.cs +++ b/OpenSim/Services/UserAccountService/GridUserService.cs | |||
@@ -39,20 +39,20 @@ using log4net; | |||
39 | 39 | ||
40 | namespace OpenSim.Services.UserAccountService | 40 | namespace OpenSim.Services.UserAccountService |
41 | { | 41 | { |
42 | public class UserGridService : UserGridServiceBase, IUserGridService | 42 | public class GridUserService : GridUserServiceBase, IGridUserService |
43 | { | 43 | { |
44 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 44 | private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
45 | 45 | ||
46 | public UserGridService(IConfigSource config) : base(config) | 46 | public GridUserService(IConfigSource config) : base(config) |
47 | { | 47 | { |
48 | m_log.Debug("[USER GRID SERVICE]: Starting user grid service"); | 48 | m_log.Debug("[USER GRID SERVICE]: Starting user grid service"); |
49 | } | 49 | } |
50 | 50 | ||
51 | public UserGridInfo GetUserGridInfo(string userID) | 51 | public GridUserInfo GetGridUserInfo(string userID) |
52 | { | 52 | { |
53 | UserGridData d = m_Database.GetUserGridData(userID); | 53 | GridUserData d = m_Database.GetGridUserData(userID); |
54 | 54 | ||
55 | UserGridInfo info = new UserGridInfo(); | 55 | GridUserInfo info = new GridUserInfo(); |
56 | info.UserID = d.UserID; | 56 | info.UserID = d.UserID; |
57 | info.HomeRegionID = new UUID(d.Data["HomeRegionID"]); | 57 | info.HomeRegionID = new UUID(d.Data["HomeRegionID"]); |
58 | info.HomePosition = Vector3.Parse(d.Data["HomePosition"]); | 58 | info.HomePosition = Vector3.Parse(d.Data["HomePosition"]); |
@@ -61,16 +61,16 @@ namespace OpenSim.Services.UserAccountService | |||
61 | return info; | 61 | return info; |
62 | } | 62 | } |
63 | 63 | ||
64 | public bool StoreUserGridInfo(UserGridInfo info) | 64 | public bool StoreGridUserInfo(GridUserInfo info) |
65 | { | 65 | { |
66 | UserGridData d = new UserGridData(); | 66 | GridUserData d = new GridUserData(); |
67 | 67 | ||
68 | d.Data["UserID"] = info.UserID; | 68 | d.Data["UserID"] = info.UserID; |
69 | d.Data["HomeRegionID"] = info.HomeRegionID.ToString(); | 69 | d.Data["HomeRegionID"] = info.HomeRegionID.ToString(); |
70 | d.Data["HomePosition"] = info.HomePosition.ToString(); | 70 | d.Data["HomePosition"] = info.HomePosition.ToString(); |
71 | d.Data["HomeLookAt"] = info.HomeLookAt.ToString(); | 71 | d.Data["HomeLookAt"] = info.HomeLookAt.ToString(); |
72 | 72 | ||
73 | return m_Database.StoreUserGridData(d); | 73 | return m_Database.StoreGridUserData(d); |
74 | } | 74 | } |
75 | } | 75 | } |
76 | } \ No newline at end of file | 76 | } \ No newline at end of file |
diff --git a/OpenSim/Services/UserAccountService/UserGridServiceBase.cs b/OpenSim/Services/UserAccountService/GridUserServiceBase.cs index 80aaa49..990cb63 100644 --- a/OpenSim/Services/UserAccountService/UserGridServiceBase.cs +++ b/OpenSim/Services/UserAccountService/GridUserServiceBase.cs | |||
@@ -35,15 +35,15 @@ using OpenSim.Services.Base; | |||
35 | 35 | ||
36 | namespace OpenSim.Services.UserAccountService | 36 | namespace OpenSim.Services.UserAccountService |
37 | { | 37 | { |
38 | public class UserGridServiceBase : ServiceBase | 38 | public class GridUserServiceBase : ServiceBase |
39 | { | 39 | { |
40 | protected IUserGridData m_Database = null; | 40 | protected IGridUserData m_Database = null; |
41 | 41 | ||
42 | public UserGridServiceBase(IConfigSource config) : base(config) | 42 | public GridUserServiceBase(IConfigSource config) : base(config) |
43 | { | 43 | { |
44 | string dllName = String.Empty; | 44 | string dllName = String.Empty; |
45 | string connString = String.Empty; | 45 | string connString = String.Empty; |
46 | string realm = "UserGrid"; | 46 | string realm = "GridUser"; |
47 | 47 | ||
48 | // | 48 | // |
49 | // Try reading the [DatabaseService] section, if it exists | 49 | // Try reading the [DatabaseService] section, if it exists |
@@ -58,9 +58,9 @@ namespace OpenSim.Services.UserAccountService | |||
58 | } | 58 | } |
59 | 59 | ||
60 | // | 60 | // |
61 | // [PresenceService] section overrides [DatabaseService], if it exists | 61 | // [GridUsetService] section overrides [DatabaseService], if it exists |
62 | // | 62 | // |
63 | IConfig presenceConfig = config.Configs["PresenceService"]; | 63 | IConfig presenceConfig = config.Configs["GridUserService"]; |
64 | if (presenceConfig != null) | 64 | if (presenceConfig != null) |
65 | { | 65 | { |
66 | dllName = presenceConfig.GetString("StorageProvider", dllName); | 66 | dllName = presenceConfig.GetString("StorageProvider", dllName); |
@@ -74,7 +74,7 @@ namespace OpenSim.Services.UserAccountService | |||
74 | if (dllName.Equals(String.Empty)) | 74 | if (dllName.Equals(String.Empty)) |
75 | throw new Exception("No StorageProvider configured"); | 75 | throw new Exception("No StorageProvider configured"); |
76 | 76 | ||
77 | m_Database = LoadPlugin<IUserGridData>(dllName, new Object[] { connString, realm }); | 77 | m_Database = LoadPlugin<IGridUserData>(dllName, new Object[] { connString, realm }); |
78 | if (m_Database == null) | 78 | if (m_Database == null) |
79 | throw new Exception("Could not find a storage interface in the given module " + dllName); | 79 | throw new Exception("Could not find a storage interface in the given module " + dllName); |
80 | } | 80 | } |