C# Class OpenMetaverse.GroupManager

Handles all network traffic related to reading and writing group information
Show file Open project: 3di/3di-viewer-rei-libs Class Usage Examples

Public Properties

Property Type Description
GroupMembersCaches InternalDictionary>
GroupName2KeyCache string>.InternalDictionary
GroupRolesCaches InternalDictionary>
GroupRolesMembersCaches InternalDictionary>>

Public Methods

Method Description
ActivateGroup ( UUID id ) : void

Set a group as the current active group

ActivateTitle ( UUID group, UUID role ) : void

Change the role that determines your active title

AddToRole ( UUID group, UUID role, UUID member ) : void

Assign an avatar to a role

CreateRole ( UUID group, GroupRole role ) : void

Create a new group role

EjectUser ( UUID group, UUID member ) : void

Eject a user from a group

GroupManager ( GridClient client ) : System

Group Management Routines, Methods and Packet Handlers

Invite ( UUID group, List roles, UUID personkey ) : void

Invites a user to a group

LeaveGroup ( UUID groupID ) : void

Request to leave a group

Subscribe to OnGroupLeft event to receive confirmation

RemoveFromRole ( UUID group, UUID role, UUID member ) : void

Remove an avatar from a role

RequestCreateGroup ( Group group ) : void

Request to create a new group. If the group is successfully created, L$100 will automatically be deducted

Subscribe to OnGroupCreated event to receive confirmation.

RequestCurrentGroups ( ) : void

Request a current list of groups the avatar is a member of.

CAPS Event Queue must be running for this to work since the results come across CAPS.

RequestGroupAccountSummary ( UUID group, int intervalDays, int currentInterval ) : void

Begin to get the group account summary

Subscribe to the OnGroupAccountSummary event to receive the results.

RequestGroupMembers ( UUID group ) : UUID

Request a list of group members.

Subscribe to OnGroupMembers event to receive the results.

RequestGroupName ( UUID groupID ) : void

Lookup name of group based on groupID

RequestGroupNames ( List groupIDs ) : void

Request lookup of multiple group names

RequestGroupNotice ( UUID noticeID ) : void

Request a group notice by key

RequestGroupNoticeList ( UUID group ) : void

Request the group notices list

RequestGroupProfile ( UUID group ) : void

Lookup group profile data such as name, enrollment, founder, logo, etc

Subscribe to OnGroupProfile event to receive the results.

RequestGroupRoleMembers ( UUID group ) : UUID

Request members (members,role) role mapping for a group.

Subscribe to OnGroupRolesMembers event to receive the results.

RequestGroupRoles ( UUID group ) : UUID

Request group roles

Subscribe to OnGroupRoles event to receive the results.

RequestGroupTitles ( UUID group ) : UUID

Request a groups Titles

Subscribe to OnGroupTitles event to receive the results.

RequestJoinGroup ( UUID id ) : void

Request to join a group

Subscribe to OnGroupJoined event for confirmation.

SendGroupNotice ( UUID group, GroupNotice notice ) : void

Send out a group notice

SetGroupContribution ( UUID group, int contribution ) : void

Set this avatar's tier contribution

StartProposal ( UUID group, GroupProposal prop ) : void

Start a group proposal (vote)

UpdateGroup ( UUID id, Group group ) : void

Update a group's profile and other information

UpdateRole ( GroupRole role ) : void

Update role information

Private Methods

Method Description
AgentDropGroupHandler ( Packet packet, Simulator simulator ) : void
CreateGroupReplyHandler ( Packet packet, Simulator simulator ) : void
EjectGroupMemberReplyHandler ( Packet packet, Simulator simulator ) : void

Packet Handler for EjectGroupMemberReply, fired when an avatar is ejected from a group.

This is a silly packet, it doesn't provide you with the ejectees UUID

GroupAccountSummaryHandler ( Packet packet, Simulator simulator ) : void
GroupActiveProposalItemHandler ( Packet packet, Simulator simulator ) : void
GroupDataHandler ( Packet packet, Simulator simulator ) : void
GroupMembersHandler ( Packet packet, Simulator simulator ) : void
GroupNoticesListReplyHandler ( Packet packet, Simulator simulator ) : void
GroupProfileHandler ( Packet packet, Simulator simulator ) : void
GroupRoleDataHandler ( Packet packet, Simulator simulator ) : void
GroupRoleMembersHandler ( Packet packet, Simulator simulator ) : void
GroupTitlesHandler ( Packet packet, Simulator simulator ) : void
GroupVoteHistoryItemHandler ( Packet packet, Simulator simulator ) : void
JoinGroupReplyHandler ( Packet packet, Simulator simulator ) : void
LeaveGroupReplyHandler ( Packet packet, Simulator simulator ) : void
UUIDGroupNameReplyHandler ( Packet packet, Simulator simulator ) : void

Method Details

ActivateGroup() public method

Set a group as the current active group
public ActivateGroup ( UUID id ) : void
id UUID group ID (UUID)
return void

ActivateTitle() public method

Change the role that determines your active title
public ActivateTitle ( UUID group, UUID role ) : void
group UUID Group ID to use
role UUID Role ID to change to
return void

AddToRole() public method

Assign an avatar to a role
public AddToRole ( UUID group, UUID role, UUID member ) : void
group UUID Group ID to update
role UUID Role ID to assign to
member UUID Avatar's ID to assign to role
return void

CreateRole() public method

