随笔分类 - java后端笔记
摘要:安装文件目录:idea64.exe.vmoptions -Xms256m -Xmx1024m -XX:ReservedCodeCacheSize=240m -XX:+UseConcMarkSweepGC -XX:SoftRefLRUPolicyMSPerMB=50 项目启动配置:vim option
阅读全文
摘要:1、String.format("%.2f",(float) 2/3) 2、DecimalFormat decimalFormat = new DecimalFormat("#.00"); decimalFormat.format((double) 10/3);
阅读全文
摘要:public static boolean isBetween(LocalDateTime beginTime, LocalDateTime endTime) { LocalDateTime now = LocalDateTime.now(); boolean flag = false; if (n
阅读全文
摘要:org.springframework.context.ApplicationContextException: Unable to start web server; nested exception is org.springframe work.boot.web.server.WebServe
阅读全文
摘要:public static void http(String url,JSONObject object){ try{ CloseableHttpClient httpClient = HttpClientBuilder.create().build(); HttpPost httpPost = n
阅读全文
摘要:String str = "'0ec93d13eaae488db7f9f644cb4885c3','fsfds','sdfsdfsd'"; List<String> list = Arrays.asList(str.split(",")); list.forEach(s -> { System.ou
阅读全文
摘要:@GetMapping("app") public void app(HttpServletResponse response) throws IOException { ServletOutputStream out = null; ClassPathResource classPathResou
阅读全文
摘要:public static String getWeek(String date) throws ParseException { String[] weeks = {"1","2","3","4","5","6","7"}; Calendar cal = Calendar.getInstance(
阅读全文
摘要:public static List<Date> getDayListOfMonth() throws ParseException { List list = new ArrayList(); Calendar aCalendar = Calendar.getInstance(Locale.CHI
阅读全文
摘要:public static List<String> allRangeDate(String startDateStr, String endDateStr) { List<String> listDate = new ArrayList<>(); DateTimeFormatter df1 = D
阅读全文
摘要:Java时间格式转换大全 import java.text.*; import java.util.Calendar; public class VeDate { /** * 获取现在时间 * * @return 返回时间类型 yyyy-MM-dd HH:mm:ss */ public static
阅读全文
摘要:<dependency> <groupId>com.dp</groupId> <artifactId>dp-common</artifactId> <version>0.0.1-SNAPSHOT</version> </dependency>
阅读全文
摘要:public static String getIp() throws SocketException { Enumeration allNetInterfaces = NetworkInterface.getNetworkInterfaces(); InetAddress ip = null; S
阅读全文
摘要:ServletRequestAttributes attributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes(); HttpServletRequest request = attributes.
阅读全文
摘要:@Override public List<Map<String, Object>> findDicById(Map<String, Object> map) { List<Map<String, Object>> tree = new ArrayList<>(); map.put("pid","0
阅读全文
摘要:public static void main(String[] args) throws APIConnectionException, APIRequestException { pushNotice("","baojing","网页内容","网页标题"); } private static f
阅读全文
摘要:一、spring项目构建 使用idea创建项目 二、Sping IOC容器 1、简单实例 package entity; /** * @Author LLF * @Date Created in 2020/12/7 10:04 * @Description * @Version 1.0 **/ pu
阅读全文
摘要:查找命令:netstat -aon|findstr 端口号停止进程命令:taskkill /pid PID号 /f
阅读全文
摘要:将XML文件中的<mirrors>节点修改为(阿里云的仓库): <mirrors> <!-- 阿里云仓库 --> <mirror> <id>alimaven</id> <mirrorOf>central</mirrorOf> <name>aliyun maven</name> <url>http:/
阅读全文
摘要:请求: RestTemplate restTemplate = new RestTemplate(); LinkedMultiValueMap body=new LinkedMultiValueMap(); body.add("map",dataService.runData()); HttpHea
阅读全文

浙公网安备 33010602011771号