org.springframework.web.socket.config.annotation

## Class WebMvcStompEndpointRegistry

- java.lang.Object
- - org.springframework.web.socket.config.annotation.WebMvcStompEndpointRegistry

- All Implemented Interfaces:
    StompEndpointRegistry

      public class WebMvcStompEndpointRegistry
      extends Object
      implements StompEndpointRegistry

  A registry for STOMP over WebSocket endpoints that maps the endpoints with a `SimpleUrlHandlerMapping` for use in Spring MVC.
  Since:
    4.0
  Author:
    Rossen Stoyanchev

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `WebMvcStompEndpointRegistry(WebSocketHandler webSocketHandler, WebSocketTransportRegistration transportRegistration, UserSessionRegistry userSessionRegistry, TaskScheduler defaultSockJsTaskScheduler)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `StompWebSocketEndpointRegistration` | `addEndpoint(String... paths)` Register a STOMP over WebSocket endpoint at the given mapping path.
    `AbstractHandlerMapping` | `getHandlerMapping()` Return a handler mapping with the mapped ViewControllers; or `null` in case of no registrations.
    `int` | `getOrder()`
    `void` | `setOrder(int order)` Set the order for the resulting `SimpleUrlHandlerMapping` relative to other handler mappings configured in Spring MVC.

    - ### Methods inherited from class java.lang.Object

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

- - ### Constructor Detail

    - #### WebMvcStompEndpointRegistry

          public WebMvcStompEndpointRegistry(WebSocketHandler webSocketHandler,
                                             WebSocketTransportRegistration transportRegistration,
                                             UserSessionRegistry userSessionRegistry,
                                             TaskScheduler defaultSockJsTaskScheduler)

  - ### Method Detail

    - #### addEndpoint

          public StompWebSocketEndpointRegistration addEndpoint(String... paths)

      Description copied from interface: `StompEndpointRegistry`
      Register a STOMP over WebSocket endpoint at the given mapping path.
      Specified by:
        `addEndpoint` in interface `StompEndpointRegistry`

    - #### setOrder

          public void setOrder(int order)

      Set the order for the resulting `SimpleUrlHandlerMapping` relative to other handler mappings configured in Spring MVC.

      The default value is 1.

    - #### getOrder

          public int getOrder()

    - #### getHandlerMapping

          public AbstractHandlerMapping getHandlerMapping()

      Return a handler mapping with the mapped ViewControllers; or `null` in case of no registrations.