Create a new group role
public CreateRole ( UUID group, GroupRole role ) : void
group UUID Group ID to update
role GroupRole Role to create
return void

EjectUser() public method

Eject a user from a group
public EjectUser ( UUID group, UUID member ) : void
group UUID Group ID to eject the user from
member UUID Avatar's key to eject
return void

GroupManager() public method

Group Management Routines, Methods and Packet Handlers
public GroupManager ( GridClient client ) : System
client GridClient A reference to the current instance
return System

Invite() public method

Invites a user to a group
public Invite ( UUID group, List roles, UUID personkey ) : void
group UUID The group to invite to
roles List A list of roles to invite a person to
personkey UUID Key of person to invite
return void

LeaveGroup() public method

Request to leave a group
Subscribe to OnGroupLeft event to receive confirmation
public LeaveGroup ( UUID groupID ) : void
groupID UUID The group to leave
return void

RemoveFromRole() public method

Remove an avatar from a role
public RemoveFromRole ( UUID group, UUID role, UUID member ) : void
group UUID Group ID to update
role UUID Role ID to be removed from
member UUID Avatar's Key to remove
return void

RequestCreateGroup() public method

Request to create a new group. If the group is successfully created, L$100 will automatically be deducted
Subscribe to OnGroupCreated event to receive confirmation.
public RequestCreateGroup ( Group group ) : void
group Group Group struct containing the new group info
return void

RequestCurrentGroups() public method

Request a current list of groups the avatar is a member of.
CAPS Event Queue must be running for this to work since the results come across CAPS.
public RequestCurrentGroups ( ) : void
return void

RequestGroupAccountSummary() public method

Begin to get the group account summary
Subscribe to the OnGroupAccountSummary event to receive the results.
public RequestGroupAccountSummary ( UUID group, int intervalDays, int currentInterval ) : void
group UUID group ID (UUID)
intervalDays int How long of an interval
currentInterval int Which interval (0 for current, 1 for last)
return void

RequestGroupMembers() public method

Request a list of group members.
Subscribe to OnGroupMembers event to receive the results.
public RequestGroupMembers ( UUID group ) : UUID
group UUID group ID (UUID)
return UUID

RequestGroupName() public method

Lookup name of group based on groupID
public RequestGroupName ( UUID groupID ) : void
groupID UUID groupID of group to lookup name for.
return void

RequestGroupNames() public method

Request lookup of multiple group names
public RequestGroupNames ( List groupIDs ) : void
groupIDs List List of group IDs to request.
return void

RequestGroupNotice() public method

Request a group notice by key
public RequestGroupNotice ( UUID noticeID ) : void
noticeID UUID ID of group notice
return void

RequestGroupNoticeList() public method

Request the group notices list
public RequestGroupNoticeList ( UUID group ) : void
group UUID Group ID to fetch notices for
return void

RequestGroupProfile() public method

Lookup group profile data such as name, enrollment, founder, logo, etc
Subscribe to OnGroupProfile event to receive the results.
public RequestGroupProfile ( UUID group ) : void
group UUID group ID (UUID)
return void

RequestGroupRoleMembers() public method

Request members (members,role) role mapping for a group.
Subscribe to OnGroupRolesMembers event to receive the results.
public RequestGroupRoleMembers ( UUID group ) : UUID
group UUID group ID (UUID)
return UUID

RequestGroupRoles() public method

Request group roles
Subscribe to OnGroupRoles event to receive the results.
public RequestGroupRoles ( UUID group ) : UUID
group UUID group ID (UUID)
return UUID

RequestGroupTitles() public method

Request a groups Titles
Subscribe to OnGroupTitles event to receive the results.
public RequestGroupTitles ( UUID group ) : UUID
group UUID group ID (UUID)
return UUID

RequestJoinGroup() public method

Request to join a group
Subscribe to OnGroupJoined event for confirmation.
public RequestJoinGroup ( UUID id ) : void
id UUID group ID (UUID) to join.
return void

SendGroupNotice() public method

Send out a group notice
public SendGroupNotice ( UUID group, GroupNotice notice ) : void
group UUID Group ID to update
notice GroupNotice GroupNotice structure containing notice data
return void

SetGroupContribution() public method

Set this avatar's tier contribution
public SetGroupContribution ( UUID group, int contribution ) : void
group UUID Group ID to change tier in
contribution int amount of tier to donate
return void

StartProposal() public method

Start a group proposal (vote)
public StartProposal ( UUID group, GroupProposal prop ) : void
group UUID The Group ID to send proposal to
prop GroupProposal GroupProposal structure containing the proposal
return void

UpdateGroup() public method

Update a group's profile and other information
public UpdateGroup ( UUID id, Group group ) : void
id UUID Groups ID (UUID) to update.
group Group Group struct to update.
return void

UpdateRole() public method

Update role information
public UpdateRole ( GroupRole role ) : void
role GroupRole Modified role to be updated
return void

Property Details

GroupMembersCaches public property

A list of all the lists of group members, indexed by the group ID
public InternalDictionary> GroupMembersCaches
return InternalDictionary>

GroupName2KeyCache public property

Caches group name lookups
public InternalDictionary GroupName2KeyCache
return string>.InternalDictionary

GroupRolesCaches public property

A list of all the lists of group roles, indexed by the group ID
public InternalDictionary> GroupRolesCaches
return InternalDictionary>

GroupRolesMembersCaches public property

A list of all the role to member mappings, indexed by the group ID
public InternalDictionary>> GroupRolesMembersCaches
return InternalDictionary>>