From 17421593528f4126256dea6d0c844da9c218fdb7 Mon Sep 17 00:00:00 2001 From: mingchen Date: Mon, 4 Jun 2007 14:09:19 +0000 Subject: Parcel Manager Changes: *Added Parcel Backup Support for DB4. Other storages currently do not save *Added parcelIDList in ParcelManager to speed up parcel fetching at position *Added ParcelData.cs and ParcelData class for better storage support *Documentation for parcel added *2 Parcel Related bug fixes --- .../OpenSim.Framework/Interfaces/ILocalStorage.cs | 13 +++++++- Common/OpenSim.Framework/OpenSim.Framework.csproj | 36 +++++++++++++--------- Common/OpenSim.Framework/Types/ParcelData.cs | 33 ++++++++++++++++++++ 3 files changed, 67 insertions(+), 15 deletions(-) create mode 100644 Common/OpenSim.Framework/Types/ParcelData.cs (limited to 'Common/OpenSim.Framework') diff --git a/Common/OpenSim.Framework/Interfaces/ILocalStorage.cs b/Common/OpenSim.Framework/Interfaces/ILocalStorage.cs index 4dd8868..9fa3a00 100644 --- a/Common/OpenSim.Framework/Interfaces/ILocalStorage.cs +++ b/Common/OpenSim.Framework/Interfaces/ILocalStorage.cs @@ -37,11 +37,17 @@ namespace OpenSim.Framework.Interfaces public interface ILocalStorage { void Initialise(string datastore); + void StorePrim(PrimData prim); void RemovePrim(LLUUID primID); void LoadPrimitives(ILocalStorageReceiver receiver); + float[] LoadWorld(); void SaveMap(float[] heightmap); + + void SaveParcels(ParcelData[] parcels); + void LoadParcels(ILocalStorageParcelReceiver recv); + void ShutDown(); } @@ -49,6 +55,11 @@ namespace OpenSim.Framework.Interfaces { void PrimFromStorage(PrimData prim); } - + + public interface ILocalStorageParcelReceiver + { + void ParcelFromStorage(ParcelData data); + void NoParcelDataFromStorage(); + } } diff --git a/Common/OpenSim.Framework/OpenSim.Framework.csproj b/Common/OpenSim.Framework/OpenSim.Framework.csproj index f58a2d7..38245f7 100644 --- a/Common/OpenSim.Framework/OpenSim.Framework.csproj +++ b/Common/OpenSim.Framework/OpenSim.Framework.csproj @@ -1,4 +1,4 @@ - + Local 8.0.50727 @@ -6,7 +6,8 @@ {8ACA2445-0000-0000-0000-000000000000} Debug AnyCPU - + + OpenSim.Framework @@ -15,9 +16,11 @@ IE50 false Library - + + OpenSim.Framework - + + @@ -28,7 +31,8 @@ TRACE;DEBUG - + + True 4096 False @@ -37,7 +41,8 @@ False False 4 - + + False @@ -46,7 +51,8 @@ TRACE - + + False 4096 True @@ -55,22 +61,23 @@ False False 4 - + + - + System.dll False - + System.Xml.dll False - + ..\..\bin\libsecondlife.dll False - + ..\..\bin\Db4objects.Db4o.dll False @@ -80,7 +87,7 @@ XMLRPC {8E81D43C-0000-0000-0000-000000000000} {FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} - False + False @@ -105,6 +112,7 @@ Code + Code @@ -191,4 +199,4 @@ - + \ No newline at end of file diff --git a/Common/OpenSim.Framework/Types/ParcelData.cs b/Common/OpenSim.Framework/Types/ParcelData.cs new file mode 100644 index 0000000..b16926e --- /dev/null +++ b/Common/OpenSim.Framework/Types/ParcelData.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Text; +using libsecondlife; + +namespace OpenSim.Framework.Types +{ + + public class ParcelData + { + public byte[] parcelBitmapByteArray = new byte[512]; + public string parcelName = ""; + public string parcelDesc = ""; + public LLUUID ownerID = new LLUUID(); + public bool isGroupOwned = false; + public LLVector3 AABBMin = new LLVector3(); + public LLVector3 AABBMax = new LLVector3(); + public int area = 0; + public uint auctionID = 0; //Unemplemented. If set to 0, not being auctioned + public LLUUID authBuyerID = new LLUUID(); //Unemplemented. Authorized Buyer's UUID + public libsecondlife.Parcel.ParcelCategory category = new libsecondlife.Parcel.ParcelCategory(); //Unemplemented. Parcel's chosen category + public int claimDate = 0; //Unemplemented + public int claimPrice = 0; //Unemplemented + public LLUUID groupID = new LLUUID(); //Unemplemented + public int groupPrims = 0; //Unemplemented + public int salePrice = 0; //Unemeplemented. Parcels price. + public libsecondlife.Parcel.ParcelStatus parcelStatus = libsecondlife.Parcel.ParcelStatus.None; + public libsecondlife.Parcel.ParcelFlags parcelFlags = libsecondlife.Parcel.ParcelFlags.None; + + public int localID = 0; + } + +} -- cgit v1.1