Chinaunix首页 | 论坛 | 博客
  • 博客访问: 423363
  • 博文数量: 79
  • 博客积分: 2886
  • 博客等级: 少校
  • 技术积分: 968
  • 用 户 组: 普通用户
  • 注册时间: 2008-05-16 10:33
文章分类

全部博文(79)

文章存档

2013年(7)

2012年(17)

2011年(28)

2010年(25)

2009年(1)

2008年(1)

我的朋友

分类: Java

2010-01-14 10:10:33

1.基本配置:

 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                   
                    /spring-context-2.5.xsd
                    ">













      init-method="init"  destroy-method="destory">








 



 
    
 

 
 
 
 
   
    
       第一个
       第二个
       第三个
    

 

 
 
   
   
        第一个l
       第二个l
       第三个l
   

   
 

 
 
   
      value1
      value2
      value3
   

 

 
 
  
     
     
     
  

 


  
  
  
  

2.开启AOP:

 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                    
                    /spring-aop-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   ">




AOP的xml版本
 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                    
                    /spring-aop-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   ">



 
 
  
 
 
  
  
 
 

 

3.开启事务和注解:

 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xmlns:tx=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   
                    /spring-aop-2.5.xsd
                    /spring-tx-2.5.xsd
                   ">


                  
  
    
      
      
      
      
       
       
       
       
       
       
       
       
 
 
  
    
   
      
 
 
 
   
   
 

  
    
   


XML版本:


 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xmlns:tx=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   
                    /spring-aop-2.5.xsd
                    /spring-tx-2.5.xsd
                   ">


                  
  
    
      
      
      
      
       
       
       
       
       
       
       
       
 
 
  

   
      
 
 
 
  
   
 

 
 
     
 
      
     
     

   
 
     
     
       
     
         
     
 
 
  
 
4.SSH:

 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xmlns:tx=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   
                    /spring-aop-2.5.xsd
                    /spring-tx-2.5.xsd
                   ">


   
    
      
      
      
      
       
       
       
       
       
       
       
       
 
 
 
 

 
 
     
        com/persia/model/Person.hbm.xml
     

  

  
    
       
       
            
            
              
 
     
          hibernate.dialect=org.hibernate.dialect.MySQL5Dialect
          hibernate.hbm2ddl.auto=update
          hibernate.show_sql=false
          hibernate.format_sql=false
          hibernate.cache.use_second_level_cache=true
                hibernate.cache.use_query_cache=false
             hibernate.cache.provider_class=org.hibernate.cache.EhCacheProvider
     

     



    

 










5.SSH2:

 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xmlns:tx=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   
                    /spring-aop-2.5.xsd
                    /spring-tx-2.5.xsd
                   ">


   
    
      
      
      
      
       
       
       
       
       
       
       
       
 
 
 
 

 
 
     
        com/persia/model/Person.hbm.xml
     

  

  
    
       
       
            
            
              
 
     
          hibernate.dialect=org.hibernate.dialect.MySQL5Dialect
          hibernate.hbm2ddl.auto=update
          hibernate.show_sql=false
          hibernate.format_sql=false
          hibernate.cache.use_second_level_cache=true
                hibernate.cache.use_query_cache=false
             hibernate.cache.provider_class=org.hibernate.cache.EhCacheProvider
     

     



    

 





6.SSJ:

 xmlns=""
 xmlns:xsi=""
 xmlns:context=""
 xmlns:aop=""
 xmlns:tx=""
 xsi:schemaLocation="
                    /spring-beans-2.5.xsd
                   
                    /spring-context-2.5.xsd
                   
                    /spring-aop-2.5.xsd
                    /spring-tx-2.5.xsd
                   ">





     


   
    



 





阅读(802) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~