Class TimeZoneManager
java.lang.Object
hu.rts.mike.example.dev.crm.session.TimeZoneManager
- All Implemented Interfaces:
com.vaadin.flow.server.VaadinServiceInitListener,Serializable,EventListener
@SpringComponent
public class TimeZoneManager
extends Object
implements com.vaadin.flow.server.VaadinServiceInitListener
The
TimeZoneManager stores the timezone offset for UI scope and helps to translate
between the backend-side Instant type and the frontend-side LocalDateTime type. Callers must ensure that all the calls are made from the UI thread
to avoid NullPointerException.- See Also:
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidinitTimeZone(com.vaadin.flow.component.UI ui) voidserviceInit(com.vaadin.flow.server.ServiceInitEvent serviceInitEvent)
-
Field Details
-
TIME_ZONE_OFFSET_COOKIE_NAME
- See Also:
-
TIME_ZONE_OFFSET_SESSION_ATTRIBUTE_NAME
- See Also:
-
-
Constructor Details
-
TimeZoneManager
public TimeZoneManager()
-
-
Method Details
-
serviceInit
public void serviceInit(com.vaadin.flow.server.ServiceInitEvent serviceInitEvent) - Specified by:
serviceInitin interfacecom.vaadin.flow.server.VaadinServiceInitListener
-
initTimeZone
public static void initTimeZone(com.vaadin.flow.component.UI ui)
-