aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Common/Mock/TestClient.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Tests/Common/Mock/TestClient.cs128
1 files changed, 104 insertions, 24 deletions
diff --git a/OpenSim/Tests/Common/Mock/TestClient.cs b/OpenSim/Tests/Common/Mock/TestClient.cs
index 0e1bc8f..449716b 100644
--- a/OpenSim/Tests/Common/Mock/TestClient.cs
+++ b/OpenSim/Tests/Common/Mock/TestClient.cs
@@ -88,7 +88,7 @@ namespace OpenSim.Tests.Common
88 public event MoneyTransferRequest OnMoneyTransferRequest; 88 public event MoneyTransferRequest OnMoneyTransferRequest;
89 public event ParcelBuy OnParcelBuy; 89 public event ParcelBuy OnParcelBuy;
90 public event Action<IClientAPI> OnConnectionClosed; 90 public event Action<IClientAPI> OnConnectionClosed;
91 91 public event MoveItemsAndLeaveCopy OnMoveItemsAndLeaveCopy;
92 public event ImprovedInstantMessage OnInstantMessage; 92 public event ImprovedInstantMessage OnInstantMessage;
93 public event ChatMessage OnChatFromClient; 93 public event ChatMessage OnChatFromClient;
94 public event TextureRequest OnRequestTexture; 94 public event TextureRequest OnRequestTexture;
@@ -105,6 +105,7 @@ namespace OpenSim.Tests.Common
105 public event ObjectDrop OnObjectDrop; 105 public event ObjectDrop OnObjectDrop;
106 public event StartAnim OnStartAnim; 106 public event StartAnim OnStartAnim;
107 public event StopAnim OnStopAnim; 107 public event StopAnim OnStopAnim;
108 public event ChangeAnim OnChangeAnim;
108 public event LinkObjects OnLinkObjects; 109 public event LinkObjects OnLinkObjects;
109 public event DelinkObjects OnDelinkObjects; 110 public event DelinkObjects OnDelinkObjects;
110 public event RequestMapBlocks OnRequestMapBlocks; 111 public event RequestMapBlocks OnRequestMapBlocks;
@@ -117,6 +118,7 @@ namespace OpenSim.Tests.Common
117 public event SetAlwaysRun OnSetAlwaysRun; 118 public event SetAlwaysRun OnSetAlwaysRun;
118 119
119 public event DeRezObject OnDeRezObject; 120 public event DeRezObject OnDeRezObject;
121 public event RezRestoreToWorld OnRezRestoreToWorld;
120 public event Action<IClientAPI> OnRegionHandShakeReply; 122 public event Action<IClientAPI> OnRegionHandShakeReply;
121 public event GenericCall1 OnRequestWearables; 123 public event GenericCall1 OnRequestWearables;
122 public event Action<IClientAPI, bool> OnCompleteMovementToRegion; 124 public event Action<IClientAPI, bool> OnCompleteMovementToRegion;
@@ -153,6 +155,7 @@ namespace OpenSim.Tests.Common
153 public event GenericCall7 OnObjectMaterial; 155 public event GenericCall7 OnObjectMaterial;
154 public event UpdatePrimFlags OnUpdatePrimFlags; 156 public event UpdatePrimFlags OnUpdatePrimFlags;
155 public event UpdatePrimTexture OnUpdatePrimTexture; 157 public event UpdatePrimTexture OnUpdatePrimTexture;
158 public event ClientChangeObject onClientChangeObject;
156 public event UpdateVector OnUpdatePrimGroupPosition; 159 public event UpdateVector OnUpdatePrimGroupPosition;
157 public event UpdateVector OnUpdatePrimSinglePosition; 160 public event UpdateVector OnUpdatePrimSinglePosition;
158 public event UpdatePrimRotation OnUpdatePrimGroupRotation; 161 public event UpdatePrimRotation OnUpdatePrimGroupRotation;
@@ -295,7 +298,7 @@ namespace OpenSim.Tests.Common
295 public event ClassifiedInfoRequest OnClassifiedInfoRequest; 298 public event ClassifiedInfoRequest OnClassifiedInfoRequest;
296 public event ClassifiedInfoUpdate OnClassifiedInfoUpdate; 299 public event ClassifiedInfoUpdate OnClassifiedInfoUpdate;
297 public event ClassifiedDelete OnClassifiedDelete; 300 public event ClassifiedDelete OnClassifiedDelete;
298 public event ClassifiedDelete OnClassifiedGodDelete; 301 public event ClassifiedGodDelete OnClassifiedGodDelete;
299 302
300 public event EventNotificationAddRequest OnEventNotificationAddRequest; 303 public event EventNotificationAddRequest OnEventNotificationAddRequest;
301 public event EventNotificationRemoveRequest OnEventNotificationRemoveRequest; 304 public event EventNotificationRemoveRequest OnEventNotificationRemoveRequest;
@@ -318,7 +321,7 @@ namespace OpenSim.Tests.Common
318 public event AvatarInterestUpdate OnAvatarInterestUpdate; 321 public event AvatarInterestUpdate OnAvatarInterestUpdate;
319 322
320 public event PlacesQuery OnPlacesQuery; 323 public event PlacesQuery OnPlacesQuery;
321 324
322 public event FindAgentUpdate OnFindAgent; 325 public event FindAgentUpdate OnFindAgent;
323 public event TrackAgentUpdate OnTrackAgent; 326 public event TrackAgentUpdate OnTrackAgent;
324 public event NewUserReport OnUserReport; 327 public event NewUserReport OnUserReport;
@@ -334,11 +337,12 @@ namespace OpenSim.Tests.Common
334 public event GroupVoteHistoryRequest OnGroupVoteHistoryRequest; 337 public event GroupVoteHistoryRequest OnGroupVoteHistoryRequest;
335 public event SimWideDeletesDelegate OnSimWideDeletes; 338 public event SimWideDeletesDelegate OnSimWideDeletes;
336 public event SendPostcard OnSendPostcard; 339 public event SendPostcard OnSendPostcard;
340 public event ChangeInventoryItemFlags OnChangeInventoryItemFlags;
337 public event MuteListEntryUpdate OnUpdateMuteListEntry; 341 public event MuteListEntryUpdate OnUpdateMuteListEntry;
338 public event MuteListEntryRemove OnRemoveMuteListEntry; 342 public event MuteListEntryRemove OnRemoveMuteListEntry;
339 public event GodlikeMessage onGodlikeMessage; 343 public event GodlikeMessage onGodlikeMessage;
340 public event GodUpdateRegionInfoUpdate OnGodUpdateRegionInfoUpdate; 344 public event GodUpdateRegionInfoUpdate OnGodUpdateRegionInfoUpdate;
341 345 public event GenericCall2 OnUpdateThrottles;
342#pragma warning restore 67 346#pragma warning restore 67
343 347
344 /// <value> 348 /// <value>
@@ -387,6 +391,8 @@ namespace OpenSim.Tests.Common
387 get { return FirstName + " " + LastName; } 391 get { return FirstName + " " + LastName; }
388 } 392 }
389 393
394 public int PingTimeMS { get { return 0; } }
395
390 public bool IsActive 396 public bool IsActive
391 { 397 {
392 get { return true; } 398 get { return true; }
@@ -398,16 +404,19 @@ namespace OpenSim.Tests.Common
398 public UUID ActiveGroupId 404 public UUID ActiveGroupId
399 { 405 {
400 get { return UUID.Zero; } 406 get { return UUID.Zero; }
407 set { }
401 } 408 }
402 409
403 public string ActiveGroupName 410 public string ActiveGroupName
404 { 411 {
405 get { return String.Empty; } 412 get { return String.Empty; }
413 set { }
406 } 414 }
407 415
408 public ulong ActiveGroupPowers 416 public ulong ActiveGroupPowers
409 { 417 {
410 get { return 0; } 418 get { return 0; }
419 set { }
411 } 420 }
412 421
413 public bool IsGroupMember(UUID groupID) 422 public bool IsGroupMember(UUID groupID)
@@ -415,6 +424,13 @@ namespace OpenSim.Tests.Common
415 return false; 424 return false;
416 } 425 }
417 426
427 public Dictionary<UUID, ulong> GetGroupPowers()
428 {
429 return new Dictionary<UUID, ulong>();
430 }
431
432 public void SetGroupPowers(Dictionary<UUID, ulong> powers) { }
433
418 public ulong GetGroupPowers(UUID groupID) 434 public ulong GetGroupPowers(UUID groupID)
419 { 435 {
420 return 0; 436 return 0;
@@ -448,6 +464,8 @@ namespace OpenSim.Tests.Common
448 get { return new IPEndPoint(IPAddress.Loopback, (ushort)m_circuitCode); } 464 get { return new IPEndPoint(IPAddress.Loopback, (ushort)m_circuitCode); }
449 } 465 }
450 466
467 public List<uint> SelectedObjects {get; private set;}
468
451 /// <summary> 469 /// <summary>
452 /// Constructor 470 /// Constructor
453 /// </summary> 471 /// </summary>
@@ -570,10 +588,27 @@ namespace OpenSim.Tests.Common
570 ReceivedKills.AddRange(localID); 588 ReceivedKills.AddRange(localID);
571 } 589 }
572 590
591 public void SendPartFullUpdate(ISceneEntity ent, uint? parentID)
592 {
593 }
594
573 public virtual void SetChildAgentThrottle(byte[] throttle) 595 public virtual void SetChildAgentThrottle(byte[] throttle)
574 { 596 {
575 } 597 }
576 598
599 public virtual void SetChildAgentThrottle(byte[] throttle, float factor)
600 {
601 }
602
603 public void SetAgentThrottleSilent(int throttle, int setting)
604 {
605 }
606
607 public int GetAgentThrottleSilent(int throttle)
608 {
609 return 0;
610 }
611
577 public byte[] GetThrottlesPacked(float multiplier) 612 public byte[] GetThrottlesPacked(float multiplier)
578 { 613 {
579 return new byte[0]; 614 return new byte[0];
@@ -608,6 +643,11 @@ namespace OpenSim.Tests.Common
608 643
609 } 644 }
610 645
646 public virtual bool CanSendLayerData()
647 {
648 return false;
649 }
650
611 public virtual void SendLayerData(float[] map) 651 public virtual void SendLayerData(float[] map)
612 { 652 {
613 } 653 }
@@ -619,9 +659,9 @@ namespace OpenSim.Tests.Common
619 { 659 {
620 } 660 }
621 661
622 public virtual void SendWindData(Vector2[] windSpeeds) { } 662 public virtual void SendWindData(int version, Vector2[] windSpeeds) { }
623 663
624 public virtual void SendCloudData(float[] cloudCover) { } 664 public virtual void SendCloudData(int version, float[] cloudCover) { }
625 665
626 public virtual void MoveAgentIntoRegion(RegionInfo regInfo, Vector3 pos, Vector3 look) 666 public virtual void MoveAgentIntoRegion(RegionInfo regInfo, Vector3 pos, Vector3 look)
627 { 667 {
@@ -633,7 +673,7 @@ namespace OpenSim.Tests.Common
633 { 673 {
634 AgentCircuitData agentData = new AgentCircuitData(); 674 AgentCircuitData agentData = new AgentCircuitData();
635 agentData.AgentID = AgentId; 675 agentData.AgentID = AgentId;
636 agentData.SessionID = SessionId; 676 agentData.SessionID = SessionId;
637 agentData.SecureSessionID = UUID.Zero; 677 agentData.SecureSessionID = UUID.Zero;
638 agentData.circuitcode = m_circuitCode; 678 agentData.circuitcode = m_circuitCode;
639 agentData.child = false; 679 agentData.child = false;
@@ -673,7 +713,7 @@ namespace OpenSim.Tests.Common
673 public virtual void SendTeleportFailed(string reason) 713 public virtual void SendTeleportFailed(string reason)
674 { 714 {
675 m_log.DebugFormat( 715 m_log.DebugFormat(
676 "[TEST CLIENT]: Teleport failed for {0} {1} on {2} with reason {3}", 716 "[TEST CLIENT]: Teleport failed for {0} {1} on {2} with reason {3}",
677 m_firstName, m_lastName, m_scene.Name, reason); 717 m_firstName, m_lastName, m_scene.Name, reason);
678 } 718 }
679 719
@@ -720,7 +760,11 @@ namespace OpenSim.Tests.Common
720 { 760 {
721 } 761 }
722 762
723 public void SendAvatarDataImmediate(ISceneEntity avatar) 763 public void SendEntityFullUpdateImmediate(ISceneEntity ent)
764 {
765 }
766
767 public void SendEntityTerseUpdateImmediate(ISceneEntity ent)
724 { 768 {
725 } 769 }
726 770
@@ -741,7 +785,7 @@ namespace OpenSim.Tests.Common
741 public virtual void SendInventoryFolderDetails(UUID ownerID, UUID folderID, 785 public virtual void SendInventoryFolderDetails(UUID ownerID, UUID folderID,
742 List<InventoryItemBase> items, 786 List<InventoryItemBase> items,
743 List<InventoryFolderBase> folders, 787 List<InventoryFolderBase> folders,
744 int version, 788 int version,
745 bool fetchFolders, 789 bool fetchFolders,
746 bool fetchItems) 790 bool fetchItems)
747 { 791 {
@@ -755,6 +799,10 @@ namespace OpenSim.Tests.Common
755 { 799 {
756 } 800 }
757 801
802 public void SendInventoryItemCreateUpdate(InventoryItemBase Item, UUID transactionID, uint callbackId)
803 {
804 }
805
758 public virtual void SendRemoveInventoryItem(UUID itemID) 806 public virtual void SendRemoveInventoryItem(UUID itemID)
759 { 807 {
760 } 808 }
@@ -771,7 +819,7 @@ namespace OpenSim.Tests.Common
771 { 819 {
772 } 820 }
773 821
774 public virtual void SendXferPacket(ulong xferID, uint packet, byte[] data) 822 public virtual void SendXferPacket(ulong xferID, uint packet, byte[] data, bool isTaskInventory)
775 { 823 {
776 } 824 }
777 825
@@ -817,6 +865,10 @@ namespace OpenSim.Tests.Common
817 { 865 {
818 } 866 }
819 867
868 public void SendAlertMessage(string message, string info)
869 {
870 }
871
820 public void SendSystemAlertMessage(string message) 872 public void SendSystemAlertMessage(string message)
821 { 873 {
822 } 874 }
@@ -833,7 +885,7 @@ namespace OpenSim.Tests.Common
833 OnRegionHandShakeReply(this); 885 OnRegionHandShakeReply(this);
834 } 886 }
835 } 887 }
836 888
837 public void SendAssetUploadCompleteMessage(sbyte AssetType, bool Success, UUID AssetFullID) 889 public void SendAssetUploadCompleteMessage(sbyte AssetType, bool Success, UUID AssetFullID)
838 { 890 {
839 } 891 }
@@ -910,8 +962,13 @@ namespace OpenSim.Tests.Common
910 ReceivedOnlineNotifications.AddRange(agentIDs); 962 ReceivedOnlineNotifications.AddRange(agentIDs);
911 } 963 }
912 964
913 public void SendSitResponse(UUID TargetID, Vector3 OffsetPos, Quaternion SitOrientation, bool autopilot, 965 public void SendFindAgent(UUID HunterID, UUID PreyID, double GlobalX, double GlobalY)
914 Vector3 CameraAtOffset, Vector3 CameraEyeOffset, bool ForceMouseLook) 966 {
967 }
968
969 public void SendSitResponse(UUID TargetID, Vector3 OffsetPos,
970 Quaternion SitOrientation, bool autopilot,
971 Vector3 CameraAtOffset, Vector3 CameraEyeOffset, bool ForceMouseLook)
915 { 972 {
916 } 973 }
917 974
@@ -937,7 +994,7 @@ namespace OpenSim.Tests.Common
937 { 994 {
938 } 995 }
939 996
940 public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] charterMember, 997 public void SendAvatarProperties(UUID avatarID, string aboutText, string bornOn, Byte[] membershipType,
941 string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL, 998 string flAbout, uint flags, UUID flImageID, UUID imageID, string profileURL,
942 UUID partnerID) 999 UUID partnerID)
943 { 1000 {
@@ -966,10 +1023,10 @@ namespace OpenSim.Tests.Common
966 1023
967 public void Close() 1024 public void Close()
968 { 1025 {
969 Close(false); 1026 Close(true, false);
970 } 1027 }
971 1028
972 public void Close(bool force) 1029 public void Close(bool sendStop, bool force)
973 { 1030 {
974 // Fire the callback for this connection closing 1031 // Fire the callback for this connection closing
975 // This is necesary to get the presence detector to notice that a client has logged out. 1032 // This is necesary to get the presence detector to notice that a client has logged out.
@@ -1175,6 +1232,10 @@ namespace OpenSim.Tests.Common
1175 { 1232 {
1176 } 1233 }
1177 1234
1235 public void SendAgentGroupDataUpdate(UUID avatarID, GroupMembershipData[] data)
1236 {
1237 }
1238
1178 public void SendJoinGroupReply(UUID groupID, bool success) 1239 public void SendJoinGroupReply(UUID groupID, bool success)
1179 { 1240 {
1180 } 1241 }
@@ -1238,14 +1299,30 @@ namespace OpenSim.Tests.Common
1238 { 1299 {
1239 } 1300 }
1240 1301
1302 public void UpdateGroupMembership(GroupMembershipData[] data)
1303 {
1304 }
1305
1306 public void GroupMembershipRemove(UUID GroupID)
1307 {
1308 }
1309
1310 public void GroupMembershipAddReplace(UUID GroupID,ulong GroupPowers)
1311 {
1312 }
1313
1241 public void SendUseCachedMuteList() 1314 public void SendUseCachedMuteList()
1242 { 1315 {
1243 } 1316 }
1244 1317
1318 public void SendEmpytMuteList()
1319 {
1320 }
1321
1245 public void SendMuteListUpdate(string filename) 1322 public void SendMuteListUpdate(string filename)
1246 { 1323 {
1247 } 1324 }
1248 1325
1249 public void SendPickInfoReply(UUID pickID,UUID creatorID, bool topPick, UUID parcelID, string name, string desc, UUID snapshotID, string user, string originalName, string simName, Vector3 posGlobal, int sortOrder, bool enabled) 1326 public void SendPickInfoReply(UUID pickID,UUID creatorID, bool topPick, UUID parcelID, string name, string desc, UUID snapshotID, string user, string originalName, string simName, Vector3 posGlobal, int sortOrder, bool enabled)
1250 { 1327 {
1251 } 1328 }
@@ -1265,7 +1342,7 @@ namespace OpenSim.Tests.Common
1265 { 1342 {
1266 } 1343 }
1267 1344
1268 public void Disconnect() 1345 public void Disconnect()
1269 { 1346 {
1270 } 1347 }
1271 1348
@@ -1274,19 +1351,19 @@ namespace OpenSim.Tests.Common
1274 if (OnReceivedSendRebakeAvatarTextures != null) 1351 if (OnReceivedSendRebakeAvatarTextures != null)
1275 OnReceivedSendRebakeAvatarTextures(textureID); 1352 OnReceivedSendRebakeAvatarTextures(textureID);
1276 } 1353 }
1277 1354
1278 public void SendAvatarInterestsReply(UUID avatarID, uint wantMask, string wantText, uint skillsMask, string skillsText, string languages) 1355 public void SendAvatarInterestsReply(UUID avatarID, uint wantMask, string wantText, uint skillsMask, string skillsText, string languages)
1279 { 1356 {
1280 } 1357 }
1281 1358
1282 public void SendGroupAccountingDetails(IClientAPI sender,UUID groupID, UUID transactionID, UUID sessionID, int amt) 1359 public void SendGroupAccountingDetails(IClientAPI sender,UUID groupID, UUID transactionID, UUID sessionID, int amt)
1283 { 1360 {
1284 } 1361 }
1285 1362
1286 public void SendGroupAccountingSummary(IClientAPI sender,UUID groupID, uint moneyAmt, int totalTier, int usedTier) 1363 public void SendGroupAccountingSummary(IClientAPI sender,UUID groupID, uint moneyAmt, int totalTier, int usedTier)
1287 { 1364 {
1288 } 1365 }
1289 1366
1290 public void SendGroupTransactionsSummaryDetails(IClientAPI sender,UUID groupID, UUID transactionID, UUID sessionID,int amt) 1367 public void SendGroupTransactionsSummaryDetails(IClientAPI sender,UUID groupID, UUID transactionID, UUID sessionID,int amt)
1291 { 1368 {
1292 } 1369 }
@@ -1315,9 +1392,12 @@ namespace OpenSim.Tests.Common
1315 { 1392 {
1316 } 1393 }
1317 1394
1318 public void SendPartPhysicsProprieties(ISceneEntity entity) 1395 public void SendSelectedPartsProprieties(List<ISceneEntity> parts)
1319 { 1396 {
1320 } 1397 }
1321 1398
1399 public void SendPartPhysicsProprieties(ISceneEntity entity)
1400 {
1401 }
1322 } 1402 }
1323} 1403}