Class VaadinServiceScopedContext.ContextualStorageManager

java.lang.Object
com.vaadin.quarkus.context.VaadinServiceScopedContext.ContextualStorageManager
All Implemented Interfaces:
Serializable
Enclosing class:
VaadinServiceScopedContext

@ApplicationScoped public static class VaadinServiceScopedContext.ContextualStorageManager extends Object
See Also:
  • Constructor Details

    • ContextualStorageManager

      public ContextualStorageManager()
  • Method Details

    • getContextualStorage

      protected ContextualStorage getContextualStorage(String key, boolean createIfNotExist)
      Gets the ContextualStorage associated with the given context key, possibly creating a new instance, if requested and not already existing.
      Parameters:
      key - context key
      createIfNotExist - whether a ContextualStorage shall get created if it doesn't yet exist.
      Returns:
      a ContextualStorage instance.
    • relocate

      protected void relocate(String from, String to)
      Changes the context key for a contextual storage.
      Parameters:
      from - the contextual storage context key
      to - the new context for the contextual storage
    • newContextualStorage

      protected ContextualStorage newContextualStorage(String key)
      Creates a new ContextualStorage for the given context key.
      Parameters:
      key - the context key
      Returns:
      a new ContextualStorage instance.
    • destroyAll

      @PreDestroy protected void destroyAll()
      Destroys all existing contextual storages.
    • destroy

      protected void destroy(String key)
      Destroys the contextual storage associated with the given context key.
      Parameters:
      key - the context key
    • getKeySet

      protected Set<String> getKeySet()
      Gets context keys of all registered contextual storages.
      Returns:
      immutable set of context keys.