Tweet.cs 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. using UnityEngine;
  2. using Newtonsoft.Json;
  3. using System;
  4. namespace DataTools
  5. {
  6. [Serializable]
  7. public class Tweet : DataObject
  8. {
  9. [JsonProperty]
  10. [SerializeField]
  11. private string senderID;
  12. [JsonProperty]
  13. [SerializeField]
  14. private int numberOFfollowes;
  15. [JsonProperty]
  16. [SerializeField]
  17. private string tweetMsg;
  18. [JsonProperty]
  19. [SerializeField]
  20. private string type;
  21. [JsonProperty]
  22. [SerializeField]
  23. private int typeIndex;
  24. [JsonProperty]
  25. [SerializeField]
  26. private string hashTag;
  27. [JsonProperty]
  28. [SerializeField]
  29. private string location;
  30. public void TweetSET(string Id, string senderid, int numberofFollowers, string tweetMsg, int TypeIndex, string Hashtag, string newLocation)
  31. {
  32. this.Id = Id;
  33. this.senderID = senderid;
  34. this.numberOFfollowes = numberofFollowers;
  35. this.tweetMsg = tweetMsg;
  36. this.typeIndex = TypeIndex;
  37. this.hashTag = Hashtag;
  38. this.location = newLocation;
  39. }
  40. [JsonIgnore]
  41. public string Location
  42. {
  43. get
  44. {
  45. return location;
  46. }
  47. set
  48. {
  49. location = value;
  50. }
  51. }
  52. [JsonIgnore]
  53. public string SenderID
  54. {
  55. get
  56. {
  57. return senderID;
  58. }
  59. set
  60. {
  61. senderID = value;
  62. }
  63. }
  64. [JsonIgnore]
  65. public int NumberOFfollowes
  66. {
  67. get
  68. {
  69. return numberOFfollowes;
  70. }
  71. set
  72. {
  73. numberOFfollowes = value;
  74. }
  75. }
  76. [JsonIgnore]
  77. public string TweetMsg
  78. {
  79. get
  80. {
  81. return tweetMsg;
  82. }
  83. set
  84. {
  85. tweetMsg = value;
  86. }
  87. }
  88. [JsonIgnore]
  89. public string Type
  90. {
  91. get
  92. {
  93. return type;
  94. }
  95. set
  96. {
  97. type = value;
  98. }
  99. }
  100. [JsonIgnore]
  101. public int TypeIndex
  102. {
  103. get
  104. {
  105. return typeIndex;
  106. }
  107. set
  108. {
  109. typeIndex = value;
  110. }
  111. }
  112. [JsonIgnore]
  113. public string HashTag
  114. {
  115. get
  116. {
  117. return hashTag;
  118. }
  119. set
  120. {
  121. hashTag = value;
  122. }
  123. }
  124. }
  125. }