Class DetectorConnectionFactory

    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

        org.eclipse.jetty.util.component.AbstractLifeCycle.AbstractLifeCycleListener, org.eclipse.jetty.util.component.AbstractLifeCycle.StopException
      • 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.Dumpable

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

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

      • Fields inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

        FAILED, STARTED, STARTING, STOPPED, STOPPING
      • Fields inherited from interface org.eclipse.jetty.util.component.Dumpable

        KEY
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      ConnectionFactory.Detecting.Detection detect​(java.nio.ByteBuffer buffer)
      Performs a detection using multiple ConnectionFactory.Detecting instances and returns the aggregated outcome.
      org.eclipse.jetty.io.Connection newConnection​(Connector connector, org.eclipse.jetty.io.EndPoint endPoint)
      Creates a new Connection with the given parameters
      protected void nextProtocol​(Connector connector, org.eclipse.jetty.io.EndPoint endPoint, java.nio.ByteBuffer buffer)
      Callback method called when detection was unsuccessful.
      protected static void upgradeToConnectionFactory​(ConnectionFactory connectionFactory, Connector connector, org.eclipse.jetty.io.EndPoint endPoint)
      Utility method that performs an upgrade to the specified connection factory, disposing of the given resources when needed.
      • Methods inherited from class org.eclipse.jetty.util.component.ContainerLifeCycle

        addBean, addBean, addEventListener, addManaged, contains, destroy, doStart, doStop, dump, dump, dump, dumpObjects, dumpStdErr, getBean, getBeans, getBeans, getContainedBeans, getContainedBeans, isAuto, isManaged, isUnmanaged, manage, removeBean, removeBeans, removeEventListener, setBeans, start, stop, unmanage, updateBean, updateBean, updateBeans, updateBeans
      • Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle

        getEventListeners, getState, getState, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, setEventListeners, start, stop
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface org.eclipse.jetty.util.component.Container

        getCachedBeans, getEventListeners
      • Methods inherited from interface org.eclipse.jetty.util.component.Dumpable

        dumpSelf
      • Methods inherited from interface org.eclipse.jetty.util.component.Dumpable.DumpableContainer

        isDumpable
    • Method Detail

      • upgradeToConnectionFactory

        protected static void upgradeToConnectionFactory​(ConnectionFactory connectionFactory,
                                                         Connector connector,
                                                         org.eclipse.jetty.io.EndPoint endPoint)
                                                  throws java.lang.IllegalStateException
        Utility method that performs an upgrade to the specified connection factory, disposing of the given resources when needed.
        Parameters:
        connectionFactory - the connection factory to upgrade to.
        connector - the connector.
        endPoint - the endpoint.
        Throws:
        java.lang.IllegalStateException
      • nextProtocol

        protected void nextProtocol​(Connector connector,
                                    org.eclipse.jetty.io.EndPoint endPoint,
                                    java.nio.ByteBuffer buffer)
                             throws java.lang.IllegalStateException

        Callback method called when detection was unsuccessful. This implementation upgrades to the protocol returned by AbstractConnectionFactory.findNextProtocol(Connector).

        Parameters:
        connector - the connector.
        endPoint - the endpoint.
        buffer - the buffer.
        Throws:
        java.lang.IllegalStateException
      • newConnection

        public org.eclipse.jetty.io.Connection newConnection​(Connector connector,
                                                             org.eclipse.jetty.io.EndPoint endPoint)
        Description copied from interface: ConnectionFactory

        Creates a new Connection with the given parameters

        Specified by:
        newConnection in interface ConnectionFactory
        Parameters:
        connector - The Connector creating this connection
        endPoint - the EndPoint associated with the connection
        Returns:
        a new Connection