![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java 功能代码块
亦心天闲
这个作者很懒,什么都没留下…
展开
-
正则表达式截取字符串内容
正则表达式截取字符串内容Pattern pattern = Pattern.compile("(\\{)(.+?)(\\})"); String test = "callback( {\"client_id\":\"222222\",\"openid\":\"122121\",\"unionid\":\"ddddddddd\"} );"; Matcher ma...原创 2019-11-19 16:25:05 · 1137 阅读 · 0 评论 -
腾讯云存储 cos
package com.jc.chile.booksgrab.utils;import com.qcloud.cos.exception.CosClientException;import com.qcloud.cos.exception.CosServiceException;import com.qcloud.cos.model.*;import com.qcloud.cos.CO...原创 2019-11-05 11:46:31 · 1110 阅读 · 0 评论 -
HttpURLConnection 网络请求 get post
//get请求public static String sendGet(String url, String param) throws Exception{ StringBuffer result = new StringBuffer(); BufferedReader br = null; try { if(p原创 2017-12-14 10:54:18 · 292 阅读 · 0 评论 -
java提取 url 的域名
String str = "https://www.xxxx.com:8080/images/1.jpg";java.net.URL url = new java.net.URL(str);String host = url.getHost();//获取主机名System.out.println(url.getPort());//端口号,若是没有端口号返回 -1System.out...原创 2019-02-21 17:00:12 · 1337 阅读 · 0 评论 -
java 合并两张图片
import java.awt.Graphics;import java.awt.Graphics2D;import java.awt.image.BufferedImage;import java.io.File;import java.net.URL;import javax.imageio.ImageIO;public class Test { publ...原创 2019-06-12 14:17:09 · 1346 阅读 · 0 评论 -
idea maven项目依赖领一个maven项目
1.发布到远程仓库pom.xml配置远程仓库2.发布到远程仓库(IDEA)3.在pom.xml中添加依赖原创 2019-06-21 15:45:58 · 135 阅读 · 0 评论 -
图片合并
import javax.imageio.ImageIO;import javax.imageio.stream.ImageOutputStream;import java.awt.*;import java.awt.image.BufferedImage;import java.io.ByteArrayInputStream;import java.io.ByteArrayOutpu...原创 2019-08-01 15:58:09 · 897 阅读 · 0 评论 -
非空验证工具类
//验证为空 public static <T> boolean isEmpty(T obj){ return !isNotEmpty(obj); } //验证非空 public static <T> boolean isNotEmpty(T obj){ if(obj != null){ if(obj instance...原创 2019-09-12 11:38:57 · 378 阅读 · 0 评论