Package org.keycloak.models.jpa.session
Record Class ImmutablePersistentUserSessionEntity
java.lang.Object
java.lang.Record
org.keycloak.models.jpa.session.ImmutablePersistentUserSessionEntity
- All Implemented Interfaces:
PersistentUserSessionModel
public record ImmutablePersistentUserSessionEntity(String userSessionId, String realmId, String userId, int createOn, int lastSessionRefresh, String brokerSessionId, String offline, String data, Boolean rememberMe)
extends Record
implements PersistentUserSessionModel
An immutable
PersistentUserSessionEntity to optimize read-only queries.-
Constructor Summary
ConstructorsConstructorDescriptionImmutablePersistentUserSessionEntity(String userSessionId, String realmId, String userId, int createOn, int lastSessionRefresh, String brokerSessionId, String offline, String data, Boolean rememberMe) Creates an instance of aImmutablePersistentUserSessionEntityrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebrokerSessionIdrecord component.intcreateOn()Returns the value of thecreateOnrecord component.data()Returns the value of thedatarecord component.final booleanIndicates whether some other object is "equal to" this one.getData()intintfinal inthashCode()Returns a hash code value for this object.booleanbooleanintReturns the value of thelastSessionRefreshrecord component.offline()Returns the value of theofflinerecord component.realmId()Returns the value of therealmIdrecord component.Returns the value of therememberMerecord component.voidsetBrokerSessionId(String brokerSessionId) voidvoidsetLastSessionRefresh(int lastSessionRefresh) voidsetOffline(boolean offline) voidsetRealmId(String realmId) voidsetRememberMe(boolean rememberMe) voidsetStarted(int started) voidvoidsetUserSessionId(String userSessionId) final StringtoString()Returns a string representation of this record class.userId()Returns the value of theuserIdrecord component.Returns the value of theuserSessionIdrecord component.
-
Constructor Details
-
ImmutablePersistentUserSessionEntity
public ImmutablePersistentUserSessionEntity(String userSessionId, String realmId, String userId, int createOn, int lastSessionRefresh, String brokerSessionId, String offline, String data, Boolean rememberMe) Creates an instance of aImmutablePersistentUserSessionEntityrecord class.- Parameters:
userSessionId- the value for theuserSessionIdrecord componentrealmId- the value for therealmIdrecord componentuserId- the value for theuserIdrecord componentcreateOn- the value for thecreateOnrecord componentlastSessionRefresh- the value for thelastSessionRefreshrecord componentbrokerSessionId- the value for thebrokerSessionIdrecord componentoffline- the value for theofflinerecord componentdata- the value for thedatarecord componentrememberMe- the value for therememberMerecord component
-
-
Method Details
-
getUserSessionId
- Specified by:
getUserSessionIdin interfacePersistentUserSessionModel
-
setUserSessionId
- Specified by:
setUserSessionIdin interfacePersistentUserSessionModel
-
getStarted
public int getStarted()- Specified by:
getStartedin interfacePersistentUserSessionModel
-
setStarted
public void setStarted(int started) - Specified by:
setStartedin interfacePersistentUserSessionModel
-
getLastSessionRefresh
public int getLastSessionRefresh()- Specified by:
getLastSessionRefreshin interfacePersistentUserSessionModel
-
setLastSessionRefresh
public void setLastSessionRefresh(int lastSessionRefresh) - Specified by:
setLastSessionRefreshin interfacePersistentUserSessionModel
-
isOffline
public boolean isOffline()- Specified by:
isOfflinein interfacePersistentUserSessionModel
-
setOffline
public void setOffline(boolean offline) - Specified by:
setOfflinein interfacePersistentUserSessionModel
-
getData
- Specified by:
getDatain interfacePersistentUserSessionModel
-
setData
- Specified by:
setDatain interfacePersistentUserSessionModel
-
setRealmId
- Specified by:
setRealmIdin interfacePersistentUserSessionModel
-
setUserId
- Specified by:
setUserIdin interfacePersistentUserSessionModel
-
setBrokerSessionId
- Specified by:
setBrokerSessionIdin interfacePersistentUserSessionModel
-
isRememberMe
public boolean isRememberMe()- Specified by:
isRememberMein interfacePersistentUserSessionModel
-
setRememberMe
public void setRememberMe(boolean rememberMe) - Specified by:
setRememberMein interfacePersistentUserSessionModel
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
userSessionId
Returns the value of theuserSessionIdrecord component.- Returns:
- the value of the
userSessionIdrecord component
-
realmId
Returns the value of therealmIdrecord component.- Returns:
- the value of the
realmIdrecord component
-
userId
Returns the value of theuserIdrecord component.- Returns:
- the value of the
userIdrecord component
-
createOn
public int createOn()Returns the value of thecreateOnrecord component.- Returns:
- the value of the
createOnrecord component
-
lastSessionRefresh
public int lastSessionRefresh()Returns the value of thelastSessionRefreshrecord component.- Returns:
- the value of the
lastSessionRefreshrecord component
-
brokerSessionId
Returns the value of thebrokerSessionIdrecord component.- Returns:
- the value of the
brokerSessionIdrecord component
-
offline
Returns the value of theofflinerecord component.- Returns:
- the value of the
offlinerecord component
-
data
Returns the value of thedatarecord component.- Returns:
- the value of the
datarecord component
-
rememberMe
Returns the value of therememberMerecord component.- Returns:
- the value of the
rememberMerecord component
-