mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Jean-Noël Rouvignac
18.04.2016 d10da5e09878c255bd3b685fa87a04610db7d404
opendj-server-legacy/src/main/java/org/opends/server/api/plugin/DirectoryServerPlugin.java
@@ -26,6 +26,7 @@
import org.forgerock.opendj.config.server.ConfigException;
import org.forgerock.opendj.ldap.DN;
import org.opends.server.core.DeleteOperation;
import org.opends.server.core.ServerContext;
import org.opends.server.types.*;
import org.opends.server.types.operation.*;
@@ -58,7 +59,8 @@
  /** The plugin types for which this plugin is registered. */
  private Set<PluginType> pluginTypes;
  /** The server context. */
  private ServerContext serverContext;
  /**
   * Creates a new instance of this Directory Server plugin.  Every
@@ -71,7 +73,15 @@
  {
  }
  /**
   * Returns the server context.
   *
   * @return the server context.
   */
  protected ServerContext getServerContext()
  {
    return serverContext;
  }
  /**
   * Indicates whether the provided configuration is acceptable for
@@ -104,6 +114,8 @@
   * plugins regardless of type. This should only be called by the
   * core Directory Server code during the course of loading a plugin.
   *
   * @param serverContext
   *          The server context.
   * @param pluginDN
   *          The configuration entry name of this plugin.
   * @param pluginTypes
@@ -118,9 +130,10 @@
       mayInstantiate=false,
       mayExtend=false,
       mayInvoke=false)
  public final void initializeInternal(DN pluginDN,
  public final void initializeInternal(ServerContext serverContext, DN pluginDN,
      Set<PluginType> pluginTypes, boolean invokeForInternalOps)
  {
    this.serverContext = serverContext;
    this.pluginDN = pluginDN;
    this.pluginTypes = pluginTypes;
    this.invokeForInternalOps = invokeForInternalOps;