aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Services/Interfaces
diff options
context:
space:
mode:
authorUbitUmarov2015-09-01 14:54:35 +0100
committerUbitUmarov2015-09-01 14:54:35 +0100
commit371c9dd2af01a2e7422ec901ee1f80757284a78c (patch)
tree058d2a513cacb12efcce0c0df0ae14ad135dbfe2 /OpenSim/Services/Interfaces
parentremove lixo (diff)
parentdont change camera on crossings (diff)
downloadopensim-SC-371c9dd2af01a2e7422ec901ee1f80757284a78c.zip
opensim-SC-371c9dd2af01a2e7422ec901ee1f80757284a78c.tar.gz
opensim-SC-371c9dd2af01a2e7422ec901ee1f80757284a78c.tar.bz2
opensim-SC-371c9dd2af01a2e7422ec901ee1f80757284a78c.tar.xz
bad merge?
Diffstat (limited to 'OpenSim/Services/Interfaces')
-rw-r--r--OpenSim/Services/Interfaces/IAttachmentsService.cs17
-rw-r--r--OpenSim/Services/Interfaces/IAuthenticationService.cs1
-rw-r--r--OpenSim/Services/Interfaces/IAvatarService.cs29
-rw-r--r--OpenSim/Services/Interfaces/IBakedTextureService.cs9
-rw-r--r--OpenSim/Services/Interfaces/IGridService.cs125
-rw-r--r--OpenSim/Services/Interfaces/ILoginService.cs4
-rw-r--r--OpenSim/Services/Interfaces/IMapImageService.cs6
-rw-r--r--OpenSim/Services/Interfaces/ISimulationService.cs8
-rw-r--r--OpenSim/Services/Interfaces/IUserAccountService.cs5
-rw-r--r--OpenSim/Services/Interfaces/IUserProfilesService.cs5
10 files changed, 193 insertions, 16 deletions
diff --git a/OpenSim/Services/Interfaces/IAttachmentsService.cs b/OpenSim/Services/Interfaces/IAttachmentsService.cs
new file mode 100644
index 0000000..bdde369
--- /dev/null
+++ b/OpenSim/Services/Interfaces/IAttachmentsService.cs
@@ -0,0 +1,17 @@
1////////////////////////////////////////////////////////////////
2//
3// (c) 2009, 2010 Careminster Limited and Melanie Thielker
4//
5// All rights reserved
6//
7using System;
8using Nini.Config;
9
10namespace OpenSim.Services.Interfaces
11{
12 public interface IAttachmentsService
13 {
14 string Get(string id);
15 void Store(string id, string data);
16 }
17}
diff --git a/OpenSim/Services/Interfaces/IAuthenticationService.cs b/OpenSim/Services/Interfaces/IAuthenticationService.cs
index cee8bc0..cdcfad9 100644
--- a/OpenSim/Services/Interfaces/IAuthenticationService.cs
+++ b/OpenSim/Services/Interfaces/IAuthenticationService.cs
@@ -67,6 +67,7 @@ namespace OpenSim.Services.Interfaces
67 // various services. 67 // various services.
68 // 68 //
69 string Authenticate(UUID principalID, string password, int lifetime); 69 string Authenticate(UUID principalID, string password, int lifetime);
70 string Authenticate(UUID principalID, string password, int lifetime, out UUID realID);
70 71
71 ////////////////////////////////////////////////////// 72 //////////////////////////////////////////////////////
72 // Verification 73 // Verification
diff --git a/OpenSim/Services/Interfaces/IAvatarService.cs b/OpenSim/Services/Interfaces/IAvatarService.cs
index 6ca0b15..3663a7a 100644
--- a/OpenSim/Services/Interfaces/IAvatarService.cs
+++ b/OpenSim/Services/Interfaces/IAvatarService.cs
@@ -162,10 +162,16 @@ namespace OpenSim.Services.Interfaces
162 } 162 }
163 163
164 // Visual Params 164 // Visual Params
165 string[] vps = new string[AvatarAppearance.VISUALPARAM_COUNT]; 165 // string[] vps = new string[AvatarAppearance.VISUALPARAM_COUNT];
166 // byte[] binary = appearance.VisualParams;
167
168 // for (int i = 0 ; i < AvatarAppearance.VISUALPARAM_COUNT ; i++)
169
170
166 byte[] binary = appearance.VisualParams; 171 byte[] binary = appearance.VisualParams;
172 string[] vps = new string[binary.Length];
167 173
168 for (int i = 0 ; i < AvatarAppearance.VISUALPARAM_COUNT ; i++) 174 for (int i = 0; i < binary.Length; i++)
169 { 175 {
170 vps[i] = binary[i].ToString(); 176 vps[i] = binary[i].ToString();
171 } 177 }
@@ -202,7 +208,13 @@ namespace OpenSim.Services.Interfaces
202 appearance.Serial = Int32.Parse(Data["Serial"]); 208 appearance.Serial = Int32.Parse(Data["Serial"]);
203 209
204 if (Data.ContainsKey("AvatarHeight")) 210 if (Data.ContainsKey("AvatarHeight"))
205 appearance.AvatarHeight = float.Parse(Data["AvatarHeight"]); 211 {
212 float h = float.Parse(Data["AvatarHeight"]);
213 if( h == 0f)
214 h = 1.9f;
215 appearance.SetSize(new Vector3(0.45f, 0.6f, h ));
216// appearance.AvatarHeight = float.Parse(Data["AvatarHeight"]);
217 }
206 218
207 // Legacy Wearables 219 // Legacy Wearables
208 if (Data.ContainsKey("BodyItem")) 220 if (Data.ContainsKey("BodyItem"))
@@ -273,10 +285,14 @@ namespace OpenSim.Services.Interfaces
273 if (Data.ContainsKey("VisualParams")) 285 if (Data.ContainsKey("VisualParams"))
274 { 286 {
275 string[] vps = Data["VisualParams"].Split(new char[] {','}); 287 string[] vps = Data["VisualParams"].Split(new char[] {','});
276 byte[] binary = new byte[AvatarAppearance.VISUALPARAM_COUNT]; 288 // byte[] binary = new byte[AvatarAppearance.VISUALPARAM_COUNT];
289
290 // for (int i = 0 ; i < vps.Length && i < binary.Length ; i++)
291 byte[] binary = new byte[vps.Length];
277 292
278 for (int i = 0 ; i < vps.Length && i < binary.Length ; i++) 293 for (int i = 0; i < vps.Length; i++)
279 binary[i] = (byte)Convert.ToInt32(vps[i]); 294
295 binary[i] = (byte)Convert.ToInt32(vps[i]);
280 296
281 appearance.VisualParams = binary; 297 appearance.VisualParams = binary;
282 } 298 }
@@ -342,6 +358,7 @@ namespace OpenSim.Services.Interfaces
342 appearance.Wearables[AvatarWearable.EYES].Wear( 358 appearance.Wearables[AvatarWearable.EYES].Wear(
343 AvatarWearable.DefaultWearables[ 359 AvatarWearable.DefaultWearables[
344 AvatarWearable.EYES][0]); 360 AvatarWearable.EYES][0]);
361
345 } 362 }
346 catch 363 catch
347 { 364 {
diff --git a/OpenSim/Services/Interfaces/IBakedTextureService.cs b/OpenSim/Services/Interfaces/IBakedTextureService.cs
index 69df4a0..ab88695 100644
--- a/OpenSim/Services/Interfaces/IBakedTextureService.cs
+++ b/OpenSim/Services/Interfaces/IBakedTextureService.cs
@@ -1,3 +1,4 @@
1<<<<<<< HEAD
1/* 2/*
2 * Copyright (c) Contributors, http://opensimulator.org/ 3 * Copyright (c) Contributors, http://opensimulator.org/
3 * See CONTRIBUTORS.TXT for a full list of copyright holders. 4 * See CONTRIBUTORS.TXT for a full list of copyright holders.
@@ -25,6 +26,14 @@
25 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 */ 27 */
27 28
29=======
30////////////////////////////////////////////////////////////////
31//
32// (c) 2009, 2010 Careminster Limited and Melanie Thielker
33//
34// All rights reserved
35//
36>>>>>>> avn/ubitvar
28using System; 37using System;
29using Nini.Config; 38using Nini.Config;
30 39
diff --git a/OpenSim/Services/Interfaces/IGridService.cs b/OpenSim/Services/Interfaces/IGridService.cs
index f5f1f75..7e5597b 100644
--- a/OpenSim/Services/Interfaces/IGridService.cs
+++ b/OpenSim/Services/Interfaces/IGridService.cs
@@ -159,7 +159,17 @@ namespace OpenSim.Services.Interfaces
159 } 159 }
160 } 160 }
161 set { 161 set {
162<<<<<<< HEAD
162 if (value.EndsWith("/")) { 163 if (value.EndsWith("/")) {
164=======
165 if ( value == null)
166 {
167 m_serverURI = String.Empty;
168 return;
169 }
170
171 if ( value.EndsWith("/") ) {
172>>>>>>> avn/ubitvar
163 m_serverURI = value; 173 m_serverURI = value;
164 } else { 174 } else {
165 m_serverURI = value + '/'; 175 m_serverURI = value + '/';
@@ -500,9 +510,13 @@ namespace OpenSim.Services.Interfaces
500 } 510 }
501 catch (SocketException e) 511 catch (SocketException e)
502 { 512 {
503 throw new Exception( 513 /*throw new Exception(
504 "Unable to resolve local hostname " + m_externalHostName + " innerException of type '" + 514 "Unable to resolve local hostname " + m_externalHostName + " innerException of type '" +
505 e + "' attached to this exception", e); 515 e + "' attached to this exception", e);*/
516 // Don't throw a fatal exception here, instead, return Null and handle it in the caller.
517 // Reason is, on systems such as OSgrid it has occured that known hostnames stop
518 // resolving and thus make surrounding regions crash out with this exception.
519 return null;
506 } 520 }
507 521
508 return new IPEndPoint(ia, m_internalEndPoint.Port); 522 return new IPEndPoint(ia, m_internalEndPoint.Port);
@@ -525,5 +539,110 @@ namespace OpenSim.Services.Interfaces
525 { 539 {
526 get { return Util.UIntsToLong((uint)RegionLocX, (uint)RegionLocY); } 540 get { return Util.UIntsToLong((uint)RegionLocX, (uint)RegionLocY); }
527 } 541 }
542<<<<<<< HEAD
543=======
544
545 public Dictionary<string, object> ToKeyValuePairs()
546 {
547 Dictionary<string, object> kvp = new Dictionary<string, object>();
548 kvp["uuid"] = RegionID.ToString();
549 kvp["locX"] = RegionLocX.ToString();
550 kvp["locY"] = RegionLocY.ToString();
551 kvp["sizeX"] = RegionSizeX.ToString();
552 kvp["sizeY"] = RegionSizeY.ToString();
553 kvp["regionName"] = RegionName;
554 kvp["serverIP"] = ExternalHostName; //ExternalEndPoint.Address.ToString();
555 kvp["serverHttpPort"] = HttpPort.ToString();
556 kvp["serverURI"] = ServerURI;
557 kvp["serverPort"] = InternalEndPoint.Port.ToString();
558 kvp["regionMapTexture"] = TerrainImage.ToString();
559 kvp["parcelMapTexture"] = ParcelImage.ToString();
560 kvp["access"] = Access.ToString();
561 kvp["regionSecret"] = RegionSecret;
562 kvp["owner_uuid"] = EstateOwner.ToString();
563 kvp["Token"] = Token.ToString();
564 // Maturity doesn't seem to exist in the DB
565 return kvp;
566 }
567
568 public GridRegion(Dictionary<string, object> kvp)
569 {
570 if (kvp.ContainsKey("uuid"))
571 RegionID = new UUID((string)kvp["uuid"]);
572
573 if (kvp.ContainsKey("locX"))
574 RegionLocX = Convert.ToInt32((string)kvp["locX"]);
575
576 if (kvp.ContainsKey("locY"))
577 RegionLocY = Convert.ToInt32((string)kvp["locY"]);
578
579 if (kvp.ContainsKey("sizeX"))
580 RegionSizeX = Convert.ToInt32((string)kvp["sizeX"]);
581 else
582 RegionSizeX = (int)Constants.RegionSize;
583
584 if (kvp.ContainsKey("sizeY"))
585 RegionSizeY = Convert.ToInt32((string)kvp["sizeY"]);
586 else
587 RegionSizeY = (int)Constants.RegionSize;
588
589 if (kvp.ContainsKey("regionName"))
590 RegionName = (string)kvp["regionName"];
591
592 if (kvp.ContainsKey("access"))
593 {
594 byte access = Convert.ToByte((string)kvp["access"]);
595 Maturity = (int)Util.ConvertAccessLevelToMaturity(access);
596 }
597
598 if (kvp.ContainsKey("serverIP"))
599 {
600 //int port = 0;
601 //Int32.TryParse((string)kvp["serverPort"], out port);
602 //IPEndPoint ep = new IPEndPoint(IPAddress.Parse((string)kvp["serverIP"]), port);
603 ExternalHostName = (string)kvp["serverIP"];
604 }
605 else
606 ExternalHostName = "127.0.0.1";
607
608 if (kvp.ContainsKey("serverPort"))
609 {
610 Int32 port = 0;
611 Int32.TryParse((string)kvp["serverPort"], out port);
612 InternalEndPoint = new IPEndPoint(IPAddress.Parse("0.0.0.0"), port);
613 }
614
615 if (kvp.ContainsKey("serverHttpPort"))
616 {
617 UInt32 port = 0;
618 UInt32.TryParse((string)kvp["serverHttpPort"], out port);
619 HttpPort = port;
620 }
621
622 if (kvp.ContainsKey("serverURI"))
623 ServerURI = (string)kvp["serverURI"];
624
625 if (kvp.ContainsKey("regionMapTexture"))
626 UUID.TryParse((string)kvp["regionMapTexture"], out TerrainImage);
627
628 if (kvp.ContainsKey("parcelMapTexture"))
629 UUID.TryParse((string)kvp["parcelMapTexture"], out ParcelImage);
630
631 if (kvp.ContainsKey("access"))
632 Access = Byte.Parse((string)kvp["access"]);
633
634 if (kvp.ContainsKey("regionSecret"))
635 RegionSecret =(string)kvp["regionSecret"];
636
637 if (kvp.ContainsKey("owner_uuid"))
638 EstateOwner = new UUID(kvp["owner_uuid"].ToString());
639
640 if (kvp.ContainsKey("Token"))
641 Token = kvp["Token"].ToString();
642
643 // m_log.DebugFormat("{0} New GridRegion. id={1}, loc=<{2},{3}>, size=<{4},{5}>",
644 // LogHeader, RegionID, RegionLocX, RegionLocY, RegionSizeX, RegionSizeY);
645 }
646>>>>>>> avn/ubitvar
528 } 647 }
529} \ No newline at end of file 648}
diff --git a/OpenSim/Services/Interfaces/ILoginService.cs b/OpenSim/Services/Interfaces/ILoginService.cs
index ee9b0b1..7c44cd8 100644
--- a/OpenSim/Services/Interfaces/ILoginService.cs
+++ b/OpenSim/Services/Interfaces/ILoginService.cs
@@ -47,8 +47,8 @@ namespace OpenSim.Services.Interfaces
47 47
48 public interface ILoginService 48 public interface ILoginService
49 { 49 {
50 LoginResponse Login(string firstName, string lastName, string passwd, string startLocation, UUID scopeID, 50 LoginResponse Login(string firstName, string lastName, string passwd, string startLocation, UUID scopeID,
51 string clientVersion, string channel, string mac, string id0, IPEndPoint clientIP); 51 string clientVersion, string channel, string mac, string id0, IPEndPoint clientIP, bool LibOMVclient);
52 Hashtable SetLevel(string firstName, string lastName, string passwd, int level, IPEndPoint clientIP); 52 Hashtable SetLevel(string firstName, string lastName, string passwd, int level, IPEndPoint clientIP);
53 } 53 }
54 54
diff --git a/OpenSim/Services/Interfaces/IMapImageService.cs b/OpenSim/Services/Interfaces/IMapImageService.cs
index 78daa5f..0d1458e 100644
--- a/OpenSim/Services/Interfaces/IMapImageService.cs
+++ b/OpenSim/Services/Interfaces/IMapImageService.cs
@@ -34,8 +34,14 @@ namespace OpenSim.Services.Interfaces
34 public interface IMapImageService 34 public interface IMapImageService
35 { 35 {
36 //List<MapBlockData> GetMapBlocks(UUID scopeID, int minX, int minY, int maxX, int maxY); 36 //List<MapBlockData> GetMapBlocks(UUID scopeID, int minX, int minY, int maxX, int maxY);
37<<<<<<< HEAD
37 bool AddMapTile(int x, int y, byte[] imageData, out string reason); 38 bool AddMapTile(int x, int y, byte[] imageData, out string reason);
38 bool RemoveMapTile(int x, int y, out string reason); 39 bool RemoveMapTile(int x, int y, out string reason);
39 byte[] GetMapTile(string fileName, out string format); 40 byte[] GetMapTile(string fileName, out string format);
41=======
42 bool AddMapTile(int x, int y, byte[] imageData, UUID scopeID, out string reason);
43 bool RemoveMapTile(int x, int y, UUID scopeID, out string reason);
44 byte[] GetMapTile(string fileName, UUID scopeID, out string format);
45>>>>>>> avn/ubitvar
40 } 46 }
41} 47}
diff --git a/OpenSim/Services/Interfaces/ISimulationService.cs b/OpenSim/Services/Interfaces/ISimulationService.cs
index 42c414d..ee1e294 100644
--- a/OpenSim/Services/Interfaces/ISimulationService.cs
+++ b/OpenSim/Services/Interfaces/ISimulationService.cs
@@ -86,6 +86,7 @@ namespace OpenSim.Services.Interfaces
86 /// <param name="agentHomeURI">The visitor's Home URI. Will be missing (null) in older OpenSims.</param> 86 /// <param name="agentHomeURI">The visitor's Home URI. Will be missing (null) in older OpenSims.</param>
87 /// <param name="viaTeleport">True: via teleport; False: via cross (walking)</param> 87 /// <param name="viaTeleport">True: via teleport; False: via cross (walking)</param>
88 /// <param name="position">Position in the region</param> 88 /// <param name="position">Position in the region</param>
89<<<<<<< HEAD
89 /// <param name="sversion"> 90 /// <param name="sversion">
90 /// Version that the requesting simulator is runing. If null then no version check is carried out. 91 /// Version that the requesting simulator is runing. If null then no version check is carried out.
91 /// </param> 92 /// </param>
@@ -93,6 +94,13 @@ namespace OpenSim.Services.Interfaces
93 /// <param name="reason">[out] Optional error message</param> 94 /// <param name="reason">[out] Optional error message</param>
94 /// <returns>True: ok; False: not allowed</returns> 95 /// <returns>True: ok; False: not allowed</returns>
95 bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string sversion, List<UUID> features, out string version, out string reason); 96 bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string sversion, List<UUID> features, out string version, out string reason);
97=======
98 /// <param name="sversion">version that the requesting simulator is runing</param>
99 /// <param name="version">version that the target simulator is running</param>
100 /// <param name="reason">[out] Optional error message</param>
101 /// <returns>True: ok; False: not allowed</returns>
102 bool QueryAccess(GridRegion destination, UUID agentID, string agentHomeURI, bool viaTeleport, Vector3 position, string sversion, out string version, out string reason);
103>>>>>>> avn/ubitvar
96 104
97 /// <summary> 105 /// <summary>
98 /// Message from receiving region to departing region, telling it got contacted by the client. 106 /// Message from receiving region to departing region, telling it got contacted by the client.
diff --git a/OpenSim/Services/Interfaces/IUserAccountService.cs b/OpenSim/Services/Interfaces/IUserAccountService.cs
index 2f7702c..1814699 100644
--- a/OpenSim/Services/Interfaces/IUserAccountService.cs
+++ b/OpenSim/Services/Interfaces/IUserAccountService.cs
@@ -91,6 +91,7 @@ namespace OpenSim.Services.Interfaces
91 public int UserLevel; 91 public int UserLevel;
92 public int UserFlags; 92 public int UserFlags;
93 public string UserTitle; 93 public string UserTitle;
94 public string UserCountry;
94 public Boolean LocalToGrid = true; 95 public Boolean LocalToGrid = true;
95 96
96 public Dictionary<string, object> ServiceURLs; 97 public Dictionary<string, object> ServiceURLs;
@@ -120,6 +121,8 @@ namespace OpenSim.Services.Interfaces
120 UserFlags = Convert.ToInt32(kvp["UserFlags"].ToString()); 121 UserFlags = Convert.ToInt32(kvp["UserFlags"].ToString());
121 if (kvp.ContainsKey("UserTitle")) 122 if (kvp.ContainsKey("UserTitle"))
122 UserTitle = kvp["UserTitle"].ToString(); 123 UserTitle = kvp["UserTitle"].ToString();
124 if (kvp.ContainsKey("UserCountry"))
125 UserCountry = kvp["UserCountry"].ToString();
123 if (kvp.ContainsKey("LocalToGrid")) 126 if (kvp.ContainsKey("LocalToGrid"))
124 Boolean.TryParse(kvp["LocalToGrid"].ToString(), out LocalToGrid); 127 Boolean.TryParse(kvp["LocalToGrid"].ToString(), out LocalToGrid);
125 128
@@ -155,6 +158,7 @@ namespace OpenSim.Services.Interfaces
155 result["UserLevel"] = UserLevel.ToString(); 158 result["UserLevel"] = UserLevel.ToString();
156 result["UserFlags"] = UserFlags.ToString(); 159 result["UserFlags"] = UserFlags.ToString();
157 result["UserTitle"] = UserTitle; 160 result["UserTitle"] = UserTitle;
161 result["UserCountry"] = UserCountry;
158 result["LocalToGrid"] = LocalToGrid.ToString(); 162 result["LocalToGrid"] = LocalToGrid.ToString();
159 163
160 string str = string.Empty; 164 string str = string.Empty;
@@ -182,6 +186,7 @@ namespace OpenSim.Services.Interfaces
182 /// <param name="query"></param> 186 /// <param name="query"></param>
183 /// <returns></returns> 187 /// <returns></returns>
184 List<UserAccount> GetUserAccounts(UUID scopeID, string query); 188 List<UserAccount> GetUserAccounts(UUID scopeID, string query);
189 List<UserAccount> GetUserAccountsWhere(UUID scopeID, string where);
185 190
186 /// <summary> 191 /// <summary>
187 /// Store the data given, wich replaces the stored data, therefore must be complete. 192 /// Store the data given, wich replaces the stored data, therefore must be complete.
diff --git a/OpenSim/Services/Interfaces/IUserProfilesService.cs b/OpenSim/Services/Interfaces/IUserProfilesService.cs
index 121baa8..319d307 100644
--- a/OpenSim/Services/Interfaces/IUserProfilesService.cs
+++ b/OpenSim/Services/Interfaces/IUserProfilesService.cs
@@ -57,11 +57,6 @@ namespace OpenSim.Services.Interfaces
57 bool AvatarPropertiesRequest(ref UserProfileProperties prop, ref string result); 57 bool AvatarPropertiesRequest(ref UserProfileProperties prop, ref string result);
58 bool AvatarPropertiesUpdate(ref UserProfileProperties prop, ref string result); 58 bool AvatarPropertiesUpdate(ref UserProfileProperties prop, ref string result);
59 #endregion Profile Properties 59 #endregion Profile Properties
60
61 #region User Preferences
62 bool UserPreferencesRequest(ref UserPreferences pref, ref string result);
63 bool UserPreferencesUpdate(ref UserPreferences pref, ref string result);
64 #endregion User Preferences
65 60
66 #region Interests 61 #region Interests
67 bool AvatarInterestsUpdate(UserProfileProperties prop, ref string result); 62 bool AvatarInterestsUpdate(UserProfileProperties prop, ref string result);