LLSDInventoryItem.cs 3.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  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 OpenSim 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. namespace OpenSim.Framework.Communications.Capabilities
  29. {
  30. [OSDMap]
  31. public class LLSDInventoryItem
  32. {
  33. public UUID parent_id;
  34. public UUID asset_id;
  35. public UUID item_id;
  36. public LLSDPermissions permissions;
  37. public string type;
  38. public string inv_type;
  39. public int flags;
  40. public LLSDSaleInfo sale_info;
  41. public string name;
  42. public string desc;
  43. public int created_at;
  44. }
  45. [OSDMap]
  46. public class LLSDPermissions
  47. {
  48. public UUID creator_id;
  49. public UUID owner_id;
  50. public UUID group_id;
  51. public int base_mask;
  52. public int owner_mask;
  53. public int group_mask;
  54. public int everyone_mask;
  55. public int next_owner_mask;
  56. public bool is_owner_group;
  57. }
  58. [OSDMap]
  59. public class LLSDSaleInfo
  60. {
  61. public int sale_price;
  62. public string sale_type;
  63. }
  64. [OSDMap]
  65. public class LLSDInventoryDescendents
  66. {
  67. public OSDArray folders = new OSDArray();
  68. }
  69. [OSDMap]
  70. public class LLSDFetchInventoryDescendents
  71. {
  72. public UUID folder_id;
  73. public UUID owner_id;
  74. public int sort_order;
  75. public bool fetch_folders;
  76. public bool fetch_items;
  77. }
  78. [OSDMap]
  79. public class LLSDInventoryFolderContents
  80. {
  81. public UUID agent___id; // the (three "_") "___" so the serialising knows to change this to a "-"
  82. public int descendents;
  83. public UUID folder___id; //as LL can't decide if they are going to use "_" or "-" to separate words in the field names
  84. public OSDArray items = new OSDArray();
  85. public UUID owner___id; // and of course we can't have field names with "-" in
  86. public int version;
  87. }
  88. }