![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java
时间 流逝
此人很懒,什么都没有写
展开
-
idea2018导入多个javaweb项目-学习笔记
idea2018导入多个javaweb项目原创 2023-03-08 16:26:25 · 151 阅读 · 0 评论 -
idea初学笔记
idea2018简单使用配置原创 2023-03-06 10:08:22 · 437 阅读 · 0 评论 -
eclipse开发学习笔记
eclipse开发时常用操作原创 2023-02-19 01:01:59 · 365 阅读 · 0 评论 -
错误: 在类 XXX中找不到 main 方法, 请将 main 方法定义为: public static void main(String[]
错误: 在类 XXX中找不到 main 方法, 请将 main 方法定义为: public static void main(String[] args)否则 JavaFX 应用程序类必须扩展javafx.application.Application原创 2023-02-15 10:15:32 · 815 阅读 · 0 评论 -
jmeter Parameters参数批量添加
jmeter Parameters参数批量添加原创 2023-02-07 10:07:04 · 352 阅读 · 0 评论 -
eclipse的android开发环境简单搭建学习
一、android开发工具sdk安装 二、eclipse 辅助插件 adt安装 三、新建项目转载 2023-02-07 09:22:40 · 401 阅读 · 0 评论 -
hibernate.session.get()方法不能获取表中最新数据解决方式样例
session.refresh(a1);原创 2022-02-23 16:24:40 · 368 阅读 · 0 评论 -
java脚本生成hibernate实例文件
java生成hibernate实例文件(oracle,mysql,达梦)原创 2022-10-25 10:19:58 · 621 阅读 · 0 评论 -
java 实现excel样式设置(居中、字体、大小、换行、合并行,列宽、指定特定字符串样式等)
HSSFWorkbook workbook = new HSSFWorkbook(); Sheet sheet = workbook.createSheet(); sheet.setColumnWidth(0, 30*256);//当前sheet页第一列宽度 sheet.setColumnWidth(1, 70*256);//第二列宽度 CellStyle style = workbook.createCellStyle(); Font font = workbook.createFont();原创 2021-12-02 22:20:51 · 19553 阅读 · 3 评论 -
java synchronized 对指定代码添加锁-简单样例
private final static Object syncLock = new Object(); // 相当于线程锁,用于线程安全 public static int n=0; public static void main(String[] args) { synchronized (syncLock){ n++; } } ...原创 2021-11-20 16:48:43 · 919 阅读 · 0 评论 -
java 接收上传的附件(文件)
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { PrintWriter out = null; try { out = response.getWriter(); out.println(" 上传成功 ")...原创 2021-11-19 16:01:57 · 2555 阅读 · 0 评论 -
java复制单个文件
/*org.apache.commons.io.FileUtils:java文件工具类*/ String targetPath="/xxx/targetfile.pdf";//已知文件全路径 String sourcePath=/xxx/sourcefile.pdf";//复制文件全路径 File f=new File(targetPath); try { if(!f.exists()) { f.createNewFile(...原创 2021-11-10 11:05:30 · 381 阅读 · 0 评论 -
java实时记录在线人数
1.配置过滤器 <listener> <listener-class>com.listener.SessionCount</listener-class > </listener> 2.登陆时记录 package com.insigma.common.listener; import java.util.HashMap; import java.util.HashSet; import java.util.Map.Entry; i...原创 2021-11-06 20:26:22 · 885 阅读 · 1 评论 -
java遍历文件夹并获取所有路径
/** * 获取路径下的所有文件/文件夹 * @param directoryPath 需要遍历的文件夹路径 * @return */ public static List<String> getAllFile(String directoryPath) { LinkedList list = new LinkedList(); if(directoryPath==null){ return...原创 2021-11-05 15:29:09 · 615 阅读 · 0 评论 -
Extjs tree树的生成
泄露超时时间必填,根据访问量和实际情况填写,防止数据源泄露。此处900是系统访问量小,访问量大可改小转载 2021-10-25 11:31:33 · 170 阅读 · 0 评论 -
java数组删除指定下标数据
/** * * @param arr1 * @param n * @return */ public static String[] deleteArray(String[] arr1,int n){ String[] arr2 =new String[arr1.length-1] ; int index=0; for (int i =0;i< arr1.length; i++) { ...原创 2021-10-26 21:02:57 · 3118 阅读 · 0 评论 -
java数组根据下标插入数据
/** * * @param arr1 源数组 * @param n 下标 0...n * @param value 值 * @return */ public static String[] insertArray(String[] arr1,int n, String value){ //复制一个长度+1的数组 String[] arr2 = Arrays.copyOf(arr1, a...转载 2021-10-26 20:48:56 · 928 阅读 · 0 评论 -
java 线程 Thread Runnable 实现样例
/** */ package util; /** * Thread多线程样例 */ public class ThreadTest implements Runnable{ public String params; public ThreadTest(String params) { this.params=params; } @Override public void run() { System.out.p...原创 2021-10-18 20:11:20 · 128 阅读 · 0 评论 -
遍历HttpServletRequest参数
public int test(HttpServletRequest request) { Enumeration paramNames = request.getParameterNames(); while (paramNames.hasMoreElements()) { String paramName = (String) paramNames.nextElement(); String[] paramValues = re...转载 2021-10-14 14:53:16 · 433 阅读 · 0 评论