Class MockSpringServletService

java.lang.Object
com.vaadin.flow.server.VaadinService
com.vaadin.flow.server.VaadinServletService
com.vaadin.flow.spring.SpringVaadinServletService
com.vaadin.browserless.mocks.MockSpringServletService
All Implemented Interfaces:
Serializable

public class MockSpringServletService extends com.vaadin.flow.spring.SpringVaadinServletService
A mocking service that performs three very important tasks: The class is intentionally opened, to be extensible in user's library.

For internal use only. May be renamed or removed in a future release.

Since:
1.0
Author:
mavi
See Also:
  • Field Summary

    Fields inherited from class com.vaadin.flow.server.VaadinService

    ATMOSPHERE_MISSING_ERROR, INVALID_ATMOSPHERE_VERSION_WARNING
  • Constructor Summary

    Constructors
    Constructor
    Description
    MockSpringServletService(@NonNull MockSpringServlet servlet, @NonNull com.vaadin.flow.function.DeploymentConfiguration deploymentConfiguration, @NonNull org.springframework.context.ApplicationContext ctx, @NonNull com.vaadin.browserless.internal.UIFactory uiFactory)
    Creates the service.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected com.vaadin.flow.server.VaadinSession
    createVaadinSession(com.vaadin.flow.server.VaadinRequest request)
     
    getMainDivId(com.vaadin.flow.server.VaadinSession session, com.vaadin.flow.server.VaadinRequest request)
     
    protected boolean
     

    Methods inherited from class com.vaadin.flow.spring.SpringVaadinServletService

    createDefaultExecutor, getExecutor, getStaticResource, init, loadInstantiators

    Methods inherited from class com.vaadin.flow.server.VaadinServletService

    constructVaadinContext, createRequestHandlers, createSessionlessRequestHandlers, getContextRootRelativePath, getCurrentResponse, getCurrentServletRequest, getMimeType, getPwaRegistry, getResource, getResourceAsStream, getResourceInServletContext, getRouteRegistry, getServiceName, getServlet, requestCanCreateSession, resolveResource, setDefaultClassLoader

    Methods inherited from class com.vaadin.flow.server.VaadinService

    accessSession, addRpcInvocationListener, addServiceDestroyListener, addSessionDestroyListener, addSessionInitListener, addSessionLockListener, addUIInitListener, applySessionLockCheckStrategy, closeSession, createCriticalNotificationJSON, createCriticalNotificationJSON, createDefaultObjectMapper, createInstantiator, createSessionExpiredJSON, createUINotFoundJSON, createVaadinRequestInterceptors, destroy, ensureAccessQueuePurged, ensurePushAvailable, findUI, findVaadinSession, fireSessionDestroy, fireUIInitListeners, getBootstrapInitialPredicate, getBootstrapUrlPredicate, getClassLoader, getContext, getCsrfTokenAttributeName, getCurrent, getCurrentOrThrow, getCurrentRequest, getDependencyFilters, getDeploymentConfiguration, getEventBus, getExistingSession, getInstantiator, getRequestHandlers, getRouter, getSessionAttributeName, getSessionlessRequestHandlers, getSessionLock, getSystemMessages, getSystemMessagesProvider, getVaadinRequestInterceptors, handleRequest, handleSessionExpired, isCsrfTokenValid, isInitialized, isOtherSessionLocked, isResourceAvailable, isUIActive, loadSession, lockSession, modifyIndexHtmlResponse, readFromHttpSession, recordRequestFailure, reinitializeSession, removeFromHttpSession, removeSession, requestEnd, requestStart, runPendingAccessTasks, setBootstrapInitialPredicate, setBootstrapUrlPredicate, setClassLoader, setCurrent, setCurrentInstances, setSystemMessagesProvider, storeSession, unlockSession, verifyNoOtherSessionLocked, whenInitialized, writeStringResponse, writeToHttpSession, writeUncachedStringResponse

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • MockSpringServletService

      public MockSpringServletService(@NonNull MockSpringServlet servlet, @NonNull com.vaadin.flow.function.DeploymentConfiguration deploymentConfiguration, @NonNull org.springframework.context.ApplicationContext ctx, @NonNull com.vaadin.browserless.internal.UIFactory uiFactory)
      Creates the service.
      Parameters:
      servlet - the servlet the service belongs to
      deploymentConfiguration - the deployment configuration to use
      ctx - the Spring context the views are instantiated from
      uiFactory - creates the UI of the session that replaces a closed session
  • Method Details

    • isAtmosphereAvailable

      protected boolean isAtmosphereAvailable()
      Overrides:
      isAtmosphereAvailable in class com.vaadin.flow.server.VaadinService
    • getMainDivId

      public String getMainDivId(com.vaadin.flow.server.VaadinSession session, com.vaadin.flow.server.VaadinRequest request)
      Overrides:
      getMainDivId in class com.vaadin.flow.server.VaadinServletService
    • createVaadinSession

      protected com.vaadin.flow.server.VaadinSession createVaadinSession(com.vaadin.flow.server.VaadinRequest request)
      Overrides:
      createVaadinSession in class com.vaadin.flow.server.VaadinService