OpenSim
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
IGroupsServicesConnector.cs
Go to the documentation of this file.
1 /*
2  * Copyright (c) Contributors, http://opensimulator.org/
3  * See CONTRIBUTORS.TXT for a full list of copyright holders.
4  *
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions are met:
7  * * Redistributions of source code must retain the above copyright
8  * notice, this list of conditions and the following disclaimer.
9  * * Redistributions in binary form must reproduce the above copyright
10  * notice, this list of conditions and the following disclaimer in the
11  * documentation and/or other materials provided with the distribution.
12  * * Neither the name of the OpenSimulator Project nor the
13  * names of its contributors may be used to endorse or promote products
14  * derived from this software without specific prior written permission.
15  *
16  * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
17  * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19  * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
20  * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26  */
27 
28 using System;
29 using System.Collections.Generic;
30 using OpenMetaverse;
31 using OpenSim.Framework;
32 
33 namespace OpenSim.Region.OptionalModules.Avatar.XmlRpcGroups
34 {
35  public interface IGroupsServicesConnector
36  {
37  UUID CreateGroup(UUID RequestingAgentID, string name, string charter, bool showInList, UUID insigniaID, int membershipFee, bool openEnrollment, bool allowPublish, bool maturePublish, UUID founderID);
38  void UpdateGroup(UUID RequestingAgentID, UUID groupID, string charter, bool showInList, UUID insigniaID, int membershipFee, bool openEnrollment, bool allowPublish, bool maturePublish);
39 
53  GroupRecord GetGroupRecord(UUID RequestingAgentID, UUID GroupID, string GroupName);
54 
55  List<DirGroupsReplyData> FindGroups(UUID RequestingAgentID, string search);
56  List<GroupMembersData> GetGroupMembers(UUID RequestingAgentID, UUID GroupID);
57 
58  void AddGroupRole(UUID RequestingAgentID, UUID groupID, UUID roleID, string name, string description, string title, ulong powers);
59  void UpdateGroupRole(UUID RequestingAgentID, UUID groupID, UUID roleID, string name, string description, string title, ulong powers);
60  void RemoveGroupRole(UUID RequestingAgentID, UUID groupID, UUID roleID);
61  List<GroupRolesData> GetGroupRoles(UUID RequestingAgentID, UUID GroupID);
62  List<GroupRoleMembersData> GetGroupRoleMembers(UUID RequestingAgentID, UUID GroupID);
63 
64  void AddAgentToGroup(UUID RequestingAgentID, UUID AgentID, UUID GroupID, UUID RoleID);
65  void RemoveAgentFromGroup(UUID RequestingAgentID, UUID AgentID, UUID GroupID);
66 
67  void AddAgentToGroupInvite(UUID RequestingAgentID, UUID inviteID, UUID groupID, UUID roleID, UUID agentID);
68  GroupInviteInfo GetAgentToGroupInvite(UUID RequestingAgentID, UUID inviteID);
69  void RemoveAgentToGroupInvite(UUID RequestingAgentID, UUID inviteID);
70 
71  void AddAgentToGroupRole(UUID RequestingAgentID, UUID AgentID, UUID GroupID, UUID RoleID);
72  void RemoveAgentFromGroupRole(UUID RequestingAgentID, UUID AgentID, UUID GroupID, UUID RoleID);
73  List<GroupRolesData> GetAgentGroupRoles(UUID RequestingAgentID, UUID AgentID, UUID GroupID);
74 
75  void SetAgentActiveGroup(UUID RequestingAgentID, UUID AgentID, UUID GroupID);
76  GroupMembershipData GetAgentActiveMembership(UUID RequestingAgentID, UUID AgentID);
77 
78  void SetAgentActiveGroupRole(UUID RequestingAgentID, UUID AgentID, UUID GroupID, UUID RoleID);
79  void SetAgentGroupInfo(UUID RequestingAgentID, UUID AgentID, UUID GroupID, bool AcceptNotices, bool ListInProfile);
80 
90  GroupMembershipData GetAgentGroupMembership(UUID RequestingAgentID, UUID AgentID, UUID GroupID);
91 
101  List<GroupMembershipData> GetAgentGroupMemberships(UUID RequestingAgentID, UUID AgentID);
102 
103  void AddGroupNotice(UUID RequestingAgentID, UUID groupID, UUID noticeID, string fromName, string subject, string message, byte[] binaryBucket);
104  GroupNoticeInfo GetGroupNotice(UUID RequestingAgentID, UUID noticeID);
105  List<GroupNoticeData> GetGroupNotices(UUID RequestingAgentID, UUID GroupID);
106 
107  void ResetAgentGroupChatSessions(UUID agentID);
108  bool hasAgentBeenInvitedToGroupChatSession(UUID agentID, UUID groupID);
109  bool hasAgentDroppedGroupChatSession(UUID agentID, UUID groupID);
110  void AgentDroppedFromGroupChatSession(UUID agentID, UUID groupID);
111  void AgentInvitedToGroupChatSession(UUID agentID, UUID groupID);
112  }
113 
114  public class GroupInviteInfo
115  {
116  public UUID GroupID = UUID.Zero;
117  public UUID RoleID = UUID.Zero;
118  public UUID AgentID = UUID.Zero;
119  public UUID InviteID = UUID.Zero;
120  }
121 }