org.apache.directory.server.factory
Class ServerAnnotationProcessor

java.lang.Object
  extended by org.apache.directory.server.factory.ServerAnnotationProcessor

public class ServerAnnotationProcessor
extends Object

Annotation processor for creating LDAP and Kerberos servers.

Author:
Apache Directory Project

Constructor Summary
ServerAnnotationProcessor()
           
 
Method Summary
static org.apache.directory.server.ldap.replication.consumer.ReplicationConsumer createConsumer()
          creates an LdapServer and starts before returning the instance, infering the configuration from the Stack trace
static org.apache.directory.server.ldap.LdapServer createLdapServer(org.junit.runner.Description description, org.apache.directory.server.core.api.DirectoryService directoryService)
          Create a new instance of LdapServer
static org.apache.directory.server.kerberos.kdc.KdcServer getKdcServer(org.junit.runner.Description description, org.apache.directory.server.core.api.DirectoryService directoryService, int startPort)
           
static org.apache.directory.server.kerberos.kdc.KdcServer getKdcServer(org.apache.directory.server.core.api.DirectoryService directoryService, int startPort)
           
static org.apache.directory.server.ldap.LdapServer getLdapServer(org.apache.directory.server.core.api.DirectoryService directoryService)
          Returns an LdapServer instance and starts it before returning the instance, infering the configuration from the Stack trace
static org.apache.directory.server.ldap.LdapServer instantiateLdapServer(CreateLdapServer createLdapServer, org.apache.directory.server.core.api.DirectoryService directoryService)
          Just gives an instance of LdapServer without starting it.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServerAnnotationProcessor

public ServerAnnotationProcessor()
Method Detail

instantiateLdapServer

public static org.apache.directory.server.ldap.LdapServer instantiateLdapServer(CreateLdapServer createLdapServer,
                                                                                org.apache.directory.server.core.api.DirectoryService directoryService)
Just gives an instance of LdapServer without starting it. For getting a running LdapServer instance see createLdapServer(CreateLdapServer, DirectoryService)

See Also:
createLdapServer(CreateLdapServer, DirectoryService)

getLdapServer

public static org.apache.directory.server.ldap.LdapServer getLdapServer(org.apache.directory.server.core.api.DirectoryService directoryService)
                                                                 throws ClassNotFoundException
Returns an LdapServer instance and starts it before returning the instance, infering the configuration from the Stack trace

Returns:
a running LdapServer instance
Throws:
ClassNotFoundException

createConsumer

public static org.apache.directory.server.ldap.replication.consumer.ReplicationConsumer createConsumer()
                                                                                                throws ClassNotFoundException
creates an LdapServer and starts before returning the instance, infering the configuration from the Stack trace

Returns:
a running LdapServer instance
Throws:
ClassNotFoundException

createLdapServer

public static org.apache.directory.server.ldap.LdapServer createLdapServer(org.junit.runner.Description description,
                                                                           org.apache.directory.server.core.api.DirectoryService directoryService)
                                                                    throws Exception
Create a new instance of LdapServer

Parameters:
description - A description for the created LdapServer
directoryService - The associated DirectoryService
startPort - The port used by the server
Returns:
An LdapServer instance
Throws:
Exception - If the server cannot be started

getKdcServer

public static org.apache.directory.server.kerberos.kdc.KdcServer getKdcServer(org.apache.directory.server.core.api.DirectoryService directoryService,
                                                                              int startPort)
                                                                       throws Exception
Throws:
Exception

getKdcServer

public static org.apache.directory.server.kerberos.kdc.KdcServer getKdcServer(org.junit.runner.Description description,
                                                                              org.apache.directory.server.core.api.DirectoryService directoryService,
                                                                              int startPort)
                                                                       throws Exception
Throws:
Exception


Copyright © 2003-2012 The Apache Software Foundation. All Rights Reserved.