Class GracefulShutdownRequestImpl

java.lang.Object
org.apache.directory.api.ldap.model.message.AbstractMessage
org.apache.directory.api.ldap.model.message.AbstractRequest
org.apache.directory.api.ldap.model.message.AbstractExtendedRequest
org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest
org.apache.directory.api.ldap.extras.extended.gracefulShutdown.GracefulShutdownRequestImpl
All Implemented Interfaces:
GracefulShutdownRequest, org.apache.directory.api.ldap.model.message.ExtendedRequest, org.apache.directory.api.ldap.model.message.Message, org.apache.directory.api.ldap.model.message.Request, org.apache.directory.api.ldap.model.message.ResultResponseRequest, org.apache.directory.api.ldap.model.message.SingleReplyRequest

public class GracefulShutdownRequestImpl extends org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest implements GracefulShutdownRequest
An extended operation requesting the server to shutdown it's LDAP service port while allowing established clients to complete or abandon operations already in progress. More information about this extended request is available here: LDAP Extensions for Graceful Shutdown.
Author:
Apache Directory Project
  • Field Summary

    Fields inherited from class org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest

    response

    Fields inherited from class org.apache.directory.api.ldap.model.message.AbstractExtendedRequest

    oid

    Fields inherited from class org.apache.directory.api.ldap.model.message.AbstractMessage

    controls

    Fields inherited from interface GracefulShutdownRequest

    EXTENSION_OID, NOW, UNDETERMINED
  • Constructor Summary

    Constructors
    Constructor
    Description
    Instantiates a new graceful shutdown request.
    Instantiates a new graceful shutdown request.
    GracefulShutdownRequestImpl(int messageId, int timeOffline, int delay)
    Instantiates a new graceful shutdown request.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Gets the delay before disconnection, in seconds.
    int
    Gets the offline time after disconnection, in minutes.
    void
    setDelay(int delay)
    Sets the delay before disconnection, in seconds.
    void
    setTimeOffline(int timeOffline)
    Sets the time offline after disconnection, in minutes.

    Methods inherited from class org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest

    addAllControls, addControl, equals, getExtendedResponse, getRequestName, getRequestValue, getResponseType, hashCode, removeControl, setMessageId, setRequestName, setRequestValue, toString

    Methods inherited from class org.apache.directory.api.ldap.model.message.AbstractExtendedRequest

    getResponse, setResponse

    Methods inherited from class org.apache.directory.api.ldap.model.message.AbstractRequest

    hasResponse

    Methods inherited from class org.apache.directory.api.ldap.model.message.AbstractMessage

    get, getControl, getControls, getMessageId, getType, hasControl, put, toString

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.apache.directory.api.ldap.model.message.ExtendedRequest

    addAllControls, addControl, getRequestName, removeControl, setMessageId, setRequestName

    Methods inherited from interface org.apache.directory.api.ldap.model.message.Message

    get, getControl, getControls, getMessageId, getType, hasControl, put

    Methods inherited from interface org.apache.directory.api.ldap.model.message.Request

    hasResponse

    Methods inherited from interface org.apache.directory.api.ldap.model.message.SingleReplyRequest

    getResponseType
  • Constructor Details

    • GracefulShutdownRequestImpl

      public GracefulShutdownRequestImpl(int messageId)
      Instantiates a new graceful shutdown request.
      Parameters:
      messageId - the message id
    • GracefulShutdownRequestImpl

      public GracefulShutdownRequestImpl()
      Instantiates a new graceful shutdown request.
    • GracefulShutdownRequestImpl

      public GracefulShutdownRequestImpl(int messageId, int timeOffline, int delay)
      Instantiates a new graceful shutdown request.
      Parameters:
      messageId - the message id
      timeOffline - the offline time after disconnection, in minutes
      delay - the delay before disconnection, in seconds
  • Method Details

    • getDelay

      public int getDelay()
      Gets the delay before disconnection, in seconds.
      Specified by:
      getDelay in interface GracefulShutdownRequest
      Returns:
      the delay before disconnection
    • setDelay

      public void setDelay(int delay)
      Sets the delay before disconnection, in seconds.
      Specified by:
      setDelay in interface GracefulShutdownRequest
      Parameters:
      delay - the new delay before disconnection
    • getTimeOffline

      public int getTimeOffline()
      Gets the offline time after disconnection, in minutes.
      Specified by:
      getTimeOffline in interface GracefulShutdownRequest
      Returns:
      the offline time after disconnection
    • setTimeOffline

      public void setTimeOffline(int timeOffline)
      Sets the time offline after disconnection, in minutes.
      Specified by:
      setTimeOffline in interface GracefulShutdownRequest
      Parameters:
      timeOffline - the new time offline after disconnection
    • getResultResponse

      public GracefulShutdownResponse getResultResponse()
      Specified by:
      getResultResponse in interface org.apache.directory.api.ldap.model.message.ResultResponseRequest
      Overrides:
      getResultResponse in class org.apache.directory.api.ldap.model.message.OpaqueExtendedRequest