
Java
rib-pet
致力于政府信息化,聚焦CIM,智慧城市解决方案以及研发实施工作;擅长国土行业,智慧规划,智慧自然资源等行业信息化。ArcGIS(GeoScene)Supermap,Cesium, UE5 游戏引擎CG领域等核心框架。底层 osg, tinyGlTF, cgal, gdal, meshlab, 微软simplegon等。
展开
-
错误:HandleServiceCommands: system error caught. error code=1072, message 断电之后,Redis启动不了
Redis启动不了的问题Redis 设置好密码,但是断电之后,不需要密码都可以访问redis。解决方案如下:D:\>cd D:\software\Redis-x64-3.2.100D:\software\Redis-x64-3.2.100>redis-server --service-install redis.windows.conf[15376] 18 May 14:45:52.995 # HandleServiceCommands: system error caught.原创 2021-05-18 21:27:58 · 3217 阅读 · 0 评论 -
oracle no listener issues ORA-12514: TNS: 监听程序当前无法识别连接描述符中请求的服务
LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0)) ) (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = DESKTOP-DVQ3QKG)(PORT = 1521)) ) ) )solu.原创 2021-05-12 14:26:22 · 142 阅读 · 0 评论 -
Java JTW implementation
1. pom.xml<?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/x.原创 2020-12-26 23:21:03 · 181 阅读 · 0 评论 -
ApiResult Class Generation
@Data@Builder(toBuilder = true)public class ApiResult { private boolean succ = false; private String code; private String msg; private Object data;}the usage: ApiResult.ApiResultBuilder builder = ApiResult.builder().succ(false.原创 2020-12-26 12:47:32 · 154 阅读 · 0 评论 -
Make IDEA recognize Lombok
Sometimes, we would not like to write get and set method in our bean class.package com.ribpet.demo.Model;import lombok.AllArgsConstructor;import lombok.Data;@Data@AllArgsConstructorpublic class ToDo { private int id; private String titl原创 2020-12-26 12:15:06 · 349 阅读 · 0 评论 -
Vue/Spring boot, implement the Folder uploading feature
We are about to support to upload a folder. in vue side, we just samply provide a folder icon as below:<input title="上传" class="upload-folder-input" multiple="" webkitdirectory="" accept="*/*" type="file" @change="getFiles原创 2020-12-25 10:02:43 · 135 阅读 · 2 评论 -
Spring boot Minio integration
1. PrerequisitionSometimes, when we need to manages all uploaded files in our server side. We have to consider that what we did is not needed for different OS. For example , what if you are going to use ftp server, it means that you had better provide ..原创 2020-12-25 09:48:23 · 318 阅读 · 0 评论 -
How to adjust the location of attachments in windows server in different driver
import org.apache.commons.lang.StringUtils;import org.springframework.beans.factory.annotation.Autowired;import org.springframework.beans.factory.annotation.Value;import org.springframework.boot.web.servlet.FilterRegistrationBean;import org.springfra..原创 2020-11-04 19:13:47 · 122 阅读 · 0 评论 -
Calculate elapsed time and return json object method
public void doTest() {// Main Loop double l; for (int i = 0; i < nWarmups; i++) { l = fibImpl1(50); } long then = System.currentTimeMillis(); for (int i = 0; i < nLoops; i++) { l = fibImpl1(50); } long no.原创 2020-11-01 19:29:39 · 90 阅读 · 0 评论 -
JAVA PDF文件下载
File file = new File(targetPdf); if (file.exists()) { OutputStream out = null; FileInputStream in = null; try { // 1.读取要下载的内容 in = new FileInputStream(fil..原创 2020-09-25 18:32:29 · 1781 阅读 · 0 评论 -
Object转Map 对象转散列表
public class IntrospectUtil { public static Map<String, Object> introspect(Object obj) throws Exception { Map<String, Object> result = new HashMap<String, Object>(); BeanInfo info = Introspector.getBeanInfo(obj.getCl.原创 2020-09-25 18:30:38 · 131 阅读 · 0 评论 -
mybatis oracle 循环 批量插入
<insert id="insertBatchList" parameterType="java.util.List" useGeneratedKeys="false"> insert into YTH_PROGRAMME_MODEL ( PROGRAMME_ID, SERIAL_NUM, UPLOAD_PROGRESS, UPLOAD_STATUS ) <f..原创 2020-09-21 16:55:09 · 690 阅读 · 0 评论 -
利用freemark打印pdf文件以及中文乱码的问题
1. 添加dependency在pom.xml文件中 <dependency> <groupId>org.freemarker</groupId> <artifactId>freemarker</artifactId> <version>2.3.28</version> </dependency> &l原创 2020-09-18 09:09:54 · 1326 阅读 · 0 评论 -
Spring boot 加载Json file并生成bean类, JSON 转Array
第一步在resouce 目录下面定义好json文件第二步,写好controller去组装apipackage com.guodi.audit;import com.alibaba.fastjson.JSON;import com.alibaba.fastjson.TypeReference;import com.guodi.audit.dto.AuditResultMaterial;import com.guodi.audit.dto.AuditSuggestion;import原创 2020-08-28 10:35:10 · 589 阅读 · 0 评论 -
Activiti Linux部署流程图出现乱码
问题描述:在linux的部署的tomcat运行流程图的时候,节点上会有乱码解决方案第一步,排查lunix服务器上面是否按照Activiti配置的字体,你可以参考如下命令去找:第二部,从windows上面拷贝对应的字体到linux中。1. 寻找自己安装jdk的路径。例如如下:workspace//jdk/jdk1.8.0_161/jre/lib/fonts.2.创建目录:fallbackmkdirfallback (并将字体拷贝到该fallback目录下)...原创 2020-09-02 11:50:40 · 677 阅读 · 0 评论 -
整形转Excel 表列名。
please refer tohttp://www.techiedelight.com/convert-given-number-corresponding-excel-column-name/#include <iostream>#include <string>using namespace std;// Function to convert...转载 2020-04-01 09:17:27 · 127 阅读 · 0 评论 -
validation email
public static boolean validate(String email) { email = email.trim(); Pattern pattern = compile("^([a-zA-Z0-9_\\-\\.]+)@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.)|(([a-zA-Z0-9\\-]+\...原创 2020-03-19 10:23:52 · 1371 阅读 · 0 评论 -
Freemarker issues html to pdf (page break)
Issues description:Blank page in first page Same image separate into 2 page Seems some image in margin were trimmedsolution:in your *.ftl file, pls add below source code:<p style="pa...原创 2020-03-10 21:43:16 · 207 阅读 · 0 评论 -
compress and decompress algorithm
POM.xml<!-- https://mvnrepository.com/artifact/net.lecousin.compression/gzip --><dependency> <groupId>net.lecousin.compression</groupId> <artifactId>gzip<...原创 2020-03-06 09:59:18 · 130 阅读 · 0 评论 -
Spring boot projects: how to build war package
the original artical is "https://stackoverflow.com/questions/45351672/maven-war-packaging-with-value-war-is-invalid-aggregator-projects-require"you need to add "dependency" in parent pom.xml file...原创 2019-09-17 11:22:05 · 108 阅读 · 0 评论 -
How to implement Android TTS via MS Java SDK package (android) - Speech to Text
Speech to Text package: package com.microsoft.cognitiveservices.speech;Add following line in your [build.gradle - app] implementation 'com.microsoft.cognitiveservices.speech:client-sdk:1.1.0' ...原创 2019-02-05 10:58:41 · 491 阅读 · 0 评论