Class JpaLockEntity
- java.lang.Object
-
- org.keycloak.models.map.common.UpdatableEntity.Impl
-
- org.keycloak.models.map.lock.MapLockEntity.AbstractLockEntity
-
- org.keycloak.models.map.storage.jpa.lock.entity.JpaLockEntity
-
- All Implemented Interfaces:
Serializable,AbstractEntity,UpdatableEntity,MapLockEntity,JpaRootEntity,JpaRootVersionedEntity
@Entity public class JpaLockEntity extends MapLockEntity.AbstractLockEntity implements JpaRootVersionedEntity
There are some fields marked by@Column(insertable = false, updatable = false). Those fields are automatically generated by database from json field, therefore marked as non-insertable and non-updatable to instruct hibernate.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.keycloak.models.map.lock.MapLockEntity
MapLockEntity.AbstractLockEntity, MapLockEntity.SearchableFields
-
Nested classes/interfaces inherited from interface org.keycloak.models.map.common.UpdatableEntity
UpdatableEntity.Impl
-
-
Field Summary
-
Fields inherited from class org.keycloak.models.map.common.UpdatableEntity.Impl
updated
-
-
Constructor Summary
Constructors Constructor Description JpaLockEntity()No-argument constructor, used by hibernate to instantiate entities.JpaLockEntity(UUID id, int version, Integer entityVersion, String name)JpaLockEntity(DeepCloner cloner)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)IntegergetCurrentSchemaVersion()IntegergetEntityVersion()StringgetId()StringgetKeycloakInstanceIdentifier()StringgetName()LonggetTimeAcquired()intgetVersion()Version of the JPA entity used for optimistic lockinginthashCode()booleanisMetadataInitialized()voidsetEntityVersion(Integer entityVersion)voidsetId(String id)voidsetKeycloakInstanceIdentifier(String keycloakInstanceIdentifier)voidsetName(String name)voidsetTimeAcquired(Long timeAcquired)-
Methods inherited from class org.keycloak.models.map.common.UpdatableEntity.Impl
clearUpdatedFlag, isUpdated
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.keycloak.models.map.storage.jpa.JpaRootEntity
updateEntityVersion
-
Methods inherited from interface org.keycloak.models.map.lock.MapLockEntity
isLockUnchanged
-
Methods inherited from interface org.keycloak.models.map.common.UpdatableEntity
clearUpdatedFlag, isUpdated
-
-
-
-
Constructor Detail
-
JpaLockEntity
public JpaLockEntity()
No-argument constructor, used by hibernate to instantiate entities.
-
JpaLockEntity
public JpaLockEntity(DeepCloner cloner)
-
-
Method Detail
-
isMetadataInitialized
public boolean isMetadataInitialized()
-
getEntityVersion
public Integer getEntityVersion()
- Specified by:
getEntityVersionin interfaceJpaRootEntity- Returns:
- current supported version of the JPA entity used for schema versioning.
-
getCurrentSchemaVersion
public Integer getCurrentSchemaVersion()
- Specified by:
getCurrentSchemaVersionin interfaceJpaRootEntity
-
setEntityVersion
public void setEntityVersion(Integer entityVersion)
- Specified by:
setEntityVersionin interfaceJpaRootEntity- Parameters:
entityVersion- sets current supported version to JPA entity.
-
getVersion
public int getVersion()
Description copied from interface:JpaRootVersionedEntityVersion of the JPA entity used for optimistic locking- Specified by:
getVersionin interfaceJpaRootVersionedEntity
-
getId
public String getId()
- Specified by:
getIdin interfaceAbstractEntity- Overrides:
getIdin classMapLockEntity.AbstractLockEntity
-
setId
public void setId(String id)
- Specified by:
setIdin interfaceAbstractEntity- Overrides:
setIdin classMapLockEntity.AbstractLockEntity
-
getName
public String getName()
- Specified by:
getNamein interfaceMapLockEntity
-
setName
public void setName(String name)
- Specified by:
setNamein interfaceMapLockEntity
-
getKeycloakInstanceIdentifier
public String getKeycloakInstanceIdentifier()
- Specified by:
getKeycloakInstanceIdentifierin interfaceMapLockEntity
-
setKeycloakInstanceIdentifier
public void setKeycloakInstanceIdentifier(String keycloakInstanceIdentifier)
- Specified by:
setKeycloakInstanceIdentifierin interfaceMapLockEntity
-
getTimeAcquired
public Long getTimeAcquired()
- Specified by:
getTimeAcquiredin interfaceMapLockEntity
-
setTimeAcquired
public void setTimeAcquired(Long timeAcquired)
- Specified by:
setTimeAcquiredin interfaceMapLockEntity
-
-