EndpointHolder (Apache Tomcat 10.1.57 API Documentation)
Description: declaration: package: org.apache.tomcat.websocket, class: EndpointHolder

# Class EndpointHolder

java.lang.Object
org.apache.tomcat.websocket.EndpointHolder

All Implemented Interfaces:
  `ClientEndpointHolder`

public class EndpointHolder extends Object implements ClientEndpointHolder
Holds a reference to a WebSocket endpoint instance.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `EndpointHolder(Endpoint endpoint)`
  Creates a new holder for the specified endpoint instance.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getClassName()`
  Returns the fully qualified class name of the endpoint.
  `Endpoint`
  `getInstance(InstanceManager instanceManager)`
  Returns an instance of the endpoint using the given instance manager.

  ### Methods inherited from class Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### EndpointHolder

    public EndpointHolder(Endpoint endpoint)
    Creates a new holder for the specified endpoint instance.
    Parameters:
      `endpoint` - The endpoint instance to hold

- ## Method Details

  - ### getClassName

    public String getClassName()
    Description copied from interface: `ClientEndpointHolder`
    Returns the fully qualified class name of the endpoint.
    Specified by:
      `getClassName` in interface `ClientEndpointHolder`
    Returns:
      the class name

  - ### getInstance

    public Endpoint getInstance(InstanceManager instanceManager) throws DeploymentException
    Description copied from interface: `ClientEndpointHolder`
    Returns an instance of the endpoint using the given instance manager.
    Specified by:
      `getInstance` in interface `ClientEndpointHolder`
    Parameters:
      `instanceManager` - the instance manager to create the endpoint
    Returns:
      the endpoint instance
    Throws:
      `DeploymentException` - if the endpoint cannot be instantiated