background picture of the home page

Hi,Friend

Core Audio API控制windows音量

该代码使用Core Audio API控制Windows音量。开发环境包括VS 2019和Windows 10企业版2016长期服务版。示例代码包含`test.h`、`test.cpp`、`SystemVolume.h`和`SystemVolume.cpp`四个文件。`SystemVolume.cpp`中包含初始化、设置音量、获取音量、关闭服务等方法,并使用`IAudioEndpointVolume`接口控制音量。代码通过`CoInitialize`、`CoCreateInstance`等COM组件接口函数,完成音量控制功能。

thumbnail of the cover of the post

Linux升级python

Linux升级python (编译安装) 当前环境 系统:Centos 7 x86_64 python版本:Python 2.7.5 (default, Nov 16 2020, 22:23:17) gcc版本: gcc version 11.2.0 (GCC) 安装步骤 1. 下载升级文件 py

thumbnail of the cover of the post

Java获取操作系统信息

该Java代码使用Maven依赖oshi-core和hutool-all库,获取操作系统信息,包括CPU型号、内存总量、可用内存、使用率、显卡信息以及网络上传/下载速度。代码通过oshi库获取硬件信息,hutool库提供IO和字符串工具类,计算CPU使用率和网络传输速度,并格式化输出结果。

thumbnail of the cover of the post

清除数据库内所有表的数据【MySQL】

该MySQL存储过程`delAllTableData`用于清除指定数据库中所有表的数据。它首先声明一个变量`table_size`,获取指定数据库中表的数量。然后循环遍历每个表,使用`truncate table`语句清空表数据。存储过程接受数据库名称作为参数,并使用`call`语句执行。

thumbnail of the cover of the post

项目升级java17遇到的问题与解决方案

本文介绍了将项目从Java 8升级到Java 17,Spring Boot升级到3.x,Spring Cloud升级到2022.0.0.0过程中遇到的问题及解决方案。 文章详细列出了需要进行的代码修改,包括使用正则表达式批量替换import语句和Swagger注解。 主要问题包括:spring.config.import属性未定义,Session符号无法解析,以及一些类库版本兼容性问题。 文中针对每个问题给出了相应的依赖包解决方案,例如添加`spring-cloud-starter-bootstrap`、`jakarta.websocket-client-api`以及`pagehelper-spring-boot-starter`等依赖。

thumbnail of the cover of the post

windows远程桌面无法复制文件

Windows远程桌面无法复制文件的问题,可以通过结束rdpclip.exe进程或重新运行rdpclip.exe来解决。若问题仍然存在,尝试关闭并重新打开远程桌面。

thumbnail of the cover of the post

@Scheduled定时不执行

Spring Boot下@Scheduled定时任务不执行可能由三个原因导致:1. 启动类未添加@EnableScheduling注解;2. 定时任务类未被Spring扫描到,需要添加@Component或@Service注解;3. 定时任务位于Controller类中,应将其移动到Service层或单独的组件类中。 解决方法分别为:在启动类添加@EnableScheduling注解,在定时任务类添加@Component或@Service注解,以及将定时任务移至Service层或独立的Service类并添加@Component注解。

thumbnail of the cover of the post

geos编译安装

geos编译安装 当前环境 系统: Linux localhost.localdomain 4.19.90-89.11.v2401.ky10.aarch64 #1 SMP Thu Apr 25 18:20:10 CST 2024 aarch64 aarch64 aarch64 GNU/Linux c

thumbnail of the cover of the post

cmake 编译安装

本文介绍了CMake 3.30.0 的编译安装步骤。首先,下载CMake源代码。然后卸载旧版本(如果存在)。接着,解压下载的源代码。下载依赖包(如gcc-c++)并运行bootstrap脚本。接下来,使用gmake编译,并使用gmake install进行安装。最后,使用cmake --version命令验证安装是否成功。

thumbnail of the cover of the post