IDialogModule.cs 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. /*
  2. * Copyright (c) Contributors, http://opensimulator.org/
  3. * See CONTRIBUTORS.TXT for a full list of copyright holders.
  4. *
  5. * Redistribution and use in source and binary forms, with or without
  6. * modification, are permitted provided that the following conditions are met:
  7. * * Redistributions of source code must retain the above copyright
  8. * notice, this list of conditions and the following disclaimer.
  9. * * Redistributions in binary form must reproduce the above copyright
  10. * notice, this list of conditions and the following disclaimer in the
  11. * documentation and/or other materials provided with the distribution.
  12. * * Neither the name of the OpenSimulator Project nor the
  13. * names of its contributors may be used to endorse or promote products
  14. * derived from this software without specific prior written permission.
  15. *
  16. * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY
  17. * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  18. * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  19. * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY
  20. * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  21. * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  22. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  23. * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  24. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  25. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  26. */
  27. using OpenMetaverse;
  28. using OpenSim.Framework;
  29. namespace OpenSim.Region.Framework.Interfaces
  30. {
  31. public interface IDialogModule
  32. {
  33. /// <summary>
  34. /// Send a non-modal alert message to a particular user. This can
  35. /// disappear from the user's view after a small interval.
  36. /// </summary>
  37. /// <param name="client">
  38. /// IClientAPI object representing the user.
  39. /// </param>
  40. /// <param name="message">Message text to send to the user.</param>
  41. void SendAlertToUser(IClientAPI client, string message);
  42. /// <summary>
  43. /// Send an alert message to a particular user.
  44. /// </summary>
  45. /// <param name="client">
  46. /// IClientAPI object representing the user.
  47. /// </param>
  48. /// <param name="message">Message text to send to the user.</param>
  49. /// <param name="modal">Flag to control modality.</param>
  50. void SendAlertToUser(IClientAPI client, string message, bool modal);
  51. /// <summary>
  52. /// Send a non-modal alert message to a particular user.
  53. /// </summary>
  54. /// <param name="agentID">UUID of agent representing the user.</param>
  55. /// <param name="message">Message text to send to the user.</param>
  56. void SendAlertToUser(UUID agentID, string message);
  57. /// <summary>
  58. /// Send an alert message to a particular user.
  59. /// </summary>
  60. /// <param name="agentID">UUID of agent representing the user.</param>
  61. /// <param name="message">Message text to send to the user.</param>
  62. /// <param name="modal">Flag to control modality.</param>
  63. void SendAlertToUser(UUID agentID, string message, bool modal);
  64. /// <summary>
  65. /// Send an alert message to a particular user.
  66. /// </summary>
  67. /// <param name="firstName">Account first name</param>
  68. /// <param name="lastName">Account last name</param>
  69. /// <param name="message">Message text to send to the user.</param>
  70. /// <param name="modal">Flag to control modality.</param>
  71. void SendAlertToUser(string firstName, string lastName,
  72. string message, bool modal);
  73. /// <summary>
  74. /// Send an alert message to all users in the scene.
  75. /// </summary>
  76. /// <param name="message">Message text to send to all users.</param>
  77. void SendGeneralAlert(string message);
  78. /// <summary>
  79. /// Send a dialog box to a particular user.
  80. /// </summary>
  81. /// <param name="avatarID">
  82. /// UUID of the avatar representing the user.
  83. /// </param>
  84. /// <param name="objectName">
  85. /// Name of the object sending the dialog.
  86. /// </param>
  87. /// <param name="objectID">
  88. /// UUID of the object sending the dialog.
  89. /// </param>
  90. /// <param name="ownerID">
  91. /// UUID of the user that owns the object.
  92. /// </param>
  93. /// <param name="message">Message text to send to the user.</param>
  94. /// <param name="textureID">
  95. /// Texture UUID to pass along with the dialog.
  96. /// </param>
  97. /// <param name="ch">
  98. /// Channel on which the selected button text should be broadcast.
  99. /// </param>
  100. /// <param name="buttonlabels">Dialog button text.</param>
  101. void SendDialogToUser(UUID avatarID, string objectName, UUID objectID,
  102. UUID ownerID, string message, UUID textureID, int ch,
  103. string[] buttonlabels);
  104. /// <summary>
  105. /// Send a url to a particular user.
  106. /// </summary>
  107. /// <param name="avatarID">
  108. /// UUID of the avatar representing the user.
  109. /// </param>
  110. /// <param name="objectName">
  111. /// Name of the object sending the dialog.
  112. /// </param>
  113. /// <param name="objectID">
  114. /// UUID of the object sending the dialog.
  115. /// </param>
  116. /// <param name="ownerID">
  117. /// UUID of the user that owns the object.
  118. /// </param>
  119. /// <param name="groupOwned">
  120. /// Flag indicating whether or not the object is group-owned.
  121. /// </param>
  122. /// <param name="message">Message text to send to the user.</param>
  123. /// <param name="url">Url to send to the user.</param>
  124. void SendUrlToUser(UUID avatarID, string objectName, UUID objectID,
  125. UUID ownerID, bool groupOwned, string message, string url);
  126. /// <summary>
  127. /// Send a notification to all users in the scene. This notification
  128. /// should remain around until the user explicitly dismisses it.
  129. /// </summary>
  130. /// <remarks>
  131. /// On the Linden Labs Second Client (as of 1.21), this is a big blue
  132. /// box message on the upper right of the screen.
  133. /// </remarks>
  134. /// <param name="fromAvatarID">The user sending the message</param>
  135. /// <param name="fromAvatarName">
  136. /// The name of the user doing the sending
  137. /// </param>
  138. /// <param name="message">The message being sent to the user</param>
  139. void SendNotificationToUsersInRegion(UUID fromAvatarID,
  140. string fromAvatarName, string message);
  141. /// <summary>
  142. /// Send a textbox entry for the client to respond to
  143. /// </summary>
  144. /// <param name="avatarID">
  145. /// UUID of the avatar representing the user.
  146. /// </param>
  147. /// <param name="message">Message text to send to the user.</param>
  148. /// <param name="chatChannel">
  149. /// Chat channel that the user's input should be broadcast on.
  150. /// </param>
  151. /// <param name="name">Name of the object sending the dialog.</param>
  152. /// <param name="objectid">
  153. /// UUID of the object sending the dialog.
  154. /// </param>
  155. /// <param name="ownerid">
  156. /// UUID of the user that owns the object.
  157. /// </param>
  158. void SendTextBoxToUser(UUID avatarid, string message, int chatChannel,
  159. string name, UUID objectid, UUID ownerid);
  160. }
  161. }