上一页 1 ··· 35 36 37 38 39 40 41 42 43 ··· 61 下一页
摘要: 如果线程执行N久还没结束,就想把它杀掉,把线程留给其它任务使用。 思路:主线程执行时,开一个子线程来监控它,看是否执行完成。如果没有执行完成就把它干了,执行完了就不管。 package com.vipsoft.Thread; public class ThreadMain { public stat 阅读全文
posted @ 2022-06-10 14:42 VipSoft 阅读(217) 评论(0) 推荐(0)
摘要: ThreadPoolExecutor 介绍 简写: package com.vipsoft.Thread; import java.util.concurrent.*; import java.util.concurrent.atomic.AtomicInteger; public class Th 阅读全文
posted @ 2022-06-09 09:40 VipSoft 阅读(251) 评论(0) 推荐(0)
摘要: 线程池能够带来3个好处: 降低资源消耗:通过重复利用已创建的线程降低线程创建和销毁造成的消耗;提高响应速度:当任务到达时,任务可以不需要等到线程创建就能立即执行;提高线程的可管理性:线程是稀缺资源,如果无限制地创建,不仅会消耗系统资源,还会降低系统的稳定性,使用线程池可以进行统一分配、调优和监控。 阅读全文
posted @ 2022-06-08 11:17 VipSoft 阅读(122) 评论(0) 推荐(0)
摘要: IIS 配置目录浏览 在目录下 Web.config 下添加一句: <directoryBrowse enabled="true"/> <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <staticC 阅读全文
posted @ 2022-06-07 14:59 VipSoft 阅读(522) 评论(2) 推荐(0)
摘要: 首先 LinkedBlockingQueue 是线程安全的阻塞队列,LinkedBlockingQueue实现的生产者和消费者模型 阻塞队列与我们平常接触的普通队列(LinkedList或ArrayList等)的最大不同点,在于阻塞队列支出阻塞添加和阻塞删除方法。 阻塞添加:所谓的阻塞添加是指当阻塞 阅读全文
posted @ 2022-06-07 10:34 VipSoft 阅读(488) 评论(0) 推荐(0)
摘要: https://www.jianshu.com/p/cc2281b1a6bc https://blog.csdn.net/tonywu1992/article/details/83419448 继承关系图 /** * 节点类,用于存储数据 */ static class Node<E> { E it 阅读全文
posted @ 2022-06-06 10:11 VipSoft 阅读(72) 评论(0) 推荐(0)
摘要: 将Excel中的汉字列,转换成拼音首字母,并保存 需要安装导入 pypinyin、openpyxl 库 # pip install pypinyin from pypinyin import lazy_pinyin, Style import openpyxl def py(str_data): " 阅读全文
posted @ 2022-06-02 09:20 VipSoft 阅读(565) 评论(0) 推荐(0)
摘要: 在DataGrid中实现Button Command绑定 Command="{Binding editCommand}" 会默认查找UserList中对象的属性,而你的UserList中对象应该不包括editCommand属性;可以尝试:Command="{Binding DataContext.e 阅读全文
posted @ 2022-06-01 14:15 VipSoft 阅读(276) 评论(0) 推荐(0)
摘要: 备份数据库文件时,发现MySQL备份生成的文件名为 【vipsoft_周三】,发现是系统的日期格式问题。需调整日期格式,生成 【vipsoft_20220601.sql】 mysqldump -uroot -p110 vipsoft > D:\DBBackup\MySQL\vipsoft%Date: 阅读全文
posted @ 2022-06-01 10:26 VipSoft 阅读(194) 评论(0) 推荐(0)
摘要: 服务端接口代码如下:参考代码有错误,不要直接使用 /** * 上传数据+实体信息 */ @RequestMapping("/upload") public String doctorAnalysis(HttpServletRequest request, @RequestParam(value = 阅读全文
posted @ 2022-05-31 17:01 VipSoft 阅读(1292) 评论(0) 推荐(0)
摘要: 为什么浏览器中有些文件点击后是预览,有些是下载:https://www.cnblogs.com/vipsoft/p/18267174 SpringBoot 接口输出文件流 & Vue 下载文件流,获取 Header 中的文件名 https://www.cnblogs.com/vipsoft/p/16 阅读全文
posted @ 2022-05-27 16:09 VipSoft 阅读(4463) 评论(0) 推荐(0)
摘要: 几种数据格式的表示方式1.普通的值(数字,字符串,布尔) expire: 60 # 方便测试,设成 60 秒 2.对象、Map (属性和值) (键值对) 不支持tab,使用空格 vipsoft: api-url: http://xxxx file-path: /temp 3.数组 (List、Set 阅读全文
posted @ 2022-05-24 12:11 VipSoft 阅读(2263) 评论(0) 推荐(0)
摘要: 1.如何判断线程池所有任务是否执行完毕 package com.vipsoft.web; import org.junit.jupiter.api.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.sp 阅读全文
posted @ 2022-05-11 10:27 VipSoft 阅读(197) 评论(0) 推荐(0)
摘要: 将目录下的N个日志文件读写到一个文件中。 @Test void verification() throws Exception { File f = new File("D:\\Logs"); String wPath = "D:\\\\Logs\\0.logsAll.log"; File wf = 阅读全文
posted @ 2022-05-10 11:14 VipSoft 阅读(338) 评论(0) 推荐(0)
摘要: 大文件推荐使用 UltraEdit 工具 Sublime Text 16进制显示(可以直接显示不同数据类型转换后的结果,不用在线工具,转二进制了) 安装 HexViewer 插件 1. Ctrl + Shift + P2. 选 install3. 输入: HexViewer 回车 安装成功后显示: 阅读全文
posted @ 2022-05-07 16:26 VipSoft 阅读(8255) 评论(0) 推荐(0)
摘要: 字节序: 指多字节数据在计算机内存中存储或者网络传输时各字节的存储顺序,有大端和小端两种方式 大端: 指高位字节存放在内存的低地址端,低位字节存放在内存的高地址端。 小端: 指低位字节放在内存的低地址端,高位字节放在内存的高地址端。 获取CPU使用的存储方式 import java.nio.Byte 阅读全文
posted @ 2022-05-07 11:17 VipSoft 阅读(530) 评论(0) 推荐(0)
摘要: C# CRC8 C# /// /// This enum is used to indicate what kind of checksum you will be calculating. /// public enum CRC8_POLY { CRC8 = 0xd5, CRC8_CCITT = 阅读全文
posted @ 2022-05-06 23:31 VipSoft 阅读(609) 评论(0) 推荐(0)
摘要: JAVA CRC32 /** * CRC-32 * * <table width="400px" border="1" cellpadding="0" cellspacing="0"> * <tr> * <th>名称</th> * <th>多项式</th> * <th>初始值</th> * <th> 阅读全文
posted @ 2022-05-06 23:12 VipSoft 阅读(341) 评论(0) 推荐(0)
摘要: JAVA CRC16 /** * CRC-16 * * <table width="400px" border="1" cellpadding="0" cellspacing="0"> * <tr> * <th>名称</th> * <th>多项式</th> * <th>初始值</th> * <th> 阅读全文
posted @ 2022-05-06 23:11 VipSoft 阅读(325) 评论(0) 推荐(0)
摘要: Java CRC8 /** * CRC-8 * * <table width="400px" border="1" cellpadding="0" cellspacing="0"> * <tr> * <th>名称</th> * <th>多项式</th> * <th>初始值</th> * <th>异或 阅读全文
posted @ 2022-05-06 23:09 VipSoft 阅读(511) 评论(0) 推荐(0)
上一页 1 ··· 35 36 37 38 39 40 41 42 43 ··· 61 下一页