`
文章列表
FileManager类, 续: //加载配置文件配置信息 private Properties loadProperties() { Properties prop = new Properties(); try { if (configFile != null) { FileInputStream in = new FileInputStream(configFile); prop.load(in); } else { configFil ...
FileManager类: /* * Class: FileManager * Description: 加载并启动文件监听,并对外开放接口访问 * Version: 1.0 * Author: Carson.Huang * Created on Dec 1, 2010 */ public class FileManager { //注册的监听文件列表 private static HashMap<String, FileListener> FMap = new HashMap<String, FileListener>(); ...
支持的xml格式: 介绍: 1.总体利用一个FileListener.properties文件来初始化加载文件 格式: #需要监听多少个文件 ListenerFileNum = 5 #多少秒验证是否修改(重新加载文件) Interval = 5000 #被监听的文件 ListenerFile1 = /var/mqsi/config/log4j.properties ListenerFile2 = /var/mqsi/config/esb.properties ListenerFile3 = /var/mqsi/config/Endpoint_URL.properties ...
1.首先通过一个按钮触发file的click事件! 2.File的click事件,选择一个文件确认之后触发本身的onchange事件,给input text文本框赋值。 JAVAScript: //浏览文件 function fileBrowse(){ //触发浏览事件 document.forms["fileForm"].upload.click(); } function setFilePath(){ $("#showFilePath").val(document.forms["fileForm"].up ...
获得window下的所有盘符: File[] files = File.listRoots(); for(File f : files){ System.out.println(f.getPath()); } //验证是否为Window操作系统 if(System.getProperties().getProperty("os.name").contains("Window")) { currentParentDir="C:"+System.getProperties().getP ...

dtree

var d=new dTree('d'); d.config.check = false; //設置複選框不顯示; d.config.useIcons = true; //設置顯示圖片; d.add(1000,-1,'WMBA MQ','','',''); d.add(1,1000,'队列管理器1','','','infoView'); d.add(101,1,'代理1','url','tips','infoView'); d.add(102,1,' ...

加密解密类之二

    博客分类:
  • java
/** * 3DES 解密(byte[]). */ private static byte[] desDecrypt(SecretKey key, byte[] crypt){ try { Cipher cipher = Cipher.getInstance("DESede"); cipher.init(Cipher.DECRYPT_MODE, key); return cipher.doFinal(crypt); } catch (Exception e) { e.printStackTra ...

加密解密类之一

    博客分类:
  • java
/** * 加密; */ public static String encrypt(String value){ String key = getLimStr("ABCDEHIJKLMNOPQRSTUVWSVZ123456789",24); String encryptString = null; if(value!=null){ encryptString =  desEncrypt(key, value); } return encryptString; } /** * 解密; */ ...
$(function(){ //超出长度 用“...”代替 $("#high_light tr td").each(function(i){ if($(this).text().length>25){ $(this).attr("title",$(this).text()); var text=$(this).text().substring(0,22)+"..."; $(this).text(text); } }); }); 其中high_light代表要实现掩 ...

jquery进度条

提示:这个进度条没有与后台同步,所以没有真正的进度条效果,只是一个禁用页面、无限进度效果。 前提要导入jquery1.3以上的版本哦! 导入进度条脚本:jquery.processing.plugin.js 在脚本里面添加一句: $(document).progressDialog.showDialog("正在请求,请等待..."); 解除进度条添加一句: $(document).progressDialog.hideDialog();

table边框样式

    博客分类:
  • html
以前不懂给table加细边框,无意中看到有人设计的网页有这种样式: <html> <head> <title>XXX</title> <style> .table_border{ border: solid 1px green; border-collapse: collapse; overflow:auto; overFlow-x: scroll ; border-style: solid ; } .table_border tr th{ ...
调用代码: StringBuffer menus=new StringBuffer(); List<EsbAdminMenuInfo> list=menuServiceImpl.getAll(); buildChildMenu(list,0L,menus); return menus.toString(); 递归代码: /** * 递归生成菜单结构 * @param list 所有的菜单集合 * @param parentNoteId 菜单父节点 * @param menus 追加节点 * */ public void buil ...
<s:date name="#vo.lastLoginTime" format="dd/MM/yyyy HH:mm:ss" ></s:date>

TimeTask的使用

    博客分类:
  • java
TimerTask是指定一个时间自动调用它的run方法! 1.新建一个类,继承:public class FileListener extends TimerTask 2.重写它的run方法:public void run(){} 3.实例化及每隔t(以秒为单位)时间 调用run方法! Timer timer = new Timer(); timer.schedule(new FileListener(), new Date(), t); 4.它位于util包中!
今天老大整理svn上的项目,删除了一个.mymetadata文件,导致把项目部署到tomcat部署时无法点击finish, 这是导入项目重新生成的.mymetadata文件 <?xml version="1.0" encoding="UTF-8"?> <project-module type="WEB" name="wmba" id="myeclipse.1313136539892" j2ee-spec="1.4" arc ...
Global site tag (gtag.js) - Google Analytics