public class EntityState extends Object implements Comparable<EntityState>
Modifier and Type | Field and Description |
---|---|
protected int |
state
internal representation of all states of entity (use bitwise operation).
|
Constructor and Description |
---|
EntityState() |
Modifier and Type | Method and Description |
---|---|
void |
addCreate()
Add create state.
|
void |
addDelete()
Add delete state.
|
void |
addLoad()
Add load state.
|
void |
addRead()
Add read state
After the invocation, method
isRead() will always return true . |
void |
addUpdate()
Add update state.
|
int |
compareTo(EntityState o) |
boolean |
isCreate()
Tells if the
#CREATE state is on. |
boolean |
isDelete()
Tells if the
#DELETE state is on. |
boolean |
isLoad()
Tells if the
#LOAD state is on. |
boolean |
isRead()
Tells if the
#READ state is on. |
boolean |
isUpdate()
Tells if the
#UPDATE state is on. |
protected int state
public void addLoad()
isLoad()
will always return true
.public void addRead()
isRead()
will always return true
.public void addCreate()
isCreate()
will always return true
.public void addUpdate()
isUpdate()
will always return true
.public void addDelete()
isDelete()
will always return true
.public boolean isLoad()
#LOAD
state is on.true
if #LOAD
state is on, false
otherwise.public boolean isRead()
#READ
state is on.true
if #READ
state is on, false
otherwise.public boolean isCreate()
#CREATE
state is on.true
if #CREATE
state is on, false
otherwise.public boolean isUpdate()
#UPDATE
state is on.true
if #UPDATE
state is on, false
otherwise.public boolean isDelete()
#DELETE
state is on.true
if #DELETE
state is on, false
otherwise.public int compareTo(EntityState o)
compareTo
in interface Comparable<EntityState>
Copyright © 2004–2022 Code Lutin. All rights reserved.