Package org.genesys.blocks.model
Class VersionedModel
- java.lang.Object
-
- org.genesys.blocks.model.EmptyModel
-
- org.genesys.blocks.model.BasicModel
-
- org.genesys.blocks.model.VersionedModel
-
- All Implemented Interfaces:
Serializable,Activatable,EntityId,org.springframework.data.domain.Persistable<Long>
@MappedSuperclass public abstract class VersionedModel extends BasicModel implements Activatable
The Class VersionedModel.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanactiveActive by default!.
-
Constructor Summary
Constructors Constructor Description VersionedModel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)IntegergetVersion()Gets the version.inthashCode()booleanisActive()Checks if is active.voidsetActive(boolean active)Sets the active.voidsetVersion(Integer version)Sets the version.StringtoString()-
Methods inherited from class org.genesys.blocks.model.BasicModel
getId, setId
-
Methods inherited from class org.genesys.blocks.model.EmptyModel
isNew
-
-
-
-
Method Detail
-
getVersion
public Integer getVersion()
Gets the version.- Returns:
- the version
-
setVersion
public void setVersion(Integer version)
Sets the version.- Parameters:
version- the new version
-
isActive
public boolean isActive()
Description copied from interface:ActivatableChecks if is active.- Specified by:
isActivein interfaceActivatable- Returns:
- true, if is active
-
setActive
public void setActive(boolean active)
Sets the active.- Parameters:
active- the new active
-
hashCode
public int hashCode()
- Overrides:
hashCodein classEmptyModel
-
equals
public boolean equals(Object obj)
- Overrides:
equalsin classEmptyModel
-
toString
public String toString()
- Overrides:
toStringin classEmptyModel
-
-