private void endWrongGearSession() { long diff = rpmTimestamp.getTime() - session.getStartTime().getTime(); session.setDuration((int) diff); if (diff >= 2000) { DatabaseManager.insertWrongGearSession(session); } session = null; }
private void startWrongGearSession() { session = new WrongGearSession(); session.setStartTime(rpmTimestamp); session.setGear(gearStatus); }