diff options
author | Diva Canto | 2010-05-05 16:54:48 -0700 |
---|---|---|
committer | Diva Canto | 2010-05-05 16:54:48 -0700 |
commit | ebc3726d52c772962cfa551721168079d5d563d2 (patch) | |
tree | 69bfd8d39e32a3fabb0709c5f05343554c2c357e /OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups | |
parent | Stab a test fail (diff) | |
download | opensim-SC_OLD-ebc3726d52c772962cfa551721168079d5d563d2.zip opensim-SC_OLD-ebc3726d52c772962cfa551721168079d5d563d2.tar.gz opensim-SC_OLD-ebc3726d52c772962cfa551721168079d5d563d2.tar.bz2 opensim-SC_OLD-ebc3726d52c772962cfa551721168079d5d563d2.tar.xz |
Added copying of Viewer field to the agent circuit data that is being passed on TPs and crossings.
(XmlRpcGroups files want to be committed too)
Diffstat (limited to 'OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups')
-rw-r--r-- | OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs | 62 | ||||
-rw-r--r-- | OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/SimianGroupsServicesConnectorModule.cs | 150 |
2 files changed, 106 insertions, 106 deletions
diff --git a/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs b/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs index 6b942cb..b2b8110 100644 --- a/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs +++ b/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/GroupsModule.cs | |||
@@ -601,14 +601,14 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
601 | public List<GroupMembersData> GroupMembersRequest(IClientAPI remoteClient, UUID groupID) | 601 | public List<GroupMembersData> GroupMembersRequest(IClientAPI remoteClient, UUID groupID) |
602 | { | 602 | { |
603 | if (m_debugEnabled) m_log.DebugFormat("[GROUPS]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name); | 603 | if (m_debugEnabled) m_log.DebugFormat("[GROUPS]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name); |
604 | List<GroupMembersData> data = m_groupData.GetGroupMembers(GetRequestingAgentID(remoteClient), groupID); | 604 | List<GroupMembersData> data = m_groupData.GetGroupMembers(GetRequestingAgentID(remoteClient), groupID); |
605 | 605 | ||
606 | if (m_debugEnabled) | 606 | if (m_debugEnabled) |
607 | { | 607 | { |
608 | foreach (GroupMembersData member in data) | 608 | foreach (GroupMembersData member in data) |
609 | { | 609 | { |
610 | m_log.DebugFormat("[GROUPS]: Member({0}) - IsOwner({1})", member.AgentID, member.IsOwner); | 610 | m_log.DebugFormat("[GROUPS]: Member({0}) - IsOwner({1})", member.AgentID, member.IsOwner); |
611 | } | 611 | } |
612 | } | 612 | } |
613 | 613 | ||
614 | return data; | 614 | return data; |
@@ -628,14 +628,14 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
628 | { | 628 | { |
629 | if (m_debugEnabled) m_log.DebugFormat("[GROUPS]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name); | 629 | if (m_debugEnabled) m_log.DebugFormat("[GROUPS]: {0} called", System.Reflection.MethodBase.GetCurrentMethod().Name); |
630 | 630 | ||
631 | List<GroupRoleMembersData> data = m_groupData.GetGroupRoleMembers(GetRequestingAgentID(remoteClient), groupID); | 631 | List<GroupRoleMembersData> data = m_groupData.GetGroupRoleMembers(GetRequestingAgentID(remoteClient), groupID); |
632 | 632 | ||
633 | if (m_debugEnabled) | 633 | if (m_debugEnabled) |
634 | { | 634 | { |
635 | foreach (GroupRoleMembersData member in data) | 635 | foreach (GroupRoleMembersData member in data) |
636 | { | 636 | { |
637 | m_log.DebugFormat("[GROUPS]: Member({0}) - Role({1})", member.MemberID, member.RoleID); | 637 | m_log.DebugFormat("[GROUPS]: Member({0}) - Role({1})", member.MemberID, member.RoleID); |
638 | } | 638 | } |
639 | } | 639 | } |
640 | return data; | 640 | return data; |
641 | } | 641 | } |
@@ -1144,11 +1144,11 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1144 | OSDMap llDataStruct = new OSDMap(3); | 1144 | OSDMap llDataStruct = new OSDMap(3); |
1145 | llDataStruct.Add("AgentData", AgentData); | 1145 | llDataStruct.Add("AgentData", AgentData); |
1146 | llDataStruct.Add("GroupData", GroupData); | 1146 | llDataStruct.Add("GroupData", GroupData); |
1147 | llDataStruct.Add("NewGroupData", NewGroupData); | 1147 | llDataStruct.Add("NewGroupData", NewGroupData); |
1148 | 1148 | ||
1149 | if (m_debugEnabled) | 1149 | if (m_debugEnabled) |
1150 | { | 1150 | { |
1151 | m_log.InfoFormat("[GROUPS]: {0}", OSDParser.SerializeJsonString(llDataStruct)); | 1151 | m_log.InfoFormat("[GROUPS]: {0}", OSDParser.SerializeJsonString(llDataStruct)); |
1152 | } | 1152 | } |
1153 | 1153 | ||
1154 | IEventQueue queue = remoteClient.Scene.RequestModuleInterface<IEventQueue>(); | 1154 | IEventQueue queue = remoteClient.Scene.RequestModuleInterface<IEventQueue>(); |
@@ -1308,16 +1308,16 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1308 | // | 1308 | // |
1309 | } | 1309 | } |
1310 | 1310 | ||
1311 | #endregion | 1311 | #endregion |
1312 | 1312 | ||
1313 | private UUID GetRequestingAgentID(IClientAPI client) | 1313 | private UUID GetRequestingAgentID(IClientAPI client) |
1314 | { | 1314 | { |
1315 | UUID requestingAgentID = UUID.Zero; | 1315 | UUID requestingAgentID = UUID.Zero; |
1316 | if (client != null) | 1316 | if (client != null) |
1317 | { | 1317 | { |
1318 | requestingAgentID = client.AgentId; | 1318 | requestingAgentID = client.AgentId; |
1319 | } | 1319 | } |
1320 | return requestingAgentID; | 1320 | return requestingAgentID; |
1321 | } | 1321 | } |
1322 | } | 1322 | } |
1323 | 1323 | ||
diff --git a/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/SimianGroupsServicesConnectorModule.cs b/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/SimianGroupsServicesConnectorModule.cs index 590753e..bc05b0f 100644 --- a/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/SimianGroupsServicesConnectorModule.cs +++ b/OpenSim/Region/OptionalModules/Avatar/XmlRpcGroups/SimianGroupsServicesConnectorModule.cs | |||
@@ -288,8 +288,8 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
288 | 288 | ||
289 | if(SimianAddGeneric(GroupID, "Group", name, GroupInfoMap)) | 289 | if(SimianAddGeneric(GroupID, "Group", name, GroupInfoMap)) |
290 | { | 290 | { |
291 | AddGroupRole(requestingAgentID, GroupID, UUID.Zero, "Everyone", "Members of " + name, "Member of " + name, (ulong)m_DefaultEveryonePowers); | 291 | AddGroupRole(requestingAgentID, GroupID, UUID.Zero, "Everyone", "Members of " + name, "Member of " + name, (ulong)m_DefaultEveryonePowers); |
292 | AddGroupRole(requestingAgentID, GroupID, OwnerRoleID, "Owners", "Owners of " + name, "Owner of " + name, (ulong)m_DefaultOwnerPowers); | 292 | AddGroupRole(requestingAgentID, GroupID, OwnerRoleID, "Owners", "Owners of " + name, "Owner of " + name, (ulong)m_DefaultOwnerPowers); |
293 | 293 | ||
294 | AddAgentToGroup(requestingAgentID, requestingAgentID, GroupID, OwnerRoleID); | 294 | AddAgentToGroup(requestingAgentID, requestingAgentID, GroupID, OwnerRoleID); |
295 | 295 | ||
@@ -413,7 +413,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
413 | } | 413 | } |
414 | } | 414 | } |
415 | else if ((groupName != null) && (groupName != string.Empty)) | 415 | else if ((groupName != null) && (groupName != string.Empty)) |
416 | { | 416 | { |
417 | if (!SimianGetFirstGenericEntry("Group", groupName, out groupID, out GroupInfoMap)) | 417 | if (!SimianGetFirstGenericEntry("Group", groupName, out groupID, out GroupInfoMap)) |
418 | { | 418 | { |
419 | return null; | 419 | return null; |
@@ -422,7 +422,7 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
422 | 422 | ||
423 | GroupRecord GroupInfo = new GroupRecord(); | 423 | GroupRecord GroupInfo = new GroupRecord(); |
424 | 424 | ||
425 | GroupInfo.GroupID = groupID; | 425 | GroupInfo.GroupID = groupID; |
426 | GroupInfo.GroupName = groupName; | 426 | GroupInfo.GroupName = groupName; |
427 | GroupInfo.Charter = GroupInfoMap["Charter"].AsString(); | 427 | GroupInfo.Charter = GroupInfoMap["Charter"].AsString(); |
428 | GroupInfo.ShowInList = GroupInfoMap["ShowInList"].AsBoolean(); | 428 | GroupInfo.ShowInList = GroupInfoMap["ShowInList"].AsBoolean(); |
@@ -751,9 +751,9 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
751 | if (SimianGetGenericEntry(agentID, "Group", "ActiveGroup", out UserActiveGroup)) | 751 | if (SimianGetGenericEntry(agentID, "Group", "ActiveGroup", out UserActiveGroup)) |
752 | { | 752 | { |
753 | GroupID = UserActiveGroup["GroupID"].AsUUID(); | 753 | GroupID = UserActiveGroup["GroupID"].AsUUID(); |
754 | } | 754 | } |
755 | 755 | ||
756 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Active GroupID : {0}", GroupID.ToString()); | 756 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Active GroupID : {0}", GroupID.ToString()); |
757 | return GetAgentGroupMembership(requestingAgentID, agentID, GroupID); | 757 | return GetAgentGroupMembership(requestingAgentID, agentID, GroupID); |
758 | } | 758 | } |
759 | 759 | ||
@@ -781,24 +781,24 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
781 | 781 | ||
782 | List<GroupRolesData> Roles = new List<GroupRolesData>(); | 782 | List<GroupRolesData> Roles = new List<GroupRolesData>(); |
783 | 783 | ||
784 | Dictionary<string, OSDMap> GroupRoles; | 784 | Dictionary<string, OSDMap> GroupRoles; |
785 | if (SimianGetGenericEntries(groupID, "GroupRole", out GroupRoles)) | 785 | if (SimianGetGenericEntries(groupID, "GroupRole", out GroupRoles)) |
786 | { | 786 | { |
787 | Dictionary<string, OSDMap> MemberRoles; | 787 | Dictionary<string, OSDMap> MemberRoles; |
788 | if (SimianGetGenericEntries(agentID, "GroupRole" + groupID.ToString(), out MemberRoles)) | 788 | if (SimianGetGenericEntries(agentID, "GroupRole" + groupID.ToString(), out MemberRoles)) |
789 | { | 789 | { |
790 | foreach (KeyValuePair<string, OSDMap> kvp in MemberRoles) | 790 | foreach (KeyValuePair<string, OSDMap> kvp in MemberRoles) |
791 | { | 791 | { |
792 | GroupRolesData data = new GroupRolesData(); | 792 | GroupRolesData data = new GroupRolesData(); |
793 | data.RoleID = UUID.Parse(kvp.Key); | 793 | data.RoleID = UUID.Parse(kvp.Key); |
794 | data.Name = GroupRoles[kvp.Key]["Name"].AsString(); | 794 | data.Name = GroupRoles[kvp.Key]["Name"].AsString(); |
795 | data.Description = GroupRoles[kvp.Key]["Description"].AsString(); | 795 | data.Description = GroupRoles[kvp.Key]["Description"].AsString(); |
796 | data.Title = GroupRoles[kvp.Key]["Title"].AsString(); | 796 | data.Title = GroupRoles[kvp.Key]["Title"].AsString(); |
797 | data.Powers = GroupRoles[kvp.Key]["Powers"].AsULong(); | 797 | data.Powers = GroupRoles[kvp.Key]["Powers"].AsULong(); |
798 | 798 | ||
799 | Roles.Add(data); | 799 | Roles.Add(data); |
800 | } | 800 | } |
801 | } | 801 | } |
802 | } | 802 | } |
803 | return Roles; | 803 | return Roles; |
804 | } | 804 | } |
@@ -912,8 +912,8 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
912 | { | 912 | { |
913 | foreach( KeyValuePair<UUID, OSDMap> GroupRoleMember in GroupRoleMembers ) | 913 | foreach( KeyValuePair<UUID, OSDMap> GroupRoleMember in GroupRoleMembers ) |
914 | { | 914 | { |
915 | GroupRoleMembersData data = new GroupRoleMembersData(); | 915 | GroupRoleMembersData data = new GroupRoleMembersData(); |
916 | 916 | ||
917 | data.MemberID = GroupRoleMember.Key; | 917 | data.MemberID = GroupRoleMember.Key; |
918 | data.RoleID = UUID.Parse(Role.Key); | 918 | data.RoleID = UUID.Parse(Role.Key); |
919 | 919 | ||
@@ -1066,20 +1066,20 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1066 | OSDMap Response = WebUtil.PostToService(m_serviceURL, RequestArgs); | 1066 | OSDMap Response = WebUtil.PostToService(m_serviceURL, RequestArgs); |
1067 | if (Response["Success"].AsBoolean() && Response["Entries"] is OSDArray) | 1067 | if (Response["Success"].AsBoolean() && Response["Entries"] is OSDArray) |
1068 | { | 1068 | { |
1069 | OSDArray entryArray = (OSDArray)Response["Entries"]; | 1069 | OSDArray entryArray = (OSDArray)Response["Entries"]; |
1070 | if (entryArray.Count >= 1) | 1070 | if (entryArray.Count >= 1) |
1071 | { | 1071 | { |
1072 | OSDMap entryMap = entryArray[0] as OSDMap; | 1072 | OSDMap entryMap = entryArray[0] as OSDMap; |
1073 | key = entryMap["Key"].AsString(); | 1073 | key = entryMap["Key"].AsString(); |
1074 | map = (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString()); | 1074 | map = (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString()); |
1075 | 1075 | ||
1076 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); | 1076 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); |
1077 | 1077 | ||
1078 | return true; | 1078 | return true; |
1079 | } | 1079 | } |
1080 | else | 1080 | else |
1081 | { | 1081 | { |
1082 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); | 1082 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); |
1083 | } | 1083 | } |
1084 | } | 1084 | } |
1085 | else | 1085 | else |
@@ -1106,20 +1106,20 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1106 | OSDMap Response = WebUtil.PostToService(m_serviceURL, RequestArgs); | 1106 | OSDMap Response = WebUtil.PostToService(m_serviceURL, RequestArgs); |
1107 | if (Response["Success"].AsBoolean() && Response["Entries"] is OSDArray) | 1107 | if (Response["Success"].AsBoolean() && Response["Entries"] is OSDArray) |
1108 | { | 1108 | { |
1109 | OSDArray entryArray = (OSDArray)Response["Entries"]; | 1109 | OSDArray entryArray = (OSDArray)Response["Entries"]; |
1110 | if (entryArray.Count >= 1) | 1110 | if (entryArray.Count >= 1) |
1111 | { | 1111 | { |
1112 | OSDMap entryMap = entryArray[0] as OSDMap; | 1112 | OSDMap entryMap = entryArray[0] as OSDMap; |
1113 | ownerID = entryMap["OwnerID"].AsUUID(); | 1113 | ownerID = entryMap["OwnerID"].AsUUID(); |
1114 | map = (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString()); | 1114 | map = (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString()); |
1115 | 1115 | ||
1116 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); | 1116 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); |
1117 | 1117 | ||
1118 | return true; | 1118 | return true; |
1119 | } | 1119 | } |
1120 | else | 1120 | else |
1121 | { | 1121 | { |
1122 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); | 1122 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); |
1123 | } | 1123 | } |
1124 | } | 1124 | } |
1125 | else | 1125 | else |
@@ -1152,16 +1152,16 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1152 | { | 1152 | { |
1153 | OSDMap entryMap = entryArray[0] as OSDMap; | 1153 | OSDMap entryMap = entryArray[0] as OSDMap; |
1154 | key = entryMap["Key"].AsString(); | 1154 | key = entryMap["Key"].AsString(); |
1155 | map = (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString()); | 1155 | map = (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString()); |
1156 | 1156 | ||
1157 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); | 1157 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); |
1158 | 1158 | ||
1159 | return true; | 1159 | return true; |
1160 | } | 1160 | } |
1161 | else | 1161 | else |
1162 | { | 1162 | { |
1163 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); | 1163 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); |
1164 | } | 1164 | } |
1165 | } | 1165 | } |
1166 | else | 1166 | else |
1167 | { | 1167 | { |
@@ -1191,13 +1191,13 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1191 | 1191 | ||
1192 | OSDArray entryArray = (OSDArray)response["Entries"]; | 1192 | OSDArray entryArray = (OSDArray)response["Entries"]; |
1193 | foreach (OSDMap entryMap in entryArray) | 1193 | foreach (OSDMap entryMap in entryArray) |
1194 | { | 1194 | { |
1195 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); | 1195 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); |
1196 | maps.Add(entryMap["Key"].AsString(), (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString())); | 1196 | maps.Add(entryMap["Key"].AsString(), (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString())); |
1197 | } | 1197 | } |
1198 | if(maps.Count == 0) | 1198 | if(maps.Count == 0) |
1199 | { | 1199 | { |
1200 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); | 1200 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); |
1201 | } | 1201 | } |
1202 | 1202 | ||
1203 | return true; | 1203 | return true; |
@@ -1229,14 +1229,14 @@ namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups | |||
1229 | 1229 | ||
1230 | OSDArray entryArray = (OSDArray)response["Entries"]; | 1230 | OSDArray entryArray = (OSDArray)response["Entries"]; |
1231 | foreach (OSDMap entryMap in entryArray) | 1231 | foreach (OSDMap entryMap in entryArray) |
1232 | { | 1232 | { |
1233 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); | 1233 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] Generics Result {0}", entryMap["Value"].AsString()); |
1234 | maps.Add(entryMap["OwnerID"].AsUUID(), (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString())); | 1234 | maps.Add(entryMap["OwnerID"].AsUUID(), (OSDMap)OSDParser.DeserializeJson(entryMap["Value"].AsString())); |
1235 | } | 1235 | } |
1236 | if (maps.Count == 0) | 1236 | if (maps.Count == 0) |
1237 | { | 1237 | { |
1238 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); | 1238 | if (m_debugEnabled) m_log.InfoFormat("[SIMIAN-GROUPS-CONNECTOR] No Generics Results"); |
1239 | } | 1239 | } |
1240 | return true; | 1240 | return true; |
1241 | } | 1241 | } |
1242 | else | 1242 | else |