Interface Connector

All Superinterfaces:
org.eclipse.jetty.util.component.Container, org.eclipse.jetty.util.component.Graceful, org.eclipse.jetty.util.component.LifeCycle
All Known Subinterfaces:
NetworkConnector
All Known Implementing Classes:
AbstractConnector, AbstractNetworkConnector, LocalConnector, MemoryConnector, NetworkTrafficServerConnector, ServerConnector

@ManagedObject("Connector Interface") public interface Connector extends org.eclipse.jetty.util.component.LifeCycle, org.eclipse.jetty.util.component.Container, org.eclipse.jetty.util.component.Graceful

A Connector accept connections and data from remote peers, and allows applications to send data to remote peers, by setting up the machinery needed to handle such tasks.

  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.Container

    org.eclipse.jetty.util.component.Container.InheritedListener, org.eclipse.jetty.util.component.Container.Listener

    Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.Graceful

    org.eclipse.jetty.util.component.Graceful.Shutdown, org.eclipse.jetty.util.component.Graceful.ThrowingRunnable

    Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle

    org.eclipse.jetty.util.component.LifeCycle.Listener
  • Method Summary

    Modifier and Type
    Method
    Description
    org.eclipse.jetty.io.ByteBufferPool
    Get the ByteBufferPool to acquire buffers from and release buffers to.
    Collection<org.eclipse.jetty.io.EndPoint>
     
     
    <T> T
    getConnectionFactory(Class<T> factoryType)
     
     
    Get the default ConnectionFactory associated with the default protocol name.
    Get the Executor used to submit tasks.
    long
     
    Get the connector name if set.
     
    org.eclipse.jetty.util.thread.Scheduler
    Get the Scheduler used to schedule tasks.
    Get the Server instance associated with this Connector.
    Get the underlying socket, channel, buffer etc. for the connector..

    Methods inherited from interface org.eclipse.jetty.util.component.Container

    addBean, addBean, addEventListener, getBean, getBeans, getBeans, getCachedBeans, getContainedBeans, getEventListeners, isManaged, manage, removeBean, removeEventListener, unmanage

    Methods inherited from interface org.eclipse.jetty.util.component.Graceful

    isShutdown, shutdown

    Methods inherited from interface org.eclipse.jetty.util.component.LifeCycle

    addEventListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeEventListener, start, stop
  • Method Details

    • getServer

      Server getServer()
      Get the Server instance associated with this Connector.
      Returns:
      the Server instance associated with this Connector
    • getExecutor

      Executor getExecutor()
      Get the Executor used to submit tasks.
      Returns:
      the Executor used to submit tasks
    • getScheduler

      org.eclipse.jetty.util.thread.Scheduler getScheduler()
      Get the Scheduler used to schedule tasks.
      Returns:
      the Scheduler used to schedule tasks
    • getByteBufferPool

      org.eclipse.jetty.io.ByteBufferPool getByteBufferPool()
      Get the ByteBufferPool to acquire buffers from and release buffers to.
      Returns:
      the ByteBufferPool to acquire buffers from and release buffers to
    • getConnectionFactory

      ConnectionFactory getConnectionFactory(String nextProtocol)
      Parameters:
      nextProtocol - the next protocol
      Returns:
      the ConnectionFactory associated with the protocol name
    • getConnectionFactory

      <T> T getConnectionFactory(Class<T> factoryType)
    • getDefaultConnectionFactory

      ConnectionFactory getDefaultConnectionFactory()
      Get the default ConnectionFactory associated with the default protocol name.
      Returns:
      the default ConnectionFactory associated with the default protocol name
    • getConnectionFactories

      Collection<ConnectionFactory> getConnectionFactories()
    • getProtocols

      List<String> getProtocols()
    • getIdleTimeout

      @ManagedAttribute("maximum time a connection can be idle before being closed (in ms)") long getIdleTimeout()
      Returns:
      the max idle timeout for connections in milliseconds
    • getTransport

      Object getTransport()
      Get the underlying socket, channel, buffer etc. for the connector..
      Returns:
      the underlying socket, channel, buffer etc. for the connector.
    • getConnectedEndPoints

      Collection<org.eclipse.jetty.io.EndPoint> getConnectedEndPoints()
      Returns:
      immutable collection of connected endpoints
    • getName

      String getName()
      Get the connector name if set.

      A ContextHandler may be configured with virtual hosts in the form "@connectorName" and will only serve requests from the named connector.

      Returns:
      The connector name or null.