Package speculoos.jndi

Examples of speculoos.jndi.JNDISource


    env.put("fr.norsys.mockldap.testsource", "canam-personnes-sample.ldif");
  }

  public void test01MapperCreation() throws NamingException, MapperException {
    /* create source */
    JNDISource src = new JNDISource();
    /* configure source */
    src.addParameters(env);
    /* add mapper */
    SearchMapperImpl smi = new SearchMapperImpl("search1");
    VariableString root = new VariableString("cn=${nom}");
    smi.setRoot(root);
    VariableString filter = new VariableString("email=${email}");
    smi.getInputChain().addMapper(new StringVariable("filter", filter));
    smi.setTypeHelper(new TypeHelper());
    src.add("search1", smi);
    /* start source */
    src.start(env);
    /* create mapper */
    SearchMapper sm = (SearchMapper) src.create("search1", new HashMap());
    /* ensure mapper is new */
    assertNotSame(sm, smi);
    /* close */
    src.release(sm);
    src.stop();
  }
 
View Full Code Here

TOP

Related Classes of speculoos.jndi.JNDISource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.