Package org.keycloak.device
Class DeviceActivityManager
java.lang.Object
org.keycloak.device.DeviceActivityManager
- Author:
 - Pedro Igor
 
- 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionstatic voidattachDevice(UserSessionModel userSession, KeycloakSession session) Attaches a device to the givenuserSessionwhere the device information is obtained from theHttpHeaders.USER_AGENTin the current request, if available.static DeviceRepresentationgetCurrentDevice(UserSessionModel userSession) Returns the device information associated with the givenuserSession. 
- 
Constructor Details
- 
DeviceActivityManager
public DeviceActivityManager() 
 - 
 - 
Method Details
- 
getCurrentDevice
Returns the device information associated with the givenuserSession.- Parameters:
 userSession- the userSession- Returns:
 - the device information or null if no device is attached to the user session
 
 - 
attachDevice
Attaches a device to the givenuserSessionwhere the device information is obtained from theHttpHeaders.USER_AGENTin the current request, if available.- Parameters:
 userSession- the user sessionsession- the keycloak session
 
 -