aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/SQLite/SQLiteRegionData.cs
diff options
context:
space:
mode:
authorAdam Frisby2008-05-01 16:03:53 +0000
committerAdam Frisby2008-05-01 16:03:53 +0000
commit523190377861292dfecdaddebe1204301a0c7912 (patch)
treec003fa3c03389fc2d701d6797557c693a4eb29fc /OpenSim/Data/SQLite/SQLiteRegionData.cs
parentAdd basic OS X support to LaunchSLClient (diff)
downloadopensim-SC_OLD-523190377861292dfecdaddebe1204301a0c7912.zip
opensim-SC_OLD-523190377861292dfecdaddebe1204301a0c7912.tar.gz
opensim-SC_OLD-523190377861292dfecdaddebe1204301a0c7912.tar.bz2
opensim-SC_OLD-523190377861292dfecdaddebe1204301a0c7912.tar.xz
* In ur code. Making it static.
* Converted a bunch of functions to static functions.
Diffstat (limited to 'OpenSim/Data/SQLite/SQLiteRegionData.cs')
-rw-r--r--OpenSim/Data/SQLite/SQLiteRegionData.cs34
1 files changed, 17 insertions, 17 deletions
diff --git a/OpenSim/Data/SQLite/SQLiteRegionData.cs b/OpenSim/Data/SQLite/SQLiteRegionData.cs
index ea12a48..9a610a4 100644
--- a/OpenSim/Data/SQLite/SQLiteRegionData.cs
+++ b/OpenSim/Data/SQLite/SQLiteRegionData.cs
@@ -572,13 +572,13 @@ namespace OpenSim.Data.SQLite
572 * 572 *
573 **********************************************************************/ 573 **********************************************************************/
574 574
575 private void createCol(DataTable dt, string name, Type type) 575 private static void createCol(DataTable dt, string name, Type type)
576 { 576 {
577 DataColumn col = new DataColumn(name, type); 577 DataColumn col = new DataColumn(name, type);
578 dt.Columns.Add(col); 578 dt.Columns.Add(col);
579 } 579 }
580 580
581 private DataTable createTerrainTable() 581 private static DataTable createTerrainTable()
582 { 582 {
583 DataTable terrain = new DataTable("terrain"); 583 DataTable terrain = new DataTable("terrain");
584 584
@@ -589,7 +589,7 @@ namespace OpenSim.Data.SQLite
589 return terrain; 589 return terrain;
590 } 590 }
591 591
592 private DataTable createPrimTable() 592 private static DataTable createPrimTable()
593 { 593 {
594 DataTable prims = new DataTable("prims"); 594 DataTable prims = new DataTable("prims");
595 595
@@ -653,7 +653,7 @@ namespace OpenSim.Data.SQLite
653 return prims; 653 return prims;
654 } 654 }
655 655
656 private DataTable createShapeTable() 656 private static DataTable createShapeTable()
657 { 657 {
658 DataTable shapes = new DataTable("primshapes"); 658 DataTable shapes = new DataTable("primshapes");
659 createCol(shapes, "UUID", typeof (String)); 659 createCol(shapes, "UUID", typeof (String));
@@ -695,7 +695,7 @@ namespace OpenSim.Data.SQLite
695 return shapes; 695 return shapes;
696 } 696 }
697 697
698 private DataTable createItemsTable() 698 private static DataTable createItemsTable()
699 { 699 {
700 DataTable items = new DataTable("primitems"); 700 DataTable items = new DataTable("primitems");
701 701
@@ -727,7 +727,7 @@ namespace OpenSim.Data.SQLite
727 return items; 727 return items;
728 } 728 }
729 729
730 private DataTable createLandTable() 730 private static DataTable createLandTable()
731 { 731 {
732 DataTable land = new DataTable("land"); 732 DataTable land = new DataTable("land");
733 createCol(land, "UUID", typeof (String)); 733 createCol(land, "UUID", typeof (String));
@@ -771,7 +771,7 @@ namespace OpenSim.Data.SQLite
771 return land; 771 return land;
772 } 772 }
773 773
774 private DataTable createLandAccessListTable() 774 private static DataTable createLandAccessListTable()
775 { 775 {
776 DataTable landaccess = new DataTable("landaccesslist"); 776 DataTable landaccess = new DataTable("landaccesslist");
777 createCol(landaccess, "LandUUID", typeof (String)); 777 createCol(landaccess, "LandUUID", typeof (String));
@@ -901,7 +901,7 @@ namespace OpenSim.Data.SQLite
901 /// </summary> 901 /// </summary>
902 /// <param name="row"></param> 902 /// <param name="row"></param>
903 /// <returns></returns> 903 /// <returns></returns>
904 private TaskInventoryItem buildItem(DataRow row) 904 private static TaskInventoryItem buildItem(DataRow row)
905 { 905 {
906 TaskInventoryItem taskItem = new TaskInventoryItem(); 906 TaskInventoryItem taskItem = new TaskInventoryItem();
907 907
@@ -1008,7 +1008,7 @@ namespace OpenSim.Data.SQLite
1008 return newData; 1008 return newData;
1009 } 1009 }
1010 1010
1011 private ParcelManager.ParcelAccessEntry buildLandAccessData(DataRow row) 1011 private static ParcelManager.ParcelAccessEntry buildLandAccessData(DataRow row)
1012 { 1012 {
1013 ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry(); 1013 ParcelManager.ParcelAccessEntry entry = new ParcelManager.ParcelAccessEntry();
1014 entry.AgentID = new LLUUID((string) row["AccessUUID"]); 1014 entry.AgentID = new LLUUID((string) row["AccessUUID"]);
@@ -1017,7 +1017,7 @@ namespace OpenSim.Data.SQLite
1017 return entry; 1017 return entry;
1018 } 1018 }
1019 1019
1020 private Array serializeTerrain(double[,] val) 1020 private static Array serializeTerrain(double[,] val)
1021 { 1021 {
1022 MemoryStream str = new MemoryStream(65536*sizeof (double)); 1022 MemoryStream str = new MemoryStream(65536*sizeof (double));
1023 BinaryWriter bw = new BinaryWriter(str); 1023 BinaryWriter bw = new BinaryWriter(str);
@@ -1046,7 +1046,7 @@ namespace OpenSim.Data.SQLite
1046// row["Heightfield"] = str.ToArray(); 1046// row["Heightfield"] = str.ToArray();
1047// } 1047// }
1048 1048
1049 private void fillPrimRow(DataRow row, SceneObjectPart prim, LLUUID sceneGroupID, LLUUID regionUUID) 1049 private static void fillPrimRow(DataRow row, SceneObjectPart prim, LLUUID sceneGroupID, LLUUID regionUUID)
1050 { 1050 {
1051 row["UUID"] = Util.ToRawUuidString(prim.UUID); 1051 row["UUID"] = Util.ToRawUuidString(prim.UUID);
1052 row["RegionUUID"] = Util.ToRawUuidString(regionUUID); 1052 row["RegionUUID"] = Util.ToRawUuidString(regionUUID);
@@ -1106,7 +1106,7 @@ namespace OpenSim.Data.SQLite
1106 row["SitTargetOrientZ"] = sitTargetOrient.Z; 1106 row["SitTargetOrientZ"] = sitTargetOrient.Z;
1107 } 1107 }
1108 1108
1109 private void fillItemRow(DataRow row, TaskInventoryItem taskItem) 1109 private static void fillItemRow(DataRow row, TaskInventoryItem taskItem)
1110 { 1110 {
1111 row["itemID"] = taskItem.ItemID; 1111 row["itemID"] = taskItem.ItemID;
1112 row["primID"] = taskItem.ParentPartID; 1112 row["primID"] = taskItem.ParentPartID;
@@ -1130,7 +1130,7 @@ namespace OpenSim.Data.SQLite
1130 row["groupPermissions"] = taskItem.GroupMask; 1130 row["groupPermissions"] = taskItem.GroupMask;
1131 } 1131 }
1132 1132
1133 private void fillLandRow(DataRow row, LandData land, LLUUID regionUUID) 1133 private static void fillLandRow(DataRow row, LandData land, LLUUID regionUUID)
1134 { 1134 {
1135 row["UUID"] = Util.ToRawUuidString(land.globalID); 1135 row["UUID"] = Util.ToRawUuidString(land.globalID);
1136 row["RegionUUID"] = Util.ToRawUuidString(regionUUID); 1136 row["RegionUUID"] = Util.ToRawUuidString(regionUUID);
@@ -1169,7 +1169,7 @@ namespace OpenSim.Data.SQLite
1169 row["AuthbuyerID"] = Util.ToRawUuidString(land.authBuyerID); 1169 row["AuthbuyerID"] = Util.ToRawUuidString(land.authBuyerID);
1170 } 1170 }
1171 1171
1172 private void fillLandAccessRow(DataRow row, ParcelManager.ParcelAccessEntry entry, LLUUID parcelID) 1172 private static void fillLandAccessRow(DataRow row, ParcelManager.ParcelAccessEntry entry, LLUUID parcelID)
1173 { 1173 {
1174 row["LandUUID"] = Util.ToRawUuidString(parcelID); 1174 row["LandUUID"] = Util.ToRawUuidString(parcelID);
1175 row["AccessUUID"] = Util.ToRawUuidString(entry.AgentID); 1175 row["AccessUUID"] = Util.ToRawUuidString(entry.AgentID);
@@ -1242,7 +1242,7 @@ namespace OpenSim.Data.SQLite
1242 return s; 1242 return s;
1243 } 1243 }
1244 1244
1245 private void fillShapeRow(DataRow row, SceneObjectPart prim) 1245 private static void fillShapeRow(DataRow row, SceneObjectPart prim)
1246 { 1246 {
1247 PrimitiveBaseShape s = prim.Shape; 1247 PrimitiveBaseShape s = prim.Shape;
1248 row["UUID"] = Util.ToRawUuidString(prim.UUID); 1248 row["UUID"] = Util.ToRawUuidString(prim.UUID);
@@ -1713,7 +1713,7 @@ namespace OpenSim.Data.SQLite
1713 * 1713 *
1714 **********************************************************************/ 1714 **********************************************************************/
1715 1715
1716 private DbType dbtypeFromType(Type type) 1716 private static DbType dbtypeFromType(Type type)
1717 { 1717 {
1718 if (type == typeof (String)) 1718 if (type == typeof (String))
1719 { 1719 {
@@ -1747,7 +1747,7 @@ namespace OpenSim.Data.SQLite
1747 1747
1748 // this is something we'll need to implement for each db 1748 // this is something we'll need to implement for each db
1749 // slightly differently. 1749 // slightly differently.
1750 private string sqliteType(Type type) 1750 private static string sqliteType(Type type)
1751 { 1751 {
1752 if (type == typeof (String)) 1752 if (type == typeof (String))
1753 { 1753 {