From 6265a09ff90d1de4a09b41fbdcb99a1eb2ebc2d4 Mon Sep 17 00:00:00 2001
From: Dr Scofield
Date: Fri, 4 Jul 2008 11:13:25 +0000
Subject: Renaming UserManagerBase.SetUserProfile(UserProfileData) to
UserManager.UpdateUserProfile(UserProfileData).
Adding UpdateUserProfile(UserProfileData) to IUserService interface.
Adding RemoteAdminPlugin.XmlRpcUpdateUserAccountMethod(...) to provide
a remote update capability.
---
OpenSim/Framework/Communications/IUserService.cs | 7 +++++++
OpenSim/Framework/Communications/UserManagerBase.cs | 11 ++++++-----
2 files changed, 13 insertions(+), 5 deletions(-)
(limited to 'OpenSim/Framework')
diff --git a/OpenSim/Framework/Communications/IUserService.cs b/OpenSim/Framework/Communications/IUserService.cs
index 6ad72c0..c1ae0e2 100644
--- a/OpenSim/Framework/Communications/IUserService.cs
+++ b/OpenSim/Framework/Communications/IUserService.cs
@@ -64,6 +64,13 @@ namespace OpenSim.Framework.Communications
///
LLUUID AddUserProfile(string firstName, string lastName, string pass, uint regX, uint regY);
+ ///
+ /// Update the user's profile.
+ ///
+ /// UserProfileData object with updated data. Should be obtained
+ /// via a call to GetUserProfile().
+ /// true if the update could be applied, false if it could not be applied.
+ bool UpdateUserProfile(UserProfileData data);
///
/// Adds a new friend to the database for XUser
diff --git a/OpenSim/Framework/Communications/UserManagerBase.cs b/OpenSim/Framework/Communications/UserManagerBase.cs
index d5b1e74..1b73152 100644
--- a/OpenSim/Framework/Communications/UserManagerBase.cs
+++ b/OpenSim/Framework/Communications/UserManagerBase.cs
@@ -153,11 +153,11 @@ namespace OpenSim.Framework.Communications
}
///
- /// Set's user profile from data object
+ /// Updates a user profile from data object
///
///
///
- public bool SetUserProfile(UserProfileData data)
+ public bool UpdateUserProfile(UserProfileData data)
{
foreach (KeyValuePair plugin in _plugins)
{
@@ -168,7 +168,8 @@ namespace OpenSim.Framework.Communications
}
catch (Exception e)
{
- m_log.Info("[USERSTORAGE]: Unable to set user via " + plugin.Key + "(" + e.ToString() + ")");
+ m_log.InfoFormat("[USERSTORAGE]: Unable to set user {0} {1} via {2}: {3}", data.FirstName, data.SurName,
+ plugin.Key, e.ToString());
}
}
return false;
@@ -352,7 +353,7 @@ namespace OpenSim.Framework.Communications
UserProfileData profile = GetUserProfile(agentID);
profile.CurrentAgent = null;
- SetUserProfile(profile);
+ UpdateUserProfile(profile);
}
@@ -539,7 +540,7 @@ namespace OpenSim.Framework.Communications
// TODO: what is the logic should be?
bool ret = false;
ret = AddUserAgent(profile.CurrentAgent);
- ret = ret & SetUserProfile(profile);
+ ret = ret & UpdateUserProfile(profile);
return ret;
}
--
cgit v1.1