UserSetting.java 8.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338
  1. package com.genersoft.iot.vmp.conf;
  2. import org.springframework.boot.context.properties.ConfigurationProperties;
  3. import org.springframework.core.annotation.Order;
  4. import org.springframework.stereotype.Component;
  5. import java.util.ArrayList;
  6. import java.util.List;
  7. /**
  8. * 配置文件 user-settings 映射的配置信息
  9. */
  10. @Component
  11. @ConfigurationProperties(prefix = "user-settings", ignoreInvalidFields = true)
  12. @Order(0)
  13. public class UserSetting {
  14. private Boolean savePositionHistory = Boolean.FALSE;
  15. private Boolean autoApplyPlay = Boolean.FALSE;
  16. private Boolean seniorSdp = Boolean.FALSE;
  17. private Integer playTimeout = 10000;
  18. private int platformPlayTimeout = 20000;
  19. private Boolean interfaceAuthentication = Boolean.TRUE;
  20. private Boolean recordPushLive = Boolean.TRUE;
  21. private Boolean recordSip = Boolean.TRUE;
  22. private Boolean logInDatabase = Boolean.TRUE;
  23. private Boolean usePushingAsStatus = Boolean.FALSE;
  24. private Boolean useSourceIpAsStreamIp = Boolean.FALSE;
  25. private Boolean sipUseSourceIpAsRemoteAddress = Boolean.FALSE;
  26. private Boolean streamOnDemand = Boolean.TRUE;
  27. private Boolean pushAuthority = Boolean.TRUE;
  28. private Boolean syncChannelOnDeviceOnline = Boolean.FALSE;
  29. private Boolean sipLog = Boolean.FALSE;
  30. private Boolean sqlLog = Boolean.FALSE;
  31. private Boolean sendToPlatformsWhenIdLost = Boolean.FALSE;
  32. private Boolean refuseChannelStatusChannelFormNotify = Boolean.FALSE;
  33. private Boolean deviceStatusNotify = Boolean.TRUE;
  34. private Boolean useCustomSsrcForParentInvite = Boolean.TRUE;
  35. private Boolean docEnable = Boolean.TRUE;
  36. private String serverId = "000000";
  37. private String thirdPartyGBIdReg = "[\\s\\S]*";
  38. private String broadcastForPlatform = "UDP";
  39. private String civilCodeFile = "classpath:civilCode.csv";
  40. private List<String> interfaceAuthenticationExcludes = new ArrayList<>();
  41. private List<String> allowedOrigins = new ArrayList<>();
  42. private int maxNotifyCountQueue = 100000;
  43. private int registerAgainAfterTime = 60;
  44. private boolean registerKeepIntDialog = false;
  45. private int gbDeviceOnline = 1;
  46. public Boolean getSavePositionHistory() {
  47. return savePositionHistory;
  48. }
  49. public Boolean isSavePositionHistory() {
  50. return savePositionHistory;
  51. }
  52. public Boolean isAutoApplyPlay() {
  53. return autoApplyPlay;
  54. }
  55. public Boolean isSeniorSdp() {
  56. return seniorSdp;
  57. }
  58. public Integer getPlayTimeout() {
  59. return playTimeout;
  60. }
  61. public Boolean isInterfaceAuthentication() {
  62. return interfaceAuthentication;
  63. }
  64. public Boolean isRecordPushLive() {
  65. return recordPushLive;
  66. }
  67. public List<String> getInterfaceAuthenticationExcludes() {
  68. return interfaceAuthenticationExcludes;
  69. }
  70. public void setSavePositionHistory(Boolean savePositionHistory) {
  71. this.savePositionHistory = savePositionHistory;
  72. }
  73. public void setAutoApplyPlay(Boolean autoApplyPlay) {
  74. this.autoApplyPlay = autoApplyPlay;
  75. }
  76. public void setSeniorSdp(Boolean seniorSdp) {
  77. this.seniorSdp = seniorSdp;
  78. }
  79. public void setPlayTimeout(Integer playTimeout) {
  80. this.playTimeout = playTimeout;
  81. }
  82. public void setInterfaceAuthentication(boolean interfaceAuthentication) {
  83. this.interfaceAuthentication = interfaceAuthentication;
  84. }
  85. public void setRecordPushLive(Boolean recordPushLive) {
  86. this.recordPushLive = recordPushLive;
  87. }
  88. public void setInterfaceAuthenticationExcludes(List<String> interfaceAuthenticationExcludes) {
  89. this.interfaceAuthenticationExcludes = interfaceAuthenticationExcludes;
  90. }
  91. public Boolean getLogInDatabase() {
  92. return logInDatabase;
  93. }
  94. public void setLogInDatabase(Boolean logInDatabase) {
  95. this.logInDatabase = logInDatabase;
  96. }
  97. public String getServerId() {
  98. return serverId;
  99. }
  100. public void setServerId(String serverId) {
  101. this.serverId = serverId;
  102. }
  103. public String getThirdPartyGBIdReg() {
  104. return thirdPartyGBIdReg;
  105. }
  106. public void setThirdPartyGBIdReg(String thirdPartyGBIdReg) {
  107. this.thirdPartyGBIdReg = thirdPartyGBIdReg;
  108. }
  109. public Boolean getRecordSip() {
  110. return recordSip;
  111. }
  112. public void setRecordSip(Boolean recordSip) {
  113. this.recordSip = recordSip;
  114. }
  115. public int getPlatformPlayTimeout() {
  116. return platformPlayTimeout;
  117. }
  118. public void setPlatformPlayTimeout(int platformPlayTimeout) {
  119. this.platformPlayTimeout = platformPlayTimeout;
  120. }
  121. public Boolean isUsePushingAsStatus() {
  122. return usePushingAsStatus;
  123. }
  124. public void setUsePushingAsStatus(Boolean usePushingAsStatus) {
  125. this.usePushingAsStatus = usePushingAsStatus;
  126. }
  127. public Boolean getStreamOnDemand() {
  128. return streamOnDemand;
  129. }
  130. public void setStreamOnDemand(Boolean streamOnDemand) {
  131. this.streamOnDemand = streamOnDemand;
  132. }
  133. public Boolean getUseSourceIpAsStreamIp() {
  134. return useSourceIpAsStreamIp;
  135. }
  136. public void setUseSourceIpAsStreamIp(Boolean useSourceIpAsStreamIp) {
  137. this.useSourceIpAsStreamIp = useSourceIpAsStreamIp;
  138. }
  139. public Boolean getPushAuthority() {
  140. return pushAuthority;
  141. }
  142. public void setPushAuthority(Boolean pushAuthority) {
  143. this.pushAuthority = pushAuthority;
  144. }
  145. public Boolean getSyncChannelOnDeviceOnline() {
  146. return syncChannelOnDeviceOnline;
  147. }
  148. public void setSyncChannelOnDeviceOnline(Boolean syncChannelOnDeviceOnline) {
  149. this.syncChannelOnDeviceOnline = syncChannelOnDeviceOnline;
  150. }
  151. public String getBroadcastForPlatform() {
  152. return broadcastForPlatform;
  153. }
  154. public void setBroadcastForPlatform(String broadcastForPlatform) {
  155. this.broadcastForPlatform = broadcastForPlatform;
  156. }
  157. public Boolean getSipUseSourceIpAsRemoteAddress() {
  158. return sipUseSourceIpAsRemoteAddress;
  159. }
  160. public void setSipUseSourceIpAsRemoteAddress(Boolean sipUseSourceIpAsRemoteAddress) {
  161. this.sipUseSourceIpAsRemoteAddress = sipUseSourceIpAsRemoteAddress;
  162. }
  163. public Boolean getSipLog() {
  164. return sipLog;
  165. }
  166. public void setSipLog(Boolean sipLog) {
  167. this.sipLog = sipLog;
  168. }
  169. public List<String> getAllowedOrigins() {
  170. return allowedOrigins;
  171. }
  172. public void setAllowedOrigins(List<String> allowedOrigins) {
  173. this.allowedOrigins = allowedOrigins;
  174. }
  175. public Boolean getSendToPlatformsWhenIdLost() {
  176. return sendToPlatformsWhenIdLost;
  177. }
  178. public void setSendToPlatformsWhenIdLost(Boolean sendToPlatformsWhenIdLost) {
  179. this.sendToPlatformsWhenIdLost = sendToPlatformsWhenIdLost;
  180. }
  181. public Boolean getRefuseChannelStatusChannelFormNotify() {
  182. return refuseChannelStatusChannelFormNotify;
  183. }
  184. public void setRefuseChannelStatusChannelFormNotify(Boolean refuseChannelStatusChannelFormNotify) {
  185. this.refuseChannelStatusChannelFormNotify = refuseChannelStatusChannelFormNotify;
  186. }
  187. public int getMaxNotifyCountQueue() {
  188. return maxNotifyCountQueue;
  189. }
  190. public void setMaxNotifyCountQueue(int maxNotifyCountQueue) {
  191. this.maxNotifyCountQueue = maxNotifyCountQueue;
  192. }
  193. public Boolean getDeviceStatusNotify() {
  194. return deviceStatusNotify;
  195. }
  196. public void setDeviceStatusNotify(Boolean deviceStatusNotify) {
  197. this.deviceStatusNotify = deviceStatusNotify;
  198. }
  199. public Boolean getUseCustomSsrcForParentInvite() {
  200. return useCustomSsrcForParentInvite;
  201. }
  202. public void setUseCustomSsrcForParentInvite(Boolean useCustomSsrcForParentInvite) {
  203. this.useCustomSsrcForParentInvite = useCustomSsrcForParentInvite;
  204. }
  205. public Boolean getSqlLog() {
  206. return sqlLog;
  207. }
  208. public void setSqlLog(Boolean sqlLog) {
  209. this.sqlLog = sqlLog;
  210. }
  211. public String getCivilCodeFile() {
  212. return civilCodeFile;
  213. }
  214. public void setCivilCodeFile(String civilCodeFile) {
  215. this.civilCodeFile = civilCodeFile;
  216. }
  217. public int getRegisterAgainAfterTime() {
  218. return registerAgainAfterTime;
  219. }
  220. public void setRegisterAgainAfterTime(int registerAgainAfterTime) {
  221. this.registerAgainAfterTime = registerAgainAfterTime;
  222. }
  223. public boolean isRegisterKeepIntDialog() {
  224. return registerKeepIntDialog;
  225. }
  226. public void setRegisterKeepIntDialog(boolean registerKeepIntDialog) {
  227. this.registerKeepIntDialog = registerKeepIntDialog;
  228. }
  229. public Boolean getDocEnable() {
  230. return docEnable;
  231. }
  232. public void setDocEnable(Boolean docEnable) {
  233. this.docEnable = docEnable;
  234. }
  235. public int getGbDeviceOnline() {
  236. return gbDeviceOnline;
  237. }
  238. public void setGbDeviceOnline(int gbDeviceOnline) {
  239. this.gbDeviceOnline = gbDeviceOnline;
  240. }
  241. }