Spring LDAP

http://static.springframework.org/spring-ldap/docs/1.2.0/reference/

xml 代码
  1. <?xml version="1.0" encoding="UTF-8"?>  
  2. <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">  
  3. <beans default-lazy-init="true">  
  4.     <bean id="ldapContextSource"  
  5.         class="org.springframework.ldap.core.support.LdapContextSource">  
  6.         <property name="url" value="${ldap.url}" />  
  7.         <property name="base" value="${ldap.base}" />  
  8.         <property name="userDn" value="${ldap.userDn}" />  
  9.         <property name="password" value="${ldap.password}" />  
  10.     </bean>  
  11.     <bean id="ldapTemplate"  
  12.         class="org.springframework.ldap.core.LdapTemplate">  
  13.         <constructor-arg ref="ldapContextSource" />  
  14.     </bean>  
  15. </beans>  

你可能感兴趣的:(spring,bean,xml)