Class ServerFCGIConnection

All Implemented Interfaces:
Closeable, AutoCloseable, Connection, ConnectionMetaData, Attributes, Invocable

public class ServerFCGIConnection extends AbstractMetaDataConnection implements ConnectionMetaData
  • Constructor Details

  • Method Details

    • getBeginNanoTime

      public long getBeginNanoTime()
    • isUseInputDirectByteBuffers

      public boolean isUseInputDirectByteBuffers()
    • setUseInputDirectByteBuffers

      public void setUseInputDirectByteBuffers(boolean useInputDirectByteBuffers)
    • isUseOutputDirectByteBuffers

      public boolean isUseOutputDirectByteBuffers()
    • setUseOutputDirectByteBuffers

      public void setUseOutputDirectByteBuffers(boolean useOutputDirectByteBuffers)
    • getId

      public String getId()
      Specified by:
      getId in interface ConnectionMetaData
      Returns:
      a unique (within the lifetime of the JVM) identifier string for the network connection to the JVM
    • getHttpVersion

      public HttpVersion getHttpVersion()
      Specified by:
      getHttpVersion in interface ConnectionMetaData
    • getProtocol

      public String getProtocol()
      Specified by:
      getProtocol in interface ConnectionMetaData
    • isPersistent

      public boolean isPersistent()
      Specified by:
      isPersistent in interface ConnectionMetaData
    • isSecure

      public boolean isSecure()
      Specified by:
      isSecure in interface ConnectionMetaData
    • removeAttribute

      public Object removeAttribute(String name)
      Description copied from interface: Attributes
      Remove an attribute
      Specified by:
      removeAttribute in interface Attributes
      Parameters:
      name - the attribute to remove
      Returns:
      the value of the attribute if removed, else null
    • setAttribute

      public Object setAttribute(String name, Object attribute)
      Description copied from interface: Attributes
      Set an attribute
      Specified by:
      setAttribute in interface Attributes
      Parameters:
      name - the attribute to set
      attribute - the value to set. A null value is equivalent to removing the attribute.
      Returns:
      the previous value of the attribute if set, else null
    • getAttribute

      public Object getAttribute(String name)
      Description copied from interface: Attributes
      Get an attribute
      Specified by:
      getAttribute in interface Attributes
      Parameters:
      name - the attribute to get
      Returns:
      the value of the attribute, or null if no such attribute exists
    • getAttributeNameSet

      public Set<String> getAttributeNameSet()
      Description copied from interface: Attributes
      Get the immutable set of attribute names.
      Specified by:
      getAttributeNameSet in interface Attributes
      Returns:
      Set of attribute names, or an empty set if there are no attributes.
    • clearAttributes

      public void clearAttributes()
      Description copied from interface: Attributes
      Clear all attribute names
      Specified by:
      clearAttributes in interface Attributes
    • onOpen

      public void onOpen()
      Description copied from interface: Connection

      Callback method invoked when this connection is opened.

      Creators of the connection implementation are responsible for calling this method.

      Specified by:
      onOpen in interface Connection
      Overrides:
      onOpen in class AbstractConnection
    • onFillable

      public void onFillable()
      Description copied from class: AbstractConnection

      Callback method invoked when the endpoint is ready to be read.

      Specified by:
      onFillable in class AbstractConnection
      See Also:
    • onReadTimeout

      protected boolean onReadTimeout(TimeoutException timeout)
      Description copied from class: AbstractConnection

      Callback method invoked when the endpoint failed to be ready to be read after a timeout

      Overrides:
      onReadTimeout in class AbstractConnection
      Parameters:
      timeout - the cause of the read timeout
      Returns:
      true to signal that the endpoint must be closed, false to keep the endpoint open
    • onIdleExpired

      public boolean onIdleExpired(TimeoutException timeoutException)
      Description copied from interface: Connection

      Callback method invoked upon an idle timeout event.

      Implementations of this method may return true to indicate that the idle timeout handling should proceed normally, typically failing the EndPoint and causing it to be closed.

      When false is returned, the handling of the idle timeout event is halted immediately and the EndPoint left in the state it was before the idle timeout event.

      Specified by:
      onIdleExpired in interface Connection
      Overrides:
      onIdleExpired in class AbstractConnection
      Returns:
      true to let the EndPoint handle the idle timeout, false to tell the EndPoint to halt the handling of the idle timeout.
    • close

      public void close()
      Description copied from interface: Connection

      Performs a logical close of this connection.

      For simple connections, this may just mean to delegate the close to the associated EndPoint but, for example, SSL connections should write the SSL close message before closing the associated EndPoint.

      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Specified by:
      close in interface Connection
      Overrides:
      close in class AbstractConnection