`
mqiqe
  • 浏览: 22459 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论
文章列表
 AspectJ使用org.aspectj.lang.JoinPoint接口表示目标类连接点对象 如果是环绕增强时,使用org.aspectj.lang.ProceedingJoinPoint表示连接点对象,该类是JoinPoint的子接口。 任何一个增强方法都可以通过将第一个入参声明为JoinPoint访问到连接点上下文的信息。我们先来了解一下这两个接口的主要方法: 1)JoinPoint  java.lang.Object[] getArgs():获取连接点方法运行时的入参列表;  Signature getSignature() :获取连接点的方法签名对象;  java.lang ...
一个简单的 aop demo     spring 配置   xmlns:aop="http://www.springframework.org/schema/aop" xmlns:context="http://www.springframework.org/schema/context" http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.1.xsd         ...
Spring aop execution 表达式 Spring AOP 用户可能会经常使用 execution pointcut designator。执行表达式的格式如下: execution(modifiers-pattern? ret-type-pattern declaring-type-pattern? name-pattern(param-pattern) throws-pattern?) 除了返回类型模式(上面代码片断中的ret-type-pattern),名字模式和参数模式以外,所有的部分都是可选的。 返回类型模式决定了方法的返回类型必须依次匹配一个连接点。 你会使 ...

cache 小demo

package com.cache;   import net.sf.ehcache.Cache; import net.sf.ehcache.CacheManager; import net.sf.ehcache.Element;   /**  * 7. * 第一步:生成CacheManager对象 8. * 第二步:生成Cache对象 9. *  * 第三步:向Cache对象里添加由key,value组成的键值对的Element元素 10. * @author mahaibo  *   */ public class TestCache {   public ...
<head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>横向手风琴</title> <style>.container{ width:700px; height:100px; margin:70px auto 10px auto;}.handle{ float:left; margin:1px; width:50px; height:90px; cursor:pointer; backgr ...

lucene 分页

/** * 获取指定范围内的文档(该方法只打印文档内容,代表取得相应的文档)。 * @param start 注意:从0开始计数 * @param howMany*/public void getResults(int

lucene 应用

lucene 应用 lucenedto 类 用于区分     增加索引: 储存文件   File indexFile = new File(indexDirPath + "/" + entity.getUrlType()); indexFile.mkdirs(); if (!indexFile.exists()) { try { indexFile.createNewFile(); } catch (IOException e) { e.printStackTrace(); return false; ...

对称加密demo

package com; import   javax.crypto.Cipher;    import   javax.crypto.KeyGenerator;      import   javax.crypto.SecretKey;        public class DES {   /** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub try{  KeyGenerator   kg   ...

spring Test

package com.test.springTest;   import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;   impo ...

Spring cache

ehcache.xml 配置 <?xml version="1.0" encoding="UTF-8"?> <ehcache xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="ehcache.xsd" updateCheck="true" monitoring="autodetect"> <!-- <d ...
Global site tag (gtag.js) - Google Analytics