public LockModeType getLockMode(Object entity) {
long start = 0;
if (isTraceEnabled)
start = System.currentTimeMillis();
LockModeType result = null;
try {
result = getEntityManager().getLockMode(entity);
} finally {
if (isTraceEnabled) {
long elapsed = System.currentTimeMillis() - start;