@Override public void addFlight(Flight flight) { airportRunaways.addFlight(flight); distributor.addTask(flight, Distributor.ACTION_ADD_AIRPLANE); if (flight.getFlightState().equals("Ожидает")) { serviceStatistics.incAmountReadyTakenOffPlane(); } else { serviceStatistics.incAmountFlewPlane(); } if (LOG.isInfoEnabled()) { LOG.info("add flight. Flight : " + flight); } }
@Override public void addMessage(User user, String text) { if (text == null || text.isEmpty()) { return; } serviceStatistics.incAmountSendMessage(user); CHAT_DAO.addMessage(user, text, new Timestamp(new Date().getTime())); if (LOG.isInfoEnabled()) { LOG.info("add message"); } }