renaming of attributes in UserAgentData for readability

0.6.0-stable
Sean Dague 2008-04-10 14:50:52 +00:00
parent ef7dfae41c
commit 55ac1c6dce
7 changed files with 63 additions and 63 deletions

View File

@ -366,11 +366,11 @@ namespace OpenSim.Data.MSSQL
retval.LogoutTime = Convert.ToInt32(reader["logoutTime"].ToString());
// Current position
retval.CurrentRegion = (string)reader["currentRegion"];
retval.CurrentHandle = Convert.ToUInt64(reader["currentHandle"].ToString());
retval.Region = (string)reader["currentRegion"];
retval.Handle = Convert.ToUInt64(reader["currentHandle"].ToString());
LLVector3 tmp_v;
LLVector3.TryParse((string)reader["currentPos"], out tmp_v);
retval.CurrentPos = tmp_v;
retval.Position = tmp_v;
}
else

View File

@ -427,11 +427,11 @@ namespace OpenSim.Data.MySQL
retval.LogoutTime = Convert.ToInt32(reader["logoutTime"].ToString());
// Current position
retval.CurrentRegion = new LLUUID((string)reader["currentRegion"]);
retval.CurrentHandle = Convert.ToUInt64(reader["currentHandle"].ToString());
retval.Region = new LLUUID((string)reader["currentRegion"]);
retval.Handle = Convert.ToUInt64(reader["currentHandle"].ToString());
LLVector3 tmp_v;
LLVector3.TryParse((string) reader["currentPos"], out tmp_v);
retval.CurrentPos = tmp_v;
retval.Position = tmp_v;
}
else
{
@ -915,9 +915,9 @@ namespace OpenSim.Data.MySQL
parameters["?agentOnline"] = (agentdata.AgentOnline == true) ? "1" : "0";
parameters["?loginTime"] = agentdata.LoginTime.ToString();
parameters["?logoutTime"] = agentdata.LogoutTime.ToString();
parameters["?currentRegion"] = agentdata.CurrentRegion.ToString();
parameters["?currentHandle"] = agentdata.CurrentHandle.ToString();
parameters["?currentPos"] = "<" + ((int)agentdata.CurrentPos.X).ToString() + "," + ((int)agentdata.CurrentPos.Y).ToString() + "," + ((int)agentdata.CurrentPos.Z).ToString() + ">";
parameters["?currentRegion"] = agentdata.Region.ToString();
parameters["?currentHandle"] = agentdata.Handle.ToString();
parameters["?currentPos"] = "<" + ((int)agentdata.Position.X).ToString() + "," + ((int)agentdata.Position.Y).ToString() + "," + ((int)agentdata.Position.Z).ToString() + ">";
bool returnval = false;

View File

@ -680,12 +680,12 @@ namespace OpenSim.Data.SQLite
ua.AgentOnline = Convert.ToBoolean(row["agentOnline"]);
ua.SessionID = new LLUUID((String) row["sessionID"]);
ua.SecureSessionID = new LLUUID((String) row["secureSessionID"]);
ua.RegionID = new LLUUID((String) row["regionID"]);
ua.InitialRegion = new LLUUID((String) row["regionID"]);
ua.LoginTime = Convert.ToInt32(row["loginTime"]);
ua.LogoutTime = Convert.ToInt32(row["logoutTime"]);
ua.CurrentRegion = new LLUUID((String) row["currentRegion"]);
ua.CurrentHandle = Convert.ToUInt64(row["currentHandle"]);
ua.CurrentPos = new LLVector3(
ua.Region = new LLUUID((String) row["currentRegion"]);
ua.Handle = Convert.ToUInt64(row["currentHandle"]);
ua.Position = new LLVector3(
Convert.ToSingle(row["currentPosX"]),
Convert.ToSingle(row["currentPosY"]),
Convert.ToSingle(row["currentPosZ"])
@ -701,15 +701,15 @@ namespace OpenSim.Data.SQLite
row["agentOnline"] = ua.AgentOnline;
row["sessionID"] = ua.SessionID;
row["secureSessionID"] = ua.SecureSessionID;
row["regionID"] = ua.RegionID;
row["regionID"] = ua.InitialRegion;
row["loginTime"] = ua.LoginTime;
row["logoutTime"] = ua.LogoutTime;
row["currentRegion"] = ua.CurrentRegion;
row["currentHandle"] = ua.CurrentHandle.ToString();
row["currentRegion"] = ua.Region;
row["currentHandle"] = ua.Handle.ToString();
// vectors
row["currentPosX"] = ua.CurrentPos.X;
row["currentPosY"] = ua.CurrentPos.Y;
row["currentPosZ"] = ua.CurrentPos.Z;
row["currentPosX"] = ua.Position.X;
row["currentPosY"] = ua.Position.Y;
row["currentPosZ"] = ua.Position.Z;
}
/***********************************************************************

View File

@ -358,8 +358,8 @@ namespace OpenSim.Framework.UserManagement
agent.ProfileID = profile.ID;
// Current position (from Home)
agent.CurrentHandle = profile.HomeRegion;
agent.CurrentPos = profile.HomeLocation;
agent.Handle = profile.HomeRegion;
agent.Position = profile.HomeLocation;
// If user specified additional start, use that
if (requestData.ContainsKey("start"))
@ -367,16 +367,16 @@ namespace OpenSim.Framework.UserManagement
string startLoc = ((string)requestData["start"]).Trim();
if (("last" == startLoc) && (profile.CurrentAgent != null))
{
if ((profile.CurrentAgent.CurrentPos.X > 0)
&& (profile.CurrentAgent.CurrentPos.Y > 0)
&& (profile.CurrentAgent.CurrentPos.Z > 0)
if ((profile.CurrentAgent.Position.X > 0)
&& (profile.CurrentAgent.Position.Y > 0)
&& (profile.CurrentAgent.Position.Z > 0)
)
{
// TODO: Right now, currentRegion has not been used in GridServer for requesting region.
// TODO: It is only using currentHandle.
agent.CurrentRegion = profile.CurrentAgent.CurrentRegion;
agent.CurrentHandle = profile.CurrentAgent.CurrentHandle;
agent.CurrentPos = profile.CurrentAgent.CurrentPos;
agent.Region = profile.CurrentAgent.Region;
agent.Handle = profile.CurrentAgent.Handle;
agent.Position = profile.CurrentAgent.Position;
}
}
@ -403,8 +403,8 @@ namespace OpenSim.Framework.UserManagement
agent.LogoutTime = 0;
// Current location
agent.RegionID = LLUUID.Zero; // Fill in later
agent.CurrentRegion = LLUUID.Zero; // Fill in later
agent.InitialRegion = LLUUID.Zero; // Fill in later
agent.Region = LLUUID.Zero; // Fill in later
profile.CurrentAgent = agent;
}
@ -442,11 +442,11 @@ namespace OpenSim.Framework.UserManagement
//userAgent.sessionID = LLUUID.Zero;
if (regionid != LLUUID.Zero)
{
userAgent.CurrentRegion = regionid;
userAgent.Region = regionid;
}
userAgent.CurrentHandle = regionhandle;
userAgent.CurrentPos = currentPos;
userAgent.Handle = regionhandle;
userAgent.Position = currentPos;
userProfile.CurrentAgent = userAgent;
CommitAgent(ref userProfile);
@ -484,16 +484,16 @@ namespace OpenSim.Framework.UserManagement
agent.ProfileID = profile.ID;
// Current position (from Home)
agent.CurrentHandle = profile.HomeRegion;
agent.CurrentPos = profile.HomeLocation;
agent.Handle = profile.HomeRegion;
agent.Position = profile.HomeLocation;
// What time did the user login?
agent.LoginTime = Util.UnixTimeSinceEpoch();
agent.LogoutTime = 0;
// Current location
agent.RegionID = LLUUID.Zero; // Fill in later
agent.CurrentRegion = LLUUID.Zero; // Fill in later
agent.InitialRegion = LLUUID.Zero; // Fill in later
agent.Region = LLUUID.Zero; // Fill in later
profile.CurrentAgent = agent;
}

View File

@ -151,7 +151,7 @@ namespace OpenSim.Framework
}
}
public LLUUID RegionID {
public LLUUID InitialRegion {
get {
return regionID;
}
@ -178,7 +178,7 @@ namespace OpenSim.Framework
}
}
public LLUUID CurrentRegion {
public LLUUID Region {
get {
return currentRegion;
}
@ -187,7 +187,7 @@ namespace OpenSim.Framework
}
}
public ulong CurrentHandle {
public ulong Handle {
get {
return currentHandle;
}
@ -196,7 +196,7 @@ namespace OpenSim.Framework
}
}
public LLVector3 CurrentPos {
public LLVector3 Position {
get {
return currentPos;
}

View File

@ -85,7 +85,7 @@ namespace OpenSim.Grid.UserServer
{
SimInfo =
RegionProfileData.RequestSimProfileData(
theUser.CurrentAgent.CurrentHandle, m_config.GridServerURL,
theUser.CurrentAgent.Handle, m_config.GridServerURL,
m_config.GridSendKey, m_config.GridRecvKey);
}
else if (startLocationRequest == "home")
@ -104,7 +104,7 @@ namespace OpenSim.Grid.UserServer
// TODO: Parse out startlocationrequest string in the format; 'uri:RegionName&X&Y&Z'
SimInfo =
RegionProfileData.RequestSimProfileData(
theUser.CurrentAgent.CurrentHandle, m_config.GridServerURL,
theUser.CurrentAgent.Handle, m_config.GridServerURL,
m_config.GridSendKey, m_config.GridRecvKey);
}
else
@ -164,11 +164,11 @@ namespace OpenSim.Grid.UserServer
//CFK: m_log.Info("[LOGIN]: " + SimInfo.regionName + " (" + SimInfo.serverURI + ") " +
//CFK: SimInfo.regionLocX + "," + SimInfo.regionLocY);
theUser.CurrentAgent.CurrentRegion = SimInfo.UUID;
theUser.CurrentAgent.CurrentHandle = SimInfo.regionHandle;
theUser.CurrentAgent.Region = SimInfo.UUID;
theUser.CurrentAgent.Handle = SimInfo.regionHandle;
if (start_x >= 0 && start_y >= 0 && start_z >= 0) {
LLVector3 tmp_v = new LLVector3(start_x, start_y, start_z);
theUser.CurrentAgent.CurrentPos = tmp_v;
theUser.CurrentAgent.Position = tmp_v;
}
// Prepare notification
Hashtable SimParams = new Hashtable();
@ -178,10 +178,10 @@ namespace OpenSim.Grid.UserServer
SimParams["lastname"] = theUser.SurName;
SimParams["agent_id"] = theUser.ID.ToString();
SimParams["circuit_code"] = (Int32) Convert.ToUInt32(response.CircuitCode);
SimParams["startpos_x"] = theUser.CurrentAgent.CurrentPos.X.ToString();
SimParams["startpos_y"] = theUser.CurrentAgent.CurrentPos.Y.ToString();
SimParams["startpos_z"] = theUser.CurrentAgent.CurrentPos.Z.ToString();
SimParams["regionhandle"] = theUser.CurrentAgent.CurrentHandle.ToString();
SimParams["startpos_x"] = theUser.CurrentAgent.Position.X.ToString();
SimParams["startpos_y"] = theUser.CurrentAgent.Position.Y.ToString();
SimParams["startpos_z"] = theUser.CurrentAgent.Position.Z.ToString();
SimParams["regionhandle"] = theUser.CurrentAgent.Handle.ToString();
SimParams["caps_path"] = capsPath;
ArrayList SendParams = new ArrayList();
SendParams.Add(SimParams);
@ -205,8 +205,8 @@ namespace OpenSim.Grid.UserServer
if (handlerUserLoggedInAtLocation != null)
{
m_log.Info("[LOGIN]: Letting other objects know about login");
handlerUserLoggedInAtLocation(theUser.ID, theUser.CurrentAgent.SessionID, theUser.CurrentAgent.CurrentRegion,
theUser.CurrentAgent.CurrentHandle, theUser.CurrentAgent.CurrentPos.X,theUser.CurrentAgent.CurrentPos.Y,theUser.CurrentAgent.CurrentPos.Z,
handlerUserLoggedInAtLocation(theUser.ID, theUser.CurrentAgent.SessionID, theUser.CurrentAgent.Region,
theUser.CurrentAgent.Handle, theUser.CurrentAgent.Position.X,theUser.CurrentAgent.Position.Y,theUser.CurrentAgent.Position.Z,
theUser.FirstName,theUser.SurName);
}
}
@ -258,8 +258,8 @@ namespace OpenSim.Grid.UserServer
m_log.Info("[LOGIN]: Notifying " + SimInfo.regionName + " (" + SimInfo.serverURI + ")");
// Update agent with target sim
theUser.CurrentAgent.CurrentRegion = SimInfo.UUID;
theUser.CurrentAgent.CurrentHandle = SimInfo.regionHandle;
theUser.CurrentAgent.Region = SimInfo.UUID;
theUser.CurrentAgent.Handle = SimInfo.regionHandle;
// Prepare notification
Hashtable SimParams = new Hashtable();
@ -269,10 +269,10 @@ namespace OpenSim.Grid.UserServer
SimParams["lastname"] = theUser.SurName;
SimParams["agent_id"] = theUser.ID.ToString();
SimParams["circuit_code"] = (Int32) Convert.ToUInt32(response.CircuitCode);
SimParams["startpos_x"] = theUser.CurrentAgent.CurrentPos.X.ToString();
SimParams["startpos_y"] = theUser.CurrentAgent.CurrentPos.Y.ToString();
SimParams["startpos_z"] = theUser.CurrentAgent.CurrentPos.Z.ToString();
SimParams["regionhandle"] = theUser.CurrentAgent.CurrentHandle.ToString();
SimParams["startpos_x"] = theUser.CurrentAgent.Position.X.ToString();
SimParams["startpos_y"] = theUser.CurrentAgent.Position.Y.ToString();
SimParams["startpos_z"] = theUser.CurrentAgent.Position.Z.ToString();
SimParams["regionhandle"] = theUser.CurrentAgent.Handle.ToString();
SimParams["caps_path"] = capsPath;
ArrayList SendParams = new ArrayList();
SendParams.Add(SimParams);
@ -285,8 +285,8 @@ namespace OpenSim.Grid.UserServer
if (handlerUserLoggedInAtLocation != null)
{
m_log.Info("[LOGIN]: Letting other objects know about login");
handlerUserLoggedInAtLocation(theUser.ID, theUser.CurrentAgent.SessionID, theUser.CurrentAgent.CurrentRegion,
theUser.CurrentAgent.CurrentHandle, theUser.CurrentAgent.CurrentPos.X, theUser.CurrentAgent.CurrentPos.Y, theUser.CurrentAgent.CurrentPos.Z,
handlerUserLoggedInAtLocation(theUser.ID, theUser.CurrentAgent.SessionID, theUser.CurrentAgent.Region,
theUser.CurrentAgent.Handle, theUser.CurrentAgent.Position.X, theUser.CurrentAgent.Position.Y, theUser.CurrentAgent.Position.Z,
theUser.FirstName, theUser.SurName);
}
}

View File

@ -127,7 +127,7 @@ namespace OpenSim.Region.Communications.Local
ulong currentRegion = 0;
if (startLocationRequest == "last")
{
currentRegion = theUser.CurrentAgent.CurrentHandle;
currentRegion = theUser.CurrentAgent.Handle;
}
else if (startLocationRequest == "home")
{
@ -138,7 +138,7 @@ namespace OpenSim.Region.Communications.Local
m_log.Info("[LOGIN]: Got Custom Login URL, but can't process it");
// LocalBackEndServices can't possibly look up a region by name :(
// TODO: Parse string in the following format: 'uri:RegionName&X&Y&Z'
currentRegion = theUser.CurrentAgent.CurrentHandle;
currentRegion = theUser.CurrentAgent.Handle;
}
RegionInfo reg = m_Parent.GridService.RequestNeighbourInfo(currentRegion);
@ -164,8 +164,8 @@ namespace OpenSim.Region.Communications.Local
"[CAPS]: Sending new CAPS seed url {0} to client {1}",
response.SeedCapability, response.AgentID);
theUser.CurrentAgent.CurrentRegion = reg.RegionID;
theUser.CurrentAgent.CurrentHandle = reg.RegionHandle;
theUser.CurrentAgent.Region = reg.RegionID;
theUser.CurrentAgent.Handle = reg.RegionHandle;
LoginResponse.BuddyList buddyList = new LoginResponse.BuddyList();