mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 08:55:56 +08:00
Comment out unused private methods.
This commit is contained in:
@@ -92,72 +92,74 @@ namespace OpenSim.Framework.Data.SQLite
|
||||
return (IDbCommand) dbcommand;
|
||||
}
|
||||
|
||||
private bool TestTables(SQLiteConnection conn)
|
||||
{
|
||||
SQLiteCommand cmd = new SQLiteCommand("SELECT * FROM regions", conn);
|
||||
SQLiteDataAdapter pDa = new SQLiteDataAdapter(cmd);
|
||||
DataSet tmpDS = new DataSet();
|
||||
try
|
||||
{
|
||||
pDa.Fill(tmpDS, "regions");
|
||||
}
|
||||
catch (SqliteSyntaxException)
|
||||
{
|
||||
m_log.Info("[DATASTORE]: SQLite Database doesn't exist... creating");
|
||||
InitDB(conn);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
// TODO: unused
|
||||
// private bool TestTables(SQLiteConnection conn)
|
||||
// {
|
||||
// SQLiteCommand cmd = new SQLiteCommand("SELECT * FROM regions", conn);
|
||||
// SQLiteDataAdapter pDa = new SQLiteDataAdapter(cmd);
|
||||
// DataSet tmpDS = new DataSet();
|
||||
// try
|
||||
// {
|
||||
// pDa.Fill(tmpDS, "regions");
|
||||
// }
|
||||
// catch (SqliteSyntaxException)
|
||||
// {
|
||||
// m_log.Info("[DATASTORE]: SQLite Database doesn't exist... creating");
|
||||
// InitDB(conn);
|
||||
// }
|
||||
// return true;
|
||||
// }
|
||||
|
||||
private DataTable createRegionsTable()
|
||||
{
|
||||
DataTable regions = new DataTable("regions");
|
||||
// TODO: unused
|
||||
// private DataTable createRegionsTable()
|
||||
// {
|
||||
// DataTable regions = new DataTable("regions");
|
||||
|
||||
createCol(regions, "regionHandle", typeof (ulong));
|
||||
createCol(regions, "regionName", typeof (String));
|
||||
createCol(regions, "uuid", typeof (String));
|
||||
// createCol(regions, "regionHandle", typeof (ulong));
|
||||
// createCol(regions, "regionName", typeof (String));
|
||||
// createCol(regions, "uuid", typeof (String));
|
||||
|
||||
createCol(regions, "regionRecvKey", typeof (String));
|
||||
createCol(regions, "regionSecret", typeof (String));
|
||||
createCol(regions, "regionSendKey", typeof (String));
|
||||
// createCol(regions, "regionRecvKey", typeof (String));
|
||||
// createCol(regions, "regionSecret", typeof (String));
|
||||
// createCol(regions, "regionSendKey", typeof (String));
|
||||
|
||||
createCol(regions, "regionDataURI", typeof (String));
|
||||
createCol(regions, "serverIP", typeof (String));
|
||||
createCol(regions, "serverPort", typeof (String));
|
||||
createCol(regions, "serverURI", typeof (String));
|
||||
// createCol(regions, "regionDataURI", typeof (String));
|
||||
// createCol(regions, "serverIP", typeof (String));
|
||||
// createCol(regions, "serverPort", typeof (String));
|
||||
// createCol(regions, "serverURI", typeof (String));
|
||||
|
||||
|
||||
createCol(regions, "locX", typeof (uint));
|
||||
createCol(regions, "locY", typeof (uint));
|
||||
createCol(regions, "locZ", typeof (uint));
|
||||
// createCol(regions, "locX", typeof (uint));
|
||||
// createCol(regions, "locY", typeof (uint));
|
||||
// createCol(regions, "locZ", typeof (uint));
|
||||
|
||||
createCol(regions, "eastOverrideHandle", typeof (ulong));
|
||||
createCol(regions, "westOverrideHandle", typeof (ulong));
|
||||
createCol(regions, "southOverrideHandle", typeof (ulong));
|
||||
createCol(regions, "northOverrideHandle", typeof (ulong));
|
||||
// createCol(regions, "eastOverrideHandle", typeof (ulong));
|
||||
// createCol(regions, "westOverrideHandle", typeof (ulong));
|
||||
// createCol(regions, "southOverrideHandle", typeof (ulong));
|
||||
// createCol(regions, "northOverrideHandle", typeof (ulong));
|
||||
|
||||
createCol(regions, "regionAssetURI", typeof (String));
|
||||
createCol(regions, "regionAssetRecvKey", typeof (String));
|
||||
createCol(regions, "regionAssetSendKey", typeof (String));
|
||||
// createCol(regions, "regionAssetURI", typeof (String));
|
||||
// createCol(regions, "regionAssetRecvKey", typeof (String));
|
||||
// createCol(regions, "regionAssetSendKey", typeof (String));
|
||||
|
||||
createCol(regions, "regionUserURI", typeof (String));
|
||||
createCol(regions, "regionUserRecvKey", typeof (String));
|
||||
createCol(regions, "regionUserSendKey", typeof (String));
|
||||
// createCol(regions, "regionUserURI", typeof (String));
|
||||
// createCol(regions, "regionUserRecvKey", typeof (String));
|
||||
// createCol(regions, "regionUserSendKey", typeof (String));
|
||||
|
||||
// Add in contraints
|
||||
regions.PrimaryKey = new DataColumn[] {regions.Columns["UUID"]};
|
||||
return regions;
|
||||
}
|
||||
|
||||
private void InitDB(SQLiteConnection conn)
|
||||
{
|
||||
string createUsers = defineTable(createRegionsTable());
|
||||
SQLiteCommand pcmd = new SQLiteCommand(createUsers, conn);
|
||||
conn.Open();
|
||||
pcmd.ExecuteNonQuery();
|
||||
conn.Close();
|
||||
}
|
||||
// // Add in contraints
|
||||
// regions.PrimaryKey = new DataColumn[] {regions.Columns["UUID"]};
|
||||
// return regions;
|
||||
// }
|
||||
|
||||
// TODO: unused
|
||||
// private void InitDB(SQLiteConnection conn)
|
||||
// {
|
||||
// string createUsers = defineTable(createRegionsTable());
|
||||
// SQLiteCommand pcmd = new SQLiteCommand(createUsers, conn);
|
||||
// conn.Open();
|
||||
// pcmd.ExecuteNonQuery();
|
||||
// conn.Close();
|
||||
// }
|
||||
|
||||
/// <summary>
|
||||
/// Reads a region row from a database reader
|
||||
|
||||
@@ -624,19 +624,20 @@ namespace OpenSim.Framework.Data.SQLite
|
||||
return user;
|
||||
}
|
||||
|
||||
private void fillFriendRow(DataRow row, LLUUID ownerID, LLUUID friendID, uint perms)
|
||||
{
|
||||
row["ownerID"] = ownerID.UUID.ToString();
|
||||
row["friendID"] = friendID.UUID.ToString();
|
||||
row["friendPerms"] = perms;
|
||||
foreach (DataColumn col in ds.Tables["userfriends"].Columns)
|
||||
{
|
||||
if (row[col] == null)
|
||||
{
|
||||
row[col] = String.Empty;
|
||||
}
|
||||
}
|
||||
}
|
||||
// TODO: unused
|
||||
// private void fillFriendRow(DataRow row, LLUUID ownerID, LLUUID friendID, uint perms)
|
||||
// {
|
||||
// row["ownerID"] = ownerID.UUID.ToString();
|
||||
// row["friendID"] = friendID.UUID.ToString();
|
||||
// row["friendPerms"] = perms;
|
||||
// foreach (DataColumn col in ds.Tables["userfriends"].Columns)
|
||||
// {
|
||||
// if (row[col] == null)
|
||||
// {
|
||||
// row[col] = String.Empty;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
private void fillUserRow(DataRow row, UserProfileData user)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user