• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
helong
博客园    首页    新随笔    联系   管理    订阅  订阅
2011年9月28日
linux基本操作命令
摘要: 以下命令都是以root身份输入的1.从图形界面进入问文本界面:init 32.从文本界面进入图形界面:startx3.从普通用户进入root用户:su4.进入文件夹:cd /文件路径5.返回上一个文件夹:cd ..6.查看当前位置的文件以及文件夹:ls7.查看当前位置所在的路径:pwd8.复制文件:cp 文件名 /新的文件夹的路径9.打开文件:cat 文件名10.删除文件: rm 文件名11.编辑文件:vi/vim 文件名 i 编辑文件 n 往下翻页浏览 ?字符(或文件名) 向上搜索字符(或文件名) /字符(或文件名) 向下搜索字符(或文件名) :输入命令 q 退出 q! 强制退出 ... 阅读全文
posted @ 2011-09-28 14:11 helong 阅读(293) 评论(0) 推荐(0)
使用struts2 拦截器实现判断是否登录功能
摘要: package com.iapppay.maintain.common;import java.util.Map;import org.jasypt.commons.CommonUtils;import com.opensymphony.xwork2.Action;import com.opensymphony.xwork2.ActionContext;import com.opensymphony.xwork2.ActionInvocation;import com.opensymphony.xwork2.interceptor.MethodFilterInterceptor;public 阅读全文
posted @ 2011-09-28 10:37 helong 阅读(444) 评论(0) 推荐(0)
使用过滤器检查用户是否登录及指定过滤URL
摘要: public class LoginFilter implements Filter { private ICacheClient memcache; public void setMemcache(ICacheClient memcache) { this.memcache = memcache; } private FilterConfig filterConfig; @Override public void destroy() { this.filterConfig=null; } ... 阅读全文
posted @ 2011-09-28 10:34 helong 阅读(517) 评论(0) 推荐(0)
在JAVA中使用正则表达式
摘要: String number="^\\+?[1-9][0-9]*$"; //非零的正整数Pattern pu = Pattern.compile(number);Matcher mu =pu.matcher("1");System.out.println("验证非零的正整数:"+mu.matches());得到的结果是:true 阅读全文
posted @ 2011-09-28 10:29 helong 阅读(351) 评论(0) 推荐(0)
在main方法中测试spring
摘要: Resource res = new ClassPathResource("applicationContext.xml"); BeanFactory factory = new XmlBeanFactory(res); /*不在applicationContext.xml配置PropertyPlaceholderConfigurer * Properties props = new Properties(); * * props.load(new FileInputStre... 阅读全文
posted @ 2011-09-28 10:26 helong 阅读(1150) 评论(0) 推荐(0)
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3