大个蝈蝈吧 关注:3贴子:485
  • 7回复贴,共1


IP属地:陕西1楼2022-05-05 10:02回复
    /**
    * @Auther: Ke Youmi
    * @Date: ${DATE} - ${MONTH} - ${DAY} - ${TIME}
    * @Description: ${PACKAGE_NAME}
    * @version: 1.0
    */


    IP属地:陕西2楼2022-05-05 10:02
    回复
      passageService.list(Wrappers.lambdaQuery(Passage.class)
      .like(StringUtils.isNotBlank(name), Passage::getName, name)
      .eq(Objects.nonNull(mapId), Passage::getMapId, mapId)
      .orderByDesc(Passage::getCreateTime))


      IP属地:陕西3楼2022-05-09 10:54
      回复
        IP属地:陕西4楼2022-05-12 22:32
        回复
          package com.hzwq.ema.config;
          import java.util.concurrent.*;
          public class Executor {
          private static final LinkedBlockingQueue queue = new LinkedBlockingQueue<>(1024);
          private static final ThreadFactory threadFactory = new HZWQThreadFactory();
          private static final ExecutorService threadPoolExecutor=new ThreadPoolExecutor(Runtime.getRuntime().availableProcessors()-1,
          Runtime.getRuntime().availableProcessors()*2,
          5,
          TimeUnit.SECONDS,
          queue,
          threadFactory,
          new ThreadPoolExecutor.AbortPolicy());
          public static void submit(Runnable runnable) {
          threadPoolExecutor.submit(runnable);
          }
          public static <T> Future<T> submit(Runnable task, T result) {
          return threadPoolExecutor.submit(task, result);
          }
          public static <T> Future<T> submit(Callable<T> callable) {
          return threadPoolExecutor.submit(callable);
          }
          public static void shutdown() {
          threadPoolExecutor.shutdown();
          }
          public static class HZWQThreadFactory implements ThreadFactory {
          @Override
          public Thread newThread(Runnable r) {
          Thread thread = new Thread(r);
          // thread.setName("HZWQ-THREAD");
          thread.setPriority(Thread.MAX_PRIORITY);
          return thread;
          }
          }
          }


          IP属地:陕西6楼2023-03-06 11:15
          收起回复
            // 读取PDF文件内容
            PDDocument document = PDDocument.load(new File("空气质量指数 AQ 标准.pdf"));
            PDFTextStripper pdfStripper = new PDFTextStripper();
            String pdfText = pdfStripper.getText(document);
            document.close();
            // 根据污染物类型和浓度计算AQ浓度
            public double calculateAQConcentration(String pollutantType, double concentration) {
            // 根据具体的计算规则进行计算
            // 这里假设有一个简单的计算规则
            if ("s021h".equals(pollutantType)) {
            return concentration * 1.5;
            } else if ("NO2_24h".equals(pollutantType)) {
            return concentration * 2.0;
            } else {
            return 0.0;
            }
            }
            // 编写Spring Boot接口
            @RestController
            public class AQController {
            @GetMapping("/calculateAQConcentration")
            public double calculateAQConcentration(@RequestParam String pollutantType, @RequestParam double concentration) {
            return calculateAQConcentration(pollutantType, concentration);
            }
            }


            IP属地:陕西来自Android客户端7楼2024-03-11 14:51
            回复
              https://blog.csdn.net/weixin_58724261/article/details/134585369 方法注释模板


              IP属地:陕西8楼2024-07-12 12:16
              回复


                **
                * @Description: $description$
                * @Param: $params$
                * @Author: xxxxx
                * @Date: $date$~$time$
                * @Return $return$
                */


                IP属地:陕西9楼2024-07-12 12:37
                回复