CameraConfig.java 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. package com.lqkj.camera.config;
  2. import org.springframework.boot.context.properties.ConfigurationProperties;
  3. import org.springframework.stereotype.Component;
  4. /**
  5. * 流媒体推送服务配置
  6. */
  7. @Component
  8. @ConfigurationProperties(prefix = "camera-config")
  9. public class CameraConfig {
  10. private Integer maxOnline = 16; //视频最大并发路数
  11. private Integer keepalive = Integer.MAX_VALUE;// 保活时长(分钟)默认持续在线
  12. private String pushHost = "127.0.0.1";// 推送地址
  13. private String httpFlvHost = "";
  14. private Integer pushPort = 1935;// 推送端口
  15. private String mainCode = "1024";// 主码流最大码率
  16. private Boolean tcpConnectCheck = true; //是否启用tcp连通校验
  17. private String videoType = "flv"; //转流类型,flv或hls
  18. public String getHttpFlvHost() {
  19. return httpFlvHost;
  20. }
  21. public void setHttpFlvHost(String httpFlvHost) {
  22. this.httpFlvHost = httpFlvHost;
  23. }
  24. public Integer getMaxOnline() {
  25. return maxOnline;
  26. }
  27. public void setMaxOnline(Integer maxOnline) {
  28. this.maxOnline = maxOnline;
  29. }
  30. public Integer getKeepalive() {
  31. return keepalive;
  32. }
  33. public void setKeepalive(Integer keepalive) {
  34. this.keepalive = keepalive;
  35. }
  36. public String getPushHost() {
  37. return pushHost;
  38. }
  39. public void setPushHost(String pushHost) {
  40. this.pushHost = pushHost;
  41. }
  42. public Integer getPushPort() {
  43. return pushPort;
  44. }
  45. public void setPushPort(Integer pushPort) {
  46. this.pushPort = pushPort;
  47. }
  48. public String getMainCode() {
  49. return mainCode;
  50. }
  51. public void setMainCode(String mainCode) {
  52. this.mainCode = mainCode;
  53. }
  54. public String getVideoType() {
  55. return videoType;
  56. }
  57. public void setVideoType(String videoType) {
  58. this.videoType = videoType;
  59. }
  60. public Boolean getTcpConnectCheck() {
  61. return tcpConnectCheck;
  62. }
  63. public void setTcpConnectCheck(Boolean tcpConnectCheck) {
  64. this.tcpConnectCheck = tcpConnectCheck;
  65. }
  66. }