Class StandaloneLdapApiService

java.lang.Object
org.apache.directory.api.ldap.codec.osgi.DefaultLdapCodecService
org.apache.directory.api.ldap.codec.standalone.StandaloneLdapApiService
All Implemented Interfaces:
org.apache.directory.api.ldap.codec.api.LdapApiService

public class StandaloneLdapApiService extends org.apache.directory.api.ldap.codec.osgi.DefaultLdapCodecService
The default LdapApiService implementation. It loads the Controls, ExtendedOperations and IntermediateResponses as defined in the following system parameters :
  • Controls :
    • apacheds.request.controls
    • apacheds.response.controls
    • default.controls
  • ExtendedOperations :
    • apacheds.extendedOperations
    • extra.extendedOperations
  • IntermediateResponses :
    • apacheds.intermediateResponses
Version:
$Rev$, $Date$
Author:
Apache Directory Project
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static enum 
    The control's type
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    The list of extended operations to load at startup
    static final String
    The list of Intermediate responses to load at startup
    static final String
    The list of request controls to load at startup
    static final String
    The list of response controls to load at startup

    Fields inherited from interface org.apache.directory.api.ldap.codec.api.LdapApiService

    DEFAULT_PROTOCOL_CODEC_FACTORY
  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates a new instance of StandaloneLdapCodecService.
    StandaloneLdapApiService(List<String> requestControls, List<String> responseControls, List<String> extendedOperations, List<String> intermediateResponses)
    Creates a new instance of StandaloneLdapApiService.
  • Method Summary

    Methods inherited from class org.apache.directory.api.ldap.codec.osgi.DefaultLdapCodecService

    fromJndi, fromJndi, fromJndiRequestControl, fromJndiResponseControl, getDnFactory, getExtendedRequestFactories, getExtendedResponseFactories, getIntermediateResponseFactories, getProtocolCodecFactory, getRequestControlFactories, getResponseControlFactories, isControlRegistered, isExtendedRequestRegistered, isExtendedResponseRegistered, isIntermediateResponseRegistered, registeredExtendedRequests, registeredExtendedResponses, registeredIntermediateResponses, registeredRequestControls, registeredResponseControls, registerExtendedRequest, registerExtendedResponse, registerIntermediateResponse, registerProtocolCodecFactory, registerRequestControl, registerResponseControl, setDnfactory, setExtendedRequestFactories, setExtendedResponseFactories, setIntermediateResponseFactories, setProtocolCodecFactory, setRequestControlFactories, setResponseControlFactories, toJndi, toJndi, toJndiControl, toString, unregisterExtendedRequest, unregisterExtendedResponse, unregisterIntermediateResponse, unregisterRequestControl, unregisterResponseControl

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

    • REQUEST_CONTROLS_LIST

      public static final String REQUEST_CONTROLS_LIST
      The list of request controls to load at startup
      See Also:
    • RESPONSE_CONTROLS_LIST

      public static final String RESPONSE_CONTROLS_LIST
      The list of response controls to load at startup
      See Also:
    • EXTENDED_OPERATIONS_LIST

      public static final String EXTENDED_OPERATIONS_LIST
      The list of extended operations to load at startup
      See Also:
    • INTERMEDIATE_RESPONSES_LIST

      public static final String INTERMEDIATE_RESPONSES_LIST
      The list of Intermediate responses to load at startup
      See Also:
  • Constructor Details

    • StandaloneLdapApiService

      public StandaloneLdapApiService() throws Exception
      Creates a new instance of StandaloneLdapCodecService.

      The following pom configuration is intended for use by unit test running tools like Maven's surefire:
        <properties>
          <codec.plugin.directory>${project.build.directory}/pluginDirectory</codec.plugin.directory>
        </properties>
      
        <build>
          <plugins>
            <plugin>
              <artifactId>maven-surefire-plugin</artifactId>
              <groupId>org.apache.maven.plugins</groupId>
              <configuration>
                <systemPropertyVariables>
                  <workingDirectory>${basedir}/target</workingDirectory>
                  <felix.cache.rootdir>
                    ${project.build.directory}
                  </felix.cache.rootdir>
                  <felix.cache.locking>
                    true
                  </felix.cache.locking>
                  <org.osgi.framework.storage.clean>
                    onFirstInit
                  </org.osgi.framework.storage.clean>
                  <org.osgi.framework.storage>
                    osgi-cache
                  </org.osgi.framework.storage>
                  <codec.plugin.directory>
                    ${codec.plugin.directory}
                  </codec.plugin.directory>
                </systemPropertyVariables>
              </configuration>
            </plugin>
      
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-dependency-plugin</artifactId>
              <executions>
                <execution>
                  <id>copy</id>
                  <phase>compile</phase>
                  <goals>
                    <goal>copy</goal>
                  </goals>
                  <configuration>
                    <artifactItems>
                      <artifactItem>
                        <groupId>${project.groupId}</groupId>
                        <artifactId>api-ldap-extras-codec</artifactId>
                        <version>${project.version}</version>
                        <outputDirectory>${codec.plugin.directory}</outputDirectory>
                      </artifactItem>
                    </artifactItems>
                  </configuration>
                </execution>
              </executions>
            </plugin>
          </plugins>
        </build>
      
      Throws:
      Exception - If we had an issue initializing the LDAP service
    • StandaloneLdapApiService

      public StandaloneLdapApiService(List<String> requestControls, List<String> responseControls, List<String> extendedOperations, List<String> intermediateResponses) throws Exception
      Creates a new instance of StandaloneLdapApiService.
      Parameters:
      requestControls - The list of request controls to store
      responseControls - The list of response controls to store
      extendedOperations - The list of extended operations to store
      intermediateResponses - The list of intermediate responsess to store
      Throws:
      Exception - If we had an issue with one of the two lists