Add simple login test with online friends. Add IFriendsModule.GrantRights() for granting rights via a module call.

Rename IFriendsModule.GetFriendPerms() -> GetRightsGrantedByFriend() to be more self-documenting and consistent with friends module terminology.
Add some method doc.
This commit is contained in:
Justin Clark-Casey (justincc)
2012-03-30 00:40:19 +01:00
parent b8d383da0a
commit 59157d9d63
12 changed files with 177 additions and 85 deletions

View File

@@ -55,7 +55,27 @@ namespace OpenSim.Region.Framework.Interfaces
/// <param name="exFriendID"></param>
void RemoveFriendship(IClientAPI client, UUID exFriendID);
uint GetFriendPerms(UUID PrincipalID, UUID FriendID);
/// <summary>
/// Get permissions granted by a friend.
/// </summary>
/// <param name="PrincipalID">The user.</param>
/// <param name="FriendID">The friend that granted.</param>
/// <returns>The permissions. These come from the FriendRights enum.</returns>
int GetRightsGrantedByFriend(UUID PrincipalID, UUID FriendID);
/// <summary>
/// Grant permissions for a friend.
/// </summary>
/// <remarks>
/// This includes giving them the ability to see when the user is online and permission to edit the user's
/// objects.
/// Granting lower permissions than the friend currently has will rescind the extra permissions.
/// </remarks>
/// <param name="remoteClient">The user granting the permissions.</param>
/// <param name="friendID">The friend.</param>
/// <param name="perms">These come from the FriendRights enum.</param>
void GrantRights(IClientAPI remoteClient, UUID friendID, int perms);
bool SendFriendsOnlineIfNeeded(IClientAPI client);
}
}
}