private int getExecutionCountForLogs(IDfDocument idfLogObject) { int executionCount = 0; try { executionCount = idfLogObject.getInt(IConstants.ATTR_LOG_EXECUTION_COUNT); DfLogger.debug(this, "Old Execution Count : " + executionCount, null, null); executionCount = executionCount >= 2 ? 0 : executionCount + 1; DfLogger.debug(this, "New Execution Count : " + executionCount, null, null); } catch (DfException e) { DfLogger.error(this, e.getStackTraceAsString(), null, null); throw new RuntimeException(e.getMessage()); } return executionCount; }