ke
2024-05-13 659d3e60c6fe5e5bcd8c4cbb3dd8077e29f13a38
skjcmanager/skjcmanager-service/skjcmanager-sm/src/main/java/cn/gistack/sm/hk/util/GetCameraUtils.java
@@ -41,6 +41,15 @@
      // 秘钥appSecret
      ArtemisConfig.appSecret = HkConstant.AppSecret;
      if (type==3) {
         // 秘钥appKey
         ArtemisConfig.appKey = HkConstant.EventAppKey;
         // 秘钥appSecret
         ArtemisConfig.appSecret = HkConstant.EventAppSecret;
         // host
         ArtemisConfig.host = HkConstant.Event_NEW_HOST;
      }
      /**
       * STEP3:设置接口的URI地址
@@ -75,10 +84,17 @@
    * @param url 视频预览url
    * @param cameraIndexCode 监控点唯一标识
    * @param protocol
    * @param transmode
    * @param expand
    * @return
    */
   public static String GetCameraPreviewURL(Integer type,String url, String cameraIndexCode, String protocol,String expand,Integer streamType) {
   public static String GetCameraPreviewURL(Integer type,
                                  String url,
                                  String cameraIndexCode,
                                  String protocol,
                                  Integer transmode,
                                  String expand,
                                  Integer streamType) {
      /**
       * 组装请求参数
       */
@@ -86,7 +102,7 @@
      jsonBody.put("cameraIndexCode", cameraIndexCode);
      jsonBody.put("streamType",streamType);
      jsonBody.put("protocol", protocol);
      jsonBody.put("transmode", 1);
      jsonBody.put("transmode", transmode);
      if (null!= expand && !expand.equals("")) {
         jsonBody.put("expand", expand);
      }
@@ -295,7 +311,7 @@
       * 组装请求参数
       */
      JSONObject jsonBody = new JSONObject();
      jsonBody.put("eventTypes", Arrays.stream(eventVO.getEventTypes().split(",")).mapToInt(Integer::parseInt).toArray());
      jsonBody.put("eventTypes", Arrays.stream(eventVO.getEventTypes().split(",")).mapToLong(Long::parseLong).toArray());
      jsonBody.put("eventDest", eventVO.getEventDest());
      if (null!=eventVO.getSubType()){
         jsonBody.put("subType", eventVO.getSubType());
@@ -319,7 +335,7 @@
    * @return
    */
   public static String removeEventSubscriptionByEventTypes(EventVO eventVO, String url) {
      int[] eventTypes =  Arrays.stream(eventVO.getEventTypes().split(",")).mapToInt(Integer::parseInt).toArray();
      long[] eventTypes =  Arrays.stream(eventVO.getEventTypes().split(",")).mapToLong(Long::parseLong).toArray();
      /**
       * 组装请求参数
       